Class BlockEvent.EntityPlaceEvent
java.lang.Object
net.neoforged.bus.api.Event
net.neoforged.neoforge.event.level.BlockEvent
net.neoforged.neoforge.event.level.BlockEvent.EntityPlaceEvent
- All Implemented Interfaces:
 net.neoforged.bus.api.ICancellableEvent
- Direct Known Subclasses:
 BlockEvent.EntityMultiPlaceEvent
- Enclosing class:
 - BlockEvent
 
public static class BlockEvent.EntityPlaceEvent
extends BlockEvent
implements net.neoforged.bus.api.ICancellableEvent
Called when a block is placed.
 If a Block Place event is cancelled, the block will not be placed.
- 
Nested Class Summary
Nested classes/interfaces inherited from class net.neoforged.neoforge.event.level.BlockEvent
BlockEvent.BlockToolModificationEvent, BlockEvent.BreakEvent, BlockEvent.CreateFluidSourceEvent, BlockEvent.CropGrowEvent, BlockEvent.EntityMultiPlaceEvent, BlockEvent.EntityPlaceEvent, BlockEvent.FarmlandTrampleEvent, BlockEvent.FluidPlaceBlockEvent, BlockEvent.NeighborNotifyEvent, BlockEvent.PortalSpawnEventNested classes/interfaces inherited from class net.neoforged.bus.api.Event
net.neoforged.bus.api.Event.HasResult, net.neoforged.bus.api.Event.Result - 
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final BlockSnapshotprivate final Entityprivate final BlockStateprivate final BlockState - 
Constructor Summary
ConstructorsConstructorDescriptionEntityPlaceEvent(BlockSnapshot blockSnapshot, BlockState placedAgainst, @Nullable Entity entity)  - 
Method Summary
Methods inherited from class net.neoforged.neoforge.event.level.BlockEvent
getLevel, getPos, getStateMethods inherited from class net.neoforged.bus.api.Event
getResult, hasResult, setResultMethods 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
- 
entity
 - 
blockSnapshot
 - 
placedBlock
 - 
placedAgainst
 
 - 
 - 
Constructor Details
- 
EntityPlaceEvent
public EntityPlaceEvent(BlockSnapshot blockSnapshot, BlockState placedAgainst, @Nullable @Nullable Entity entity)  
 - 
 - 
Method Details
- 
getEntity
 - 
getBlockSnapshot
 - 
getPlacedBlock
 - 
getPlacedAgainst
 
 -