mirror of
https://github.com/TotalFreedomMC/OpenInv.git
synced 2024-12-23 00:15:08 +00:00
Use the same method for getting BlockChest, when checking whether AnyChest is needed due to the side block as in d0494aa2
This commit is contained in:
parent
d0494aa2e7
commit
ec3426b827
1 changed files with 2 additions and 1 deletions
|
@ -35,7 +35,8 @@ public class AnySilentChest implements IAnySilentChest {
|
|||
BlockPosition position = new BlockPosition(x, y, z);
|
||||
EntityPlayer player = ((CraftPlayer) p).getHandle();
|
||||
World world = player.world;
|
||||
BlockChest chest = (BlockChest) Block.getByName("chest");
|
||||
BlockChest chest = (BlockChest) (((BlockChest) world.getType(position).getBlock()).b == 1 ?
|
||||
Block.getByName("trapped_chest") : Block.getByName("chest"));
|
||||
|
||||
// If block on top
|
||||
if (topBlocking(world, position)) {
|
||||
|
|
Loading…
Reference in a new issue