CommandSender
, Entity
, Metadatable
, Nameable
, Permissible
, PersistentDataHolder
, Projectile
, ServerOperator
LingeringPotion
, SplashPotion
public interface ThrownPotion extends Projectile
Entity.Spigot
Modifier and Type | Method | Description |
---|---|---|
@NotNull Collection<PotionEffect> |
getEffects() |
Returns the effects that are applied by this potion.
|
@NotNull ItemStack |
getItem() |
Returns a copy of the ItemStack for this thrown potion.
|
void |
setItem(@NotNull ItemStack item) |
Set the ItemStack for this thrown potion.
|
getName, sendMessage, sendMessage, sendMessage, sendMessage
addPassenger, addScoreboardTag, eject, fromMobSpawner, getBoundingBox, getChunk, getEntityId, getEntitySpawnReason, getFacing, getFallDistance, getFireTicks, getHeight, getLastDamageCause, getLocation, getLocation, getMaxFireTicks, getNearbyEntities, getOrigin, getPassenger, getPassengers, getPistonMoveReaction, getPortalCooldown, getPose, getScoreboardTags, getServer, getTicksLived, getType, getUniqueId, getVehicle, getVelocity, getWidth, getWorld, hasGravity, isCustomNameVisible, isDead, isEmpty, isGlowing, isInsideVehicle, isInvulnerable, isOnGround, isPersistent, isSilent, isValid, leaveVehicle, playEffect, remove, removePassenger, removeScoreboardTag, setCustomNameVisible, setFallDistance, setFireTicks, setGlowing, setGravity, setInvulnerable, setLastDamageCause, setPassenger, setPersistent, setPortalCooldown, setRotation, setSilent, setTicksLived, setVelocity, spigot, teleport, teleport, teleport, teleport, teleportAsync, teleportAsync
getMetadata, hasMetadata, removeMetadata, setMetadata
getCustomName, setCustomName
addAttachment, addAttachment, addAttachment, addAttachment, getEffectivePermissions, hasPermission, hasPermission, isPermissionSet, isPermissionSet, recalculatePermissions, removeAttachment
getPersistentDataContainer
doesBounce, getShooter, setBounce, setShooter
isOp, setOp
@NotNull @NotNull Collection<PotionEffect> getEffects()
@NotNull @NotNull ItemStack getItem()
Altering this copy will not alter the thrown potion directly. If you want
to alter the thrown potion, you must use the setItemStack
method.
void setItem(@NotNull @NotNull ItemStack item)
The ItemStack must be of type Material.SPLASH_POTION
or Material.LINGERING_POTION
, otherwise an exception
is thrown.
item
- New ItemStackCopyright © 2020. All rights reserved.