From 0e9bbdcdac151d3454a41408f3832c87f96e7fb8 Mon Sep 17 00:00:00 2001 From: Kam Date: Sun, 17 Mar 2024 17:07:04 -0400 Subject: [PATCH] Move Inventory Slots --- src/main/java/noppes/npcs/containers/ContainerCustomGui.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/java/noppes/npcs/containers/ContainerCustomGui.java b/src/main/java/noppes/npcs/containers/ContainerCustomGui.java index c42b6f041..68cba316f 100644 --- a/src/main/java/noppes/npcs/containers/ContainerCustomGui.java +++ b/src/main/java/noppes/npcs/containers/ContainerCustomGui.java @@ -33,12 +33,13 @@ public class ContainerCustomGui extends Container { public void setGui(ScriptGui gui, EntityPlayer player) { this.customGui = gui; + + slotCount=0; + inventorySlots.clear(); if (this.customGui.getShowPlayerInv()) { this.addPlayerInventory(player, this.customGui.getPlayerInvX(), this.customGui.getPlayerInvY()); } - slotCount=0; - // inventorySlots.clear(); for (IItemSlot slot : this.customGui.getSlots()) { if (slot.hasStack()) { this.addSlot(player, slot.getPosX(), slot.getPosY(), slot, slot.getStack().getMCItemStack(), player.worldObj.isRemote);