From f9eddf3f6eed4805d5c1dd5be4f4731be7e508c3 Mon Sep 17 00:00:00 2001 From: Brokkonaut Date: Fri, 9 Dec 2016 12:53:15 +1100 Subject: SPIGOT-2886: Call BlockFormEvent when Lava and Water collide --- nms-patches/BlockFluids.patch | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 nms-patches/BlockFluids.patch (limited to 'nms-patches/BlockFluids.patch') diff --git a/nms-patches/BlockFluids.patch b/nms-patches/BlockFluids.patch new file mode 100644 index 00000000..ba2f7bb4 --- /dev/null +++ b/nms-patches/BlockFluids.patch @@ -0,0 +1,27 @@ +--- a/net/minecraft/server/BlockFluids.java ++++ b/net/minecraft/server/BlockFluids.java +@@ -163,14 +163,20 @@ + Integer integer = (Integer) iblockdata.get(BlockFluids.LEVEL); + + if (integer.intValue() == 0) { +- world.setTypeUpdate(blockposition, Blocks.OBSIDIAN.getBlockData()); +- this.fizz(world, blockposition); ++ // CraftBukkit start ++ if (org.bukkit.craftbukkit.event.CraftEventFactory.handleBlockFormEvent(world, blockposition, Blocks.OBSIDIAN, null)) { ++ this.fizz(world, blockposition); ++ } ++ // CraftBukkit end + return true; + } + + if (integer.intValue() <= 4) { +- world.setTypeUpdate(blockposition, Blocks.COBBLESTONE.getBlockData()); +- this.fizz(world, blockposition); ++ // CraftBukkit start ++ if (org.bukkit.craftbukkit.event.CraftEventFactory.handleBlockFormEvent(world, blockposition, Blocks.COBBLESTONE, null)) { ++ this.fizz(world, blockposition); ++ } ++ // CraftBukkit end + return true; + } + } -- cgit v1.2.3