diff --git a/common/buildcraft/factory/TileHopper.java b/common/buildcraft/factory/TileHopper.java index 67d70e8a..0410144b 100644 --- a/common/buildcraft/factory/TileHopper.java +++ b/common/buildcraft/factory/TileHopper.java @@ -25,7 +25,12 @@ public class TileHopper extends TileBuildCraft implements IInventory { private final SimpleInventory inventory = new SimpleInventory(4, "Hopper", 64); private boolean isEmpty; private TileEntity outputTile; - + + @Override + public void initialize() { + inventory.addListener(this); + } + @Override public void readFromNBT(NBTTagCompound nbtTagCompound) { super.readFromNBT(nbtTagCompound); @@ -38,8 +43,7 @@ public class TileHopper extends TileBuildCraft implements IInventory { } inventory.readFromNBT(p); - - refreshInventoryFlags(); + inventory.markDirty(); } @Override @@ -90,7 +94,8 @@ public class TileHopper extends TileBuildCraft implements IInventory { } } - private void refreshInventoryFlags() { + @Override + public void markDirty() { isEmpty = true; for (int internalSlot = 0; internalSlot < inventory.getSizeInventory(); internalSlot++) { @@ -118,21 +123,18 @@ public class TileHopper extends TileBuildCraft implements IInventory { @Override public ItemStack decrStackSize(int slotId, int count) { ItemStack output = inventory.decrStackSize(slotId, count); - refreshInventoryFlags(); return output; } @Override public ItemStack getStackInSlotOnClosing(int slotId) { ItemStack output = inventory.getStackInSlotOnClosing(slotId); - refreshInventoryFlags(); return output; } @Override public void setInventorySlotContents(int slotId, ItemStack itemStack) { inventory.setInventorySlotContents(slotId, itemStack); - refreshInventoryFlags(); } @Override diff --git a/common/buildcraft/transport/render/PipeRendererWorld.java b/common/buildcraft/transport/render/PipeRendererWorld.java index 598bfb40..9e60229b 100644 --- a/common/buildcraft/transport/render/PipeRendererWorld.java +++ b/common/buildcraft/transport/render/PipeRendererWorld.java @@ -97,7 +97,7 @@ public class PipeRendererWorld implements ISimpleBlockRenderingHandler { fakeBlock.setColor(0xFFFFFF); } else if (renderPass == 1) { // Fix a bug in Minecraft 1.7.2-1.7.10 - // Remove in 1.8 + // TODO: Remove in 1.8 renderblocks.renderFaceXNeg(fakeBlock, x, y, z, PipeIconProvider.TYPE.Transparent.getIcon()); }