mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-28 23:38:25 +01:00
Remove useless check on player interact cancellation (#5448)
This removes the BlockFlowerPot check that most likely was used when it was a tile entity.
This commit is contained in:
parent
e4e3475ac3
commit
fe208075ab
1 changed files with 0 additions and 12 deletions
|
@ -60,18 +60,6 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
|||
+ entityplayer.playerConnection.sendPacket(new PacketPlayOutCloseWindow());
|
||||
+ } else if (iblockdata.getBlock() instanceof BlockCommand) {
|
||||
+ entityplayer.playerConnection.sendPacket(new PacketPlayOutCloseWindow());
|
||||
+ } else if (iblockdata.getBlock() instanceof BlockFlowerPot) {
|
||||
+ // Send a block change to air and then send back the correct block, just to make the client happy
|
||||
+ PacketPlayOutBlockChange packet = new PacketPlayOutBlockChange(this.world, blockposition);
|
||||
+ packet.block = Blocks.AIR.getBlockData();
|
||||
+ this.player.playerConnection.sendPacket(packet);
|
||||
+
|
||||
+ this.player.playerConnection.sendPacket(new PacketPlayOutBlockChange(this.world, blockposition));
|
||||
+
|
||||
+ TileEntity tileentity = this.world.getTileEntity(blockposition);
|
||||
+ if (tileentity != null) {
|
||||
+ player.playerConnection.sendPacket(tileentity.getUpdatePacket());
|
||||
+ }
|
||||
}
|
||||
+ // Paper end - extend Player Interact cancellation
|
||||
entityplayer.getBukkitEntity().updateInventory(); // SPIGOT-2867
|
||||
|
|
Loading…
Reference in a new issue