SPIGOT-6478: Double chests opened by plugins don't play their closing animation.
This commit is contained in:
parent
fd905ab527
commit
5912843493
@ -29,7 +29,6 @@ import net.minecraft.world.level.block.BlockEnchantmentTable;
|
|||||||
import net.minecraft.world.level.block.BlockWorkbench;
|
import net.minecraft.world.level.block.BlockWorkbench;
|
||||||
import net.minecraft.world.level.block.Blocks;
|
import net.minecraft.world.level.block.Blocks;
|
||||||
import net.minecraft.world.level.block.entity.TileEntity;
|
import net.minecraft.world.level.block.entity.TileEntity;
|
||||||
import net.minecraft.world.level.block.entity.TileEntityContainer;
|
|
||||||
import net.minecraft.world.level.block.state.IBlockData;
|
import net.minecraft.world.level.block.state.IBlockData;
|
||||||
import org.bukkit.GameMode;
|
import org.bukkit.GameMode;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
@ -295,7 +294,7 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Containers<?> container = CraftContainer.getNotchInventoryType(inventory);
|
Containers<?> container = CraftContainer.getNotchInventoryType(inventory);
|
||||||
if (iinventory instanceof TileEntityContainer) {
|
if (iinventory instanceof ITileInventory) {
|
||||||
getHandle().openContainer(iinventory);
|
getHandle().openContainer(iinventory);
|
||||||
} else {
|
} else {
|
||||||
openCustomInventory(inventory, player, container);
|
openCustomInventory(inventory, player, container);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user