aboutsummaryrefslogtreecommitdiff
path: root/GuiTest/src/main/java
diff options
context:
space:
mode:
authorJuuz <6596629+Juuxel@users.noreply.github.com>2021-07-11 13:21:39 +0300
committerJuuz <6596629+Juuxel@users.noreply.github.com>2021-07-11 13:21:39 +0300
commit84a07a241ddc03be92680a077c9308695b66a179 (patch)
tree784abe3cd7e1682937209598d2c056b65b4f3d27 /GuiTest/src/main/java
parent9dfd9f06b2154b01bfc1acf01b6bf3eec27fccdd (diff)
downloadLibGui-84a07a241ddc03be92680a077c9308695b66a179.tar.gz
LibGui-84a07a241ddc03be92680a077c9308695b66a179.tar.bz2
LibGui-84a07a241ddc03be92680a077c9308695b66a179.zip
Update Yarn
Diffstat (limited to 'GuiTest/src/main/java')
-rw-r--r--GuiTest/src/main/java/io/github/cottonmc/test/GuiItem.java2
-rw-r--r--GuiTest/src/main/java/io/github/cottonmc/test/client/LibGuiTestClient.java8
2 files changed, 5 insertions, 5 deletions
diff --git a/GuiTest/src/main/java/io/github/cottonmc/test/GuiItem.java b/GuiTest/src/main/java/io/github/cottonmc/test/GuiItem.java
index 699c38e..278ddb9 100644
--- a/GuiTest/src/main/java/io/github/cottonmc/test/GuiItem.java
+++ b/GuiTest/src/main/java/io/github/cottonmc/test/GuiItem.java
@@ -32,6 +32,6 @@ public class GuiItem extends Item {
@Environment(EnvType.CLIENT)
private void openScreen() {
- MinecraftClient.getInstance().openScreen(new CottonClientScreen(new TestClientGui()));
+ MinecraftClient.getInstance().setScreen(new CottonClientScreen(new TestClientGui()));
}
}
diff --git a/GuiTest/src/main/java/io/github/cottonmc/test/client/LibGuiTestClient.java b/GuiTest/src/main/java/io/github/cottonmc/test/client/LibGuiTestClient.java
index 2f78fcd..02b1452 100644
--- a/GuiTest/src/main/java/io/github/cottonmc/test/client/LibGuiTestClient.java
+++ b/GuiTest/src/main/java/io/github/cottonmc/test/client/LibGuiTestClient.java
@@ -29,28 +29,28 @@ public class LibGuiTestClient implements ClientModInitializer {
.then(literal("config").executes(context -> {
var client = context.getSource().getClient();
client.send(() -> {
- client.openScreen(new CottonClientScreen(new ConfigGui(client.currentScreen)));
+ client.setScreen(new CottonClientScreen(new ConfigGui(client.currentScreen)));
});
return 0;
}))
.then(literal("tab").executes(context -> {
var client = context.getSource().getClient();
client.send(() -> {
- client.openScreen(new CottonClientScreen(new TabTestGui()));
+ client.setScreen(new CottonClientScreen(new TabTestGui()));
});
return 0;
}))
.then(literal("scrolling").executes(context -> {
var client = context.getSource().getClient();
client.send(() -> {
- client.openScreen(new CottonClientScreen(new ScrollingTestGui()));
+ client.setScreen(new CottonClientScreen(new ScrollingTestGui()));
});
return 0;
}))
.then(literal("insets").executes(context -> {
var client = context.getSource().getClient();
client.send(() -> {
- client.openScreen(new CottonClientScreen(new InsetsTestGui()));
+ client.setScreen(new CottonClientScreen(new InsetsTestGui()));
});
return 0;
}))