aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main/java/de/torui/coflsky/gui/bingui/BinGuiCurrent.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main/java/de/torui/coflsky/gui/bingui/BinGuiCurrent.java b/src/main/java/de/torui/coflsky/gui/bingui/BinGuiCurrent.java
index 03892ec..e742ba0 100644
--- a/src/main/java/de/torui/coflsky/gui/bingui/BinGuiCurrent.java
+++ b/src/main/java/de/torui/coflsky/gui/bingui/BinGuiCurrent.java
@@ -44,6 +44,7 @@ public class BinGuiCurrent extends GuiChest {
private int pixelsScrolled = 0;
private boolean wasMouseDown;
private boolean isRendered = false;
+ private boolean isClosing = false;
private boolean hasInitialMouseSet = false;
// set if the auction was already bought
@@ -157,6 +158,9 @@ public class BinGuiCurrent extends GuiChest {
@Override
public void drawScreen(int mouseX, int mouseY, float partialTicks) {
+ if(isClosing){
+ return;
+ }
Mouse.setGrabbed(false);
isRendered = true;
@@ -270,6 +274,8 @@ public class BinGuiCurrent extends GuiChest {
itemStack = null;
hasInitialMouseSet = false;
isRendered = false;
+ isClosing = true;
+ Mouse.setGrabbed(true);
mc.thePlayer.closeScreen();
MinecraftForge.EVENT_BUS.unregister(this);
}