From 4a21f4ce242ab1bb64e7133efa1a37c407e1d20b Mon Sep 17 00:00:00 2001 From: CovertJaguar Date: Sun, 8 Dec 2013 21:03:29 -0800 Subject: [PATCH] Notify player of inv changes when filling --- common/buildcraft/core/fluids/FluidUtils.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/common/buildcraft/core/fluids/FluidUtils.java b/common/buildcraft/core/fluids/FluidUtils.java index 2e0a535e..6f600b54 100644 --- a/common/buildcraft/core/fluids/FluidUtils.java +++ b/common/buildcraft/core/fluids/FluidUtils.java @@ -36,6 +36,7 @@ public class FluidUtils { if (used > 0) { if (!player.capabilities.isCreativeMode) { player.inventory.setInventorySlotContents(player.inventory.currentItem, InvUtils.consumeItem(current)); + player.inventory.onInventoryChanged(); } return true; } @@ -50,14 +51,14 @@ public class FluidUtils { if (liquid != null) { if (current.stackSize > 1) { - if (!player.inventory.addItemStackToInventory(filled)) { + if (!player.inventory.addItemStackToInventory(filled)) return false; - } else { - player.inventory.setInventorySlotContents(player.inventory.currentItem, InvUtils.consumeItem(current)); - } + player.inventory.setInventorySlotContents(player.inventory.currentItem, InvUtils.consumeItem(current)); + player.inventory.onInventoryChanged(); } else { player.inventory.setInventorySlotContents(player.inventory.currentItem, InvUtils.consumeItem(current)); player.inventory.setInventorySlotContents(player.inventory.currentItem, filled); + player.inventory.onInventoryChanged(); } tank.drain(side, liquid.amount, true);