aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/me/Danker/gui/OnlySlayerGui.java
diff options
context:
space:
mode:
authorbowser0000 <bowser0000@gmail.com>2020-10-16 15:20:27 -0400
committerbowser0000 <bowser0000@gmail.com>2020-10-16 15:20:27 -0400
commitff7001b95634e610a56220c58bc9619c063203da (patch)
treefdb0bffb128c4a3cf45584b5392ad5c46527cfc0 /src/main/java/me/Danker/gui/OnlySlayerGui.java
parent68111a9d9c9d403436dc2041010f337580d48d60 (diff)
downloadSkyblockMod-ff7001b95634e610a56220c58bc9619c063203da.tar.gz
SkyblockMod-ff7001b95634e610a56220c58bc9619c063203da.tar.bz2
SkyblockMod-ff7001b95634e610a56220c58bc9619c063203da.zip
Add ability to drag around displays WIP
WIP, buggy with scaling
Diffstat (limited to 'src/main/java/me/Danker/gui/OnlySlayerGui.java')
-rw-r--r--src/main/java/me/Danker/gui/OnlySlayerGui.java8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/main/java/me/Danker/gui/OnlySlayerGui.java b/src/main/java/me/Danker/gui/OnlySlayerGui.java
index 0573777..c96bfd6 100644
--- a/src/main/java/me/Danker/gui/OnlySlayerGui.java
+++ b/src/main/java/me/Danker/gui/OnlySlayerGui.java
@@ -1,5 +1,6 @@
package me.Danker.gui;
+import me.Danker.TheMod;
import me.Danker.commands.BlockSlayerCommand;
import me.Danker.handlers.ConfigHandler;
import me.Danker.handlers.TextRenderer;
@@ -13,6 +14,7 @@ public class OnlySlayerGui extends GuiScreen {
private int onlyNumberInt = 4;
private String onlyName = "Revenant Horror";
+ private GuiButton goBack;
private GuiButton off;
private GuiButton zombie;
private GuiButton spider;
@@ -46,6 +48,7 @@ public class OnlySlayerGui extends GuiScreen {
onlyNumberInt = 4;
}
+ goBack = new GuiButton(0, 2, height - 30, 100, 20, "Go Back");
off = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Off");
zombie = new GuiButton(0, width / 2 - 200, (int) (height * 0.4), 120, 20, "Zombie");
spider = new GuiButton(0, width / 2 - 60, (int) (height * 0.4), 120, 20, "Spider");
@@ -63,6 +66,7 @@ public class OnlySlayerGui extends GuiScreen {
this.buttonList.add(two);
this.buttonList.add(three);
this.buttonList.add(four);
+ this.buttonList.add(goBack);
}
@Override
@@ -84,7 +88,9 @@ public class OnlySlayerGui extends GuiScreen {
@Override
public void actionPerformed(GuiButton button) {
- if (button == off) {
+ if (button == goBack) {
+ TheMod.guiToOpen = "dankergui1";
+ } else if (button == off) {
BlockSlayerCommand.onlySlayerName = "";
BlockSlayerCommand.onlySlayerNumber = "";
ConfigHandler.writeStringConfig("toggles", "BlockSlayer", "");