public class PlayerBucketEntityEvent extends PlayerEvent implements Cancellable
Event.Resultplayer| Constructor and Description |
|---|
PlayerBucketEntityEvent(Player player,
Entity entity,
ItemStack originalBucket,
ItemStack entityBucket) |
| Modifier and Type | Method and Description |
|---|---|
Entity |
getEntity()
Gets the
Entity being put into the bucket. |
ItemStack |
getEntityBucket()
Gets the bucket that the
Entity will be put into. |
static HandlerList |
getHandlerList() |
HandlerList |
getHandlers() |
ItemStack |
getOriginalBucket()
Gets the bucket used to capture the
Entity. |
boolean |
isCancelled()
Gets the cancellation state of this event.
|
void |
setCancelled(boolean cancel)
Sets the cancellation state of this event.
|
getPlayergetEventName, isAsynchronous@NotNull public Entity getEntity()
Entity being put into the bucket.Entity being put into the bucket@NotNull public ItemStack getOriginalBucket()
Entity.
This refers to the bucket clicked with, eg Material.WATER_BUCKET.@NotNull public ItemStack getEntityBucket()
Entity will be put into.
This refers to the bucket with the entity, eg
Material.PUFFERFISH_BUCKET.Entity will be put intopublic boolean isCancelled()
CancellableisCancelled in interface Cancellablepublic void setCancelled(boolean cancel)
CancellablesetCancelled in interface Cancellablecancel - true if you wish to cancel this event@NotNull public HandlerList getHandlers()
getHandlers in class Event@NotNull public static HandlerList getHandlerList()
Copyright © 2022. All rights reserved.