mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-10 10:17:38 +01:00
SPIGOT-536: Delay physics updates for tall plants until both parts are set
By: Thinkofdeath <thinkofdeath@spigotmc.org>
This commit is contained in:
parent
77f7c3e705
commit
31eccc6372
25
paper-server/nms-patches/BlockTallPlant.patch
Normal file
25
paper-server/nms-patches/BlockTallPlant.patch
Normal file
@ -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
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user