diff --git a/eSpigot-Server/src/main/java/net/minecraft/server/BlockPlant.java b/eSpigot-Server/src/main/java/net/minecraft/server/BlockPlant.java index 6697837..eb6ff57 100644 --- a/eSpigot-Server/src/main/java/net/minecraft/server/BlockPlant.java +++ b/eSpigot-Server/src/main/java/net/minecraft/server/BlockPlant.java @@ -42,20 +42,21 @@ public class BlockPlant extends Block { } protected void e(World world, BlockPosition blockposition, IBlockData iblockdata) { - if (!this.f(world, blockposition, iblockdata) && ((WorldServer) world).hasPhysicsEvent) { // PandaSpigot - hasPhysicsEvent + if (!this.f(world, blockposition, iblockdata)) { // CraftBukkit Start - org.bukkit.block.Block block = world.getWorld().getBlockAt(blockposition.getX(), blockposition.getY(), blockposition.getZ()); - BlockPhysicsEvent event = new BlockPhysicsEvent(block, block.getTypeId()); - world.getServer().getPluginManager().callEvent(event); + if (((WorldServer) world).hasPhysicsEvent) { // PandaSpigot - hasPhysicsEvent + org.bukkit.block.Block block = world.getWorld().getBlockAt(blockposition.getX(), blockposition.getY(), blockposition.getZ()); + BlockPhysicsEvent event = new BlockPhysicsEvent(block, block.getTypeId()); + world.getServer().getPluginManager().callEvent(event); - if (event.isCancelled()) { - return; + if (event.isCancelled()) { + return; + } } // CraftBukkit end this.b(world, blockposition, iblockdata, 0); world.setTypeAndData(blockposition, Blocks.AIR.getBlockData(), 3); } - } public boolean f(World world, BlockPosition blockposition, IBlockData iblockdata) {