From 4c5ef8103468672b24bd27831da2cb04de001400 Mon Sep 17 00:00:00 2001 From: OnyxDarkKnight Date: Thu, 26 Dec 2013 23:27:53 +0200 Subject: Fix? --- common/darkknight/jewelrycraft/block/BlockDisplayer.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'common/darkknight/jewelrycraft/block/BlockDisplayer.java') diff --git a/common/darkknight/jewelrycraft/block/BlockDisplayer.java b/common/darkknight/jewelrycraft/block/BlockDisplayer.java index 02de477..e0061ae 100644 --- a/common/darkknight/jewelrycraft/block/BlockDisplayer.java +++ b/common/darkknight/jewelrycraft/block/BlockDisplayer.java @@ -59,7 +59,7 @@ public class BlockDisplayer extends BlockContainer { TileEntityDisplayer te = (TileEntityDisplayer) world.getBlockTileEntity(i, j, k); ItemStack item = entityPlayer.inventory.getCurrentItem(); - if (te != null && item != null && !world.isRemote) + if (te != null && item != null && item != new ItemStack(0, 0, 0) && !world.isRemote) { if(!te.hasObject) { @@ -87,7 +87,7 @@ public class BlockDisplayer extends BlockContainer TileEntityDisplayer te = (TileEntityDisplayer) world.getBlockTileEntity(i, j, k); if (te != null && !world.isRemote) { - if (te.hasObject && player.inventory.addItemStackToInventory(te.object)) + if (te.hasObject && te.object != null && te.object != new ItemStack(0, 0, 0) && player.inventory.addItemStackToInventory(te.object)) { if(player.isSneaking()) { -- cgit v1.2.3