use of net.minecraftforge.event.world.BlockEvent.MultiPlaceEvent in project MinecraftForge by MinecraftForge.
the class ForgeEventFactory method onPlayerMultiBlockPlace.
public static MultiPlaceEvent onPlayerMultiBlockPlace(EntityPlayer player, List<BlockSnapshot> blockSnapshots, EnumFacing direction, @Nullable EnumHand hand) {
BlockSnapshot snap = blockSnapshots.get(0);
IBlockState placedAgainst = snap.getWorld().getBlockState(snap.getPos().offset(direction.getOpposite()));
MultiPlaceEvent event = new MultiPlaceEvent(blockSnapshots, placedAgainst, player, hand);
MinecraftForge.EVENT_BUS.post(event);
return event;
}
Aggregations