Skip to content

Commit

Permalink
Fix dedicated server GUI never showing up (#946)
Browse files Browse the repository at this point in the history
  • Loading branch information
sciwhiz12 authored May 10, 2024
1 parent 238a273 commit 212f760
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion patches/net/minecraft/server/Main.java.patch
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@
boolean flag2 = !optionset.has(optionspec) && !optionset.valuesOf(optionspec15).contains("nogui");
- if (flag2 && !GraphicsEnvironment.isHeadless()) {
- dedicatedserver1.showGui();
+ if (dedicatedserver1 instanceof DedicatedServer dedicatedServer && flag1 && !GraphicsEnvironment.isHeadless()) {
+ if (dedicatedserver1 instanceof DedicatedServer dedicatedServer && flag2 && !GraphicsEnvironment.isHeadless()) {
+ dedicatedServer.showGui();
}

Expand Down

0 comments on commit 212f760

Please sign in to comment.