public class ArrowCollideEvent extends EntityEvent implements Cancellable
This event is called before EntityDamageByEntityEvent
, and cancelling it will allow the arrow to continue flying
Event.Result
Constructor and Description |
---|
ArrowCollideEvent(Arrow what,
Entity collidedWith) |
Modifier and Type | Method and Description |
---|---|
Entity |
getCollidedWith()
Get the entity the arrow collided wit
|
Arrow |
getEntity()
Get the arrow that collided
|
static HandlerList |
getHandlerList() |
HandlerList |
getHandlers() |
boolean |
isCancelled()
Gets the cancellation state of this event.
|
void |
setCancelled(boolean cancel)
Sets the cancellation state of this event.
|
getEntityType
getEventName, isAsynchronous
public Entity getCollidedWith()
public Arrow getEntity()
getEntity
in class EntityEvent
public static HandlerList getHandlerList()
public HandlerList getHandlers()
getHandlers
in class Event
public boolean isCancelled()
Cancellable
isCancelled
in interface Cancellable
public void setCancelled(boolean cancel)
Cancellable
setCancelled
in interface Cancellable
cancel
- true if you wish to cancel this eventCopyright © 2022. All rights reserved.