fixed chat gui crash when closed

This commit is contained in:
LAX1DUDE 2022-03-11 14:26:06 -08:00
parent ca7c681ab9
commit 2a28e69e31
2 changed files with 4 additions and 4 deletions

View File

@ -4,7 +4,7 @@ public class ConfigConstants {
public static boolean profanity = false; public static boolean profanity = false;
public static final String version = "22w10c"; public static final String version = "22w10d";
public static final String mainMenuString = "eaglercraft " + version; public static final String mainMenuString = "eaglercraft " + version;
public static final String forkMe = "https://github.com/LAX1DUDE/eaglercraft"; public static final String forkMe = "https://github.com/LAX1DUDE/eaglercraft";

View File

@ -429,6 +429,9 @@ public class Minecraft implements Runnable {
EaglerAdapter.glDisable(EaglerAdapter.GL_BLEND); EaglerAdapter.glDisable(EaglerAdapter.GL_BLEND);
EaglerAdapter.glEnable(EaglerAdapter.GL_ALPHA_TEST); EaglerAdapter.glEnable(EaglerAdapter.GL_ALPHA_TEST);
EaglerAdapter.glAlphaFunc(EaglerAdapter.GL_GREATER, 0.1F); EaglerAdapter.glAlphaFunc(EaglerAdapter.GL_GREATER, 0.1F);
while(EaglerAdapter.keysNext());
while(EaglerAdapter.mouseNext());
} }
/** /**
@ -496,9 +499,6 @@ public class Minecraft implements Runnable {
this.currentScreen.onGuiClosed(); this.currentScreen.onGuiClosed();
} }
while(EaglerAdapter.keysNext());
while(EaglerAdapter.mouseNext());
if (par1GuiScreen == null && this.theWorld == null) { if (par1GuiScreen == null && this.theWorld == null) {
par1GuiScreen = new GuiMainMenu(); par1GuiScreen = new GuiMainMenu();
} else if (par1GuiScreen == null && this.thePlayer.getHealth() <= 0) { } else if (par1GuiScreen == null && this.thePlayer.getHealth() <= 0) {