aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/io
diff options
context:
space:
mode:
authorDoKM <mcazzyman@gmail.com>2021-08-28 19:03:35 +0200
committerDoKM <mcazzyman@gmail.com>2021-08-28 19:03:35 +0200
commitb9525a3419d695ce8b10e8da76ba61c0c6be54e2 (patch)
treebfaf6bd882075bb7c5b606f584a33950c35b35f1 /src/main/java/io
parent45d4cfb62437201fbcacea0fe888acab7806dc62 (diff)
downloadNotEnoughUpdates-b9525a3419d695ce8b10e8da76ba61c0c6be54e2.tar.gz
NotEnoughUpdates-b9525a3419d695ce8b10e8da76ba61c0c6be54e2.tar.bz2
NotEnoughUpdates-b9525a3419d695ce8b10e8da76ba61c0c6be54e2.zip
I think this fixes a slotlocking crash
Diffstat (limited to 'src/main/java/io')
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/SlotLocking.java2
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);