From b70ebbc9cf8fdb4a1ec228b51e2cfcd010af905d Mon Sep 17 00:00:00 2001 From: Thinkofdeath Date: Sat, 7 Feb 2015 10:08:55 +0000 Subject: SPIGOT-536: Delay physics updates for tall plants until both parts are set --- nms-patches/BlockTallPlant.patch | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 nms-patches/BlockTallPlant.patch (limited to 'nms-patches') diff --git a/nms-patches/BlockTallPlant.patch b/nms-patches/BlockTallPlant.patch new file mode 100644 index 00000000..96da54d9 --- /dev/null +++ b/nms-patches/BlockTallPlant.patch @@ -0,0 +1,25 @@ +--- ../work/decompile-8eb82bde//net/minecraft/server/BlockTallPlant.java 2015-02-07 10:08:04.520216186 +0000 ++++ src/main/java/net/minecraft/server/BlockTallPlant.java 2015-02-07 10:08:04.520216186 +0000 +@@ -55,16 +55,20 @@ + Object object1 = flag ? world.getType(blockposition2).getBlock() : this; + + if (object == this) { +- world.setTypeAndData(blockposition1, Blocks.AIR.getBlockData(), 3); ++ world.setTypeAndData(blockposition1, Blocks.AIR.getBlockData(), 2); // CraftBukkit + } + + if (object1 == this) { +- world.setTypeAndData(blockposition2, Blocks.AIR.getBlockData(), 3); ++ world.setTypeAndData(blockposition2, Blocks.AIR.getBlockData(), 2); // CraftBukkit + if (!flag) { + this.b(world, blockposition2, iblockdata, 0); + } + } + ++ // CraftBukkit start - delay updates ++ world.update(blockposition1, this); ++ world.update(blockposition2, this); ++ // CraftBukkit end + } + } + -- cgit v1.2.3