mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-04 14:04:49 +01:00
SPIGOT-4835: Manually opened chest doesn't have close animation
This commit is contained in:
parent
84c2f4d1ab
commit
09a453aede
1 changed files with 28 additions and 24 deletions
|
@ -334,6 +334,9 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity {
|
|||
case PLAYER:
|
||||
case CHEST:
|
||||
case ENDER_CHEST:
|
||||
if (iinventory instanceof ITileInventory) {
|
||||
getHandle().openContainer((ITileInventory) iinventory);
|
||||
} else {
|
||||
Containers customSize;
|
||||
switch (inventory.getSize()) {
|
||||
case 9:
|
||||
|
@ -359,6 +362,7 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity {
|
|||
throw new IllegalArgumentException("Unsupported custom inventory size " + inventory.getSize());
|
||||
}
|
||||
openCustomInventory(inventory, player, customSize);
|
||||
}
|
||||
break;
|
||||
case DISPENSER:
|
||||
if (iinventory instanceof TileEntityDispenser) {
|
||||
|
|
Loading…
Reference in a new issue