Class LivingDestroyBlockEvent
java.lang.Object
net.neoforged.bus.api.Event
net.neoforged.neoforge.event.entity.EntityEvent
net.neoforged.neoforge.event.entity.living.LivingEvent
net.neoforged.neoforge.event.entity.living.LivingDestroyBlockEvent
- All Implemented Interfaces:
net.neoforged.bus.api.ICancellableEvent
public class LivingDestroyBlockEvent
extends LivingEvent
implements net.neoforged.bus.api.ICancellableEvent
Fired when the ender dragon or wither attempts to destroy a block and when ever a zombie attempts to break a door. Basically a event version of
This event is
If this event is canceled, the block will not be destroyed.
This event is fired on the
IBlockExtension.canEntityDestroy(BlockState, BlockGetter, BlockPos, Entity)This event is
ICancellableEvent.If this event is canceled, the block will not be destroyed.
This event is fired on the
NeoForge.EVENT_BUS.-
Nested Class Summary
Nested classes/interfaces inherited from class net.neoforged.neoforge.event.entity.living.LivingEvent
LivingEvent.LivingJumpEvent, LivingEvent.LivingVisibilityEventNested classes/interfaces inherited from class net.neoforged.neoforge.event.entity.EntityEvent
EntityEvent.EnteringSection, EntityEvent.EntityConstructing, EntityEvent.Size -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionLivingDestroyBlockEvent(LivingEntity entity, BlockPos pos, BlockState state) -
Method Summary
Methods inherited from class net.neoforged.neoforge.event.entity.living.LivingEvent
getEntityMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.neoforged.bus.api.ICancellableEvent
isCanceled, setCanceled
-
Field Details
-
pos
-
state
-
-
Constructor Details
-
LivingDestroyBlockEvent
-
-
Method Details
-
getState
-
getPos
-