From 241e11397ba26ad337633fbd9a9e096795605f47 Mon Sep 17 00:00:00 2001 From: syeyoung Date: Mon, 10 May 2021 22:49:52 +0900 Subject: press any key to close chest no longer closes when swiping mouse. --- .../features/impl/dungeon/FeaturePressAnyKeyToCloseChest.java | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/main/java/kr/syeyoung') diff --git a/src/main/java/kr/syeyoung/dungeonsguide/features/impl/dungeon/FeaturePressAnyKeyToCloseChest.java b/src/main/java/kr/syeyoung/dungeonsguide/features/impl/dungeon/FeaturePressAnyKeyToCloseChest.java index c2113120..e0dc7f97 100644 --- a/src/main/java/kr/syeyoung/dungeonsguide/features/impl/dungeon/FeaturePressAnyKeyToCloseChest.java +++ b/src/main/java/kr/syeyoung/dungeonsguide/features/impl/dungeon/FeaturePressAnyKeyToCloseChest.java @@ -30,6 +30,7 @@ import net.minecraft.client.gui.inventory.GuiChest; import net.minecraft.inventory.ContainerChest; import net.minecraft.inventory.IInventory; import net.minecraftforge.client.event.GuiScreenEvent; +import org.lwjgl.input.Mouse; public class FeaturePressAnyKeyToCloseChest extends SimpleFeature implements KeyInputListener, GuiClickListener { public FeaturePressAnyKeyToCloseChest() { @@ -66,6 +67,7 @@ public class FeaturePressAnyKeyToCloseChest extends SimpleFeature implements Key GuiScreen screen = Minecraft.getMinecraft().currentScreen; if (!isEnabled()) return; if (!DungeonsGuide.getDungeonsGuide().getSkyblockStatus().isOnDungeon()) return; + if (Mouse.getEventButton() == -1) return; if (screen instanceof GuiChest){ ContainerChest ch = (ContainerChest) ((GuiChest)screen).inventorySlots; -- cgit