diff options
author | DoKM <mcazzyman@gmail.com> | 2021-08-28 19:03:35 +0200 |
---|---|---|
committer | DoKM <mcazzyman@gmail.com> | 2021-08-28 19:03:35 +0200 |
commit | b9525a3419d695ce8b10e8da76ba61c0c6be54e2 (patch) | |
tree | bfaf6bd882075bb7c5b606f584a33950c35b35f1 /src/main | |
parent | 45d4cfb62437201fbcacea0fe888acab7806dc62 (diff) | |
download | NotEnoughUpdates-b9525a3419d695ce8b10e8da76ba61c0c6be54e2.tar.gz NotEnoughUpdates-b9525a3419d695ce8b10e8da76ba61c0c6be54e2.tar.bz2 NotEnoughUpdates-b9525a3419d695ce8b10e8da76ba61c0c6be54e2.zip |
I think this fixes a slotlocking crash
Diffstat (limited to 'src/main')
-rw-r--r-- | src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/SlotLocking.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/SlotLocking.java b/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/SlotLocking.java index 7f981092..7459c4a4 100644 --- a/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/SlotLocking.java +++ b/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/SlotLocking.java @@ -420,7 +420,7 @@ public class SlotLocking { return; } else if(locked.locked || (clickType == 2 && SlotLocking.getInstance().isSlotIndexLocked(clickedButton))) { consumer.accept(null); - } else if(NotEnoughUpdates.INSTANCE.config.slotLocking.enableSlotBinding && clickType == 1) { + } else if(NotEnoughUpdates.INSTANCE.config.slotLocking.enableSlotBinding && clickType == 1 && locked.boundTo != -1) { GuiContainer container = (GuiContainer) Minecraft.getMinecraft().currentScreen; Slot boundSlot = container.inventorySlots.getSlotFromInventory(Minecraft.getMinecraft().thePlayer.inventory, locked.boundTo); |