Package org.bukkit.entity
Interface Arrow
- All Superinterfaces:
- AbstractArrow,- CommandSender,- Entity,- Metadatable,- Nameable,- Permissible,- PersistentDataHolder,- Projectile,- ServerOperator
- All Known Subinterfaces:
- TippedArrow
- 
Nested Class SummaryNested classes/interfaces inherited from interface org.bukkit.entity.AbstractArrowAbstractArrow.PickupStatusNested classes/interfaces inherited from interface org.bukkit.entity.EntityEntity.Spigot
- 
Method SummaryModifier and TypeMethodDescriptionbooleanaddCustomEffect(PotionEffect effect, boolean overwrite) Adds a custom potion effect to this arrow.voidRemoves all custom potion effects from this arrow.Deprecated.Returns the potion type about the base potiongetColor()Gets the color of this arrow.Gets an immutable list containing all custom potion effects applied to this arrow.booleanChecks for a specific custom potion effect type on this arrow.booleanChecks for the presence of custom potion effects.booleanRemoves a custom potion effect from this arrow.voidsetBasePotionData(PotionData data) Deprecated.Upgraded / extended potions are now their ownPotionTypeusesetBasePotionType(org.bukkit.potion.PotionType)instead.voidsetBasePotionType(PotionType type) Sets the underlying potion typevoidSets the color of this arrow.Methods inherited from interface org.bukkit.entity.AbstractArrowgetAttachedBlock, getDamage, getItem, getKnockbackStrength, getPickupStatus, getPierceLevel, getWeapon, isCritical, isInBlock, isShotFromCrossbow, setCritical, setDamage, setItem, setKnockbackStrength, setPickupStatus, setPierceLevel, setShotFromCrossbow, setWeaponMethods inherited from interface org.bukkit.command.CommandSendergetName, sendMessage, sendMessage, sendMessage, sendMessageMethods inherited from interface org.bukkit.entity.EntityaddPassenger, addScoreboardTag, copy, copy, createSnapshot, eject, getAsString, getBoundingBox, getEntityId, getFacing, getFallDistance, getFireTicks, getFreezeTicks, getHeight, getLastDamageCause, getLocation, getLocation, getMaxFireTicks, getMaxFreezeTicks, getNearbyEntities, getPassenger, getPassengers, getPistonMoveReaction, getPortalCooldown, getPose, getScoreboardTags, getServer, getSpawnCategory, getSwimHighSpeedSplashSound, getSwimSound, getSwimSplashSound, getTicksLived, getTrackedBy, getType, getUniqueId, getVehicle, getVelocity, getWidth, getWorld, hasGravity, isCustomNameVisible, isDead, isEmpty, isFrozen, isGlowing, isInsideVehicle, isInvulnerable, isInWater, isInWorld, isOnGround, isPersistent, isSilent, isValid, isVisibleByDefault, isVisualFire, leaveVehicle, playEffect, remove, removePassenger, removeScoreboardTag, setCustomNameVisible, setFallDistance, setFireTicks, setFreezeTicks, setGlowing, setGravity, setInvulnerable, setLastDamageCause, setPassenger, setPersistent, setPortalCooldown, setRotation, setSilent, setTicksLived, setVelocity, setVisibleByDefault, setVisualFire, spigot, teleport, teleport, teleport, teleportMethods inherited from interface org.bukkit.metadata.MetadatablegetMetadata, hasMetadata, removeMetadata, setMetadataMethods inherited from interface org.bukkit.NameablegetCustomName, setCustomNameMethods inherited from interface org.bukkit.permissions.PermissibleaddAttachment, addAttachment, addAttachment, addAttachment, getEffectivePermissions, hasPermission, hasPermission, isPermissionSet, isPermissionSet, recalculatePermissions, removeAttachmentMethods inherited from interface org.bukkit.persistence.PersistentDataHoldergetPersistentDataContainerMethods inherited from interface org.bukkit.entity.ProjectiledoesBounce, getShooter, setBounce, setShooterMethods inherited from interface org.bukkit.permissions.ServerOperatorisOp, setOp
- 
Method Details- 
setBasePotionDataDeprecated.Upgraded / extended potions are now their ownPotionTypeusesetBasePotionType(org.bukkit.potion.PotionType)instead.Sets the underlying potion data- Parameters:
- data- PotionData to set the base potion state to
 
- 
getBasePotionDataDeprecated.Upgraded / extended potions are now their ownPotionTypeusegetBasePotionType()instead.Returns the potion data about the base potion- Returns:
- a PotionData object
 
- 
setBasePotionTypeSets the underlying potion type- Parameters:
- type- PotionType to set the base potion state to
 
- 
getBasePotionTypeReturns the potion type about the base potion- Returns:
- a PotionType object
 
- 
getColorGets the color of this arrow.- Returns:
- arrow Coloror null if not color is set
 
- 
setColorSets the color of this arrow. Will be applied as a tint to its particles.- Parameters:
- color- arrow color, null to clear the color
 
- 
hasCustomEffectsboolean hasCustomEffects()Checks for the presence of custom potion effects.- Returns:
- true if custom potion effects are applied
 
- 
getCustomEffectsGets an immutable list containing all custom potion effects applied to this arrow.Plugins should check that hasCustomEffects() returns true before calling this method. - Returns:
- the immutable list of custom potion effects
 
- 
addCustomEffectAdds a custom potion effect to this arrow.- Parameters:
- effect- the potion effect to add
- overwrite- true if any existing effect of the same type should be overwritten
- Returns:
- true if the effect was added as a result of this call
 
- 
removeCustomEffectRemoves a custom potion effect from this arrow.- Parameters:
- type- the potion effect type to remove
- Returns:
- true if the an effect was removed as a result of this call
- Throws:
- IllegalArgumentException- if this operation would leave the Arrow in a state with no Custom Effects and PotionType.UNCRAFTABLE
 
- 
hasCustomEffectChecks for a specific custom potion effect type on this arrow.- Parameters:
- type- the potion effect type to check for
- Returns:
- true if the potion has this effect
 
- 
clearCustomEffectsvoid clearCustomEffects()Removes all custom potion effects from this arrow.- Throws:
- IllegalArgumentException- if this operation would leave the Arrow in a state with no Custom Effects and PotionType.UNCRAFTABLE
 
 
- 
PotionTypeusegetBasePotionType()instead.