From 511b95de7dcb83e047dce2adadeff8c18804c1b6 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Mon, 9 Nov 2020 14:50:39 -0500 Subject: Add config values for colours and many bug fixes Fix spooky fishing config values Add spooky fishing to /importfishing Add boolean to config to truely turn off chat Maddox Remove bold red name from three man puzzle answer Change spooky fishing to fishing spooky --- src/main/java/me/Danker/gui/DisplayGui.java | 10 +++++----- src/main/java/me/Danker/gui/EditLocationsGui.java | 5 +++-- 2 files changed, 8 insertions(+), 7 deletions(-) (limited to 'src/main/java/me/Danker/gui') diff --git a/src/main/java/me/Danker/gui/DisplayGui.java b/src/main/java/me/Danker/gui/DisplayGui.java index 9f00ed3..b944a2f 100644 --- a/src/main/java/me/Danker/gui/DisplayGui.java +++ b/src/main/java/me/Danker/gui/DisplayGui.java @@ -25,7 +25,7 @@ public class DisplayGui extends GuiScreen { private GuiButton fishing; private GuiButton fishingWinter; private GuiButton fishingFestival; - private GuiButton spookyFishing; + private GuiButton fishingSpooky; private GuiButton catacombsF1; private GuiButton catacombsF2; private GuiButton catacombsF3; @@ -57,7 +57,7 @@ public class DisplayGui extends GuiScreen { fishing = new GuiButton(0, width / 2 - 230, (int) (height * 0.4), 100, 20, "Fishing"); fishingWinter = new GuiButton(0, width / 2 - 110, (int) (height * 0.4), 100, 20, "Fishing Winter"); fishingFestival = new GuiButton(0, width / 2 + 10, (int) (height * 0.4), 100, 20, "Fishing Festival"); - spookyFishing = new GuiButton(0, width / 2 + 130, (int) (height * 0.4), 100, 20, "Spooky Fishing"); + fishingSpooky = new GuiButton(0, width / 2 + 130, (int) (height * 0.4), 100, 20, "Fishing Spooky"); catacombsF1 = new GuiButton(0, width / 2 - 145, (int) (height * 0.55), 50, 20, "F1"); catacombsF2 = new GuiButton(0, width / 2 - 85, (int) (height * 0.55), 50, 20, "F2"); catacombsF3 = new GuiButton(0, width / 2 - 25, (int) (height * 0.55), 50, 20, "F3"); @@ -74,7 +74,7 @@ public class DisplayGui extends GuiScreen { this.buttonList.add(fishing); this.buttonList.add(fishingWinter); this.buttonList.add(fishingFestival); - this.buttonList.add(spookyFishing); + this.buttonList.add(fishingSpooky); this.buttonList.add(catacombsF1); this.buttonList.add(catacombsF2); this.buttonList.add(catacombsF3); @@ -132,8 +132,8 @@ public class DisplayGui extends GuiScreen { setDisplay("fishing_winter", false); } else if (button == fishingFestival) { setDisplay("fishing_festival", false); - } else if (button == spookyFishing) { - setDisplay("spooky_fishing", false); + } else if (button == fishingSpooky) { + setDisplay("fishing_spooky", false); } else if (button == catacombsF1) { setDisplay("catacombs_floor_one", false); } else if (button == catacombsF2) { diff --git a/src/main/java/me/Danker/gui/EditLocationsGui.java b/src/main/java/me/Danker/gui/EditLocationsGui.java index f8b6712..c902c6c 100644 --- a/src/main/java/me/Danker/gui/EditLocationsGui.java +++ b/src/main/java/me/Danker/gui/EditLocationsGui.java @@ -1,5 +1,6 @@ package me.Danker.gui; +import me.Danker.TheMod; import me.Danker.commands.MoveCommand; import me.Danker.commands.ScaleCommand; import me.Danker.gui.buttons.LocationButton; @@ -71,8 +72,8 @@ public class EditLocationsGui extends GuiScreen { display = new LocationButton(0, moc.displayXY[0], moc.displayXY[1], 145 * sc.displayScale, 102 * sc.displayScale, sc.displayScale, displayText, displayNums, 110); dungeonTimer = new LocationButton(0, moc.dungeonTimerXY[0], moc.dungeonTimerXY[1], 113 * sc.dungeonTimerScale, 57 * sc.dungeonTimerScale, sc.dungeonTimerScale, dungeonTimerText, dungeonTimerNums, 80); - coords = new LocationButton(0, moc.coordsXY[0], moc.coordsXY[1], 141 * sc.coordsScale, 12 * sc.coordsScale, sc.coordsScale, "74 / 14 / -26 (141.1 / 6.7)", null, null); - skill50 = new LocationButton(0, moc.skill50XY[0], moc.skill50XY[1], 233 * sc.skill50Scale, 12 * sc.skill50Scale, sc.skill50Scale, EnumChatFormatting.AQUA + "+3.5 Farming (28,882,117.7/55,172,425) 52.34%", null, null); + coords = new LocationButton(0, moc.coordsXY[0], moc.coordsXY[1], 141 * sc.coordsScale, 12 * sc.coordsScale, sc.coordsScale, TheMod.COORDS_COLOUR + "74 / 14 / -26 (141.1 / 6.7)", null, null); + skill50 = new LocationButton(0, moc.skill50XY[0], moc.skill50XY[1], 233 * sc.skill50Scale, 12 * sc.skill50Scale, sc.skill50Scale, TheMod.SKILL_50_COLOUR + "+3.5 Farming (28,882,117.7/55,172,425) 52.34%", null, null); lividHP = new LocationButton(0, moc.lividHpXY[0], moc.lividHpXY[1], 85 * sc.lividHpScale, 12 * sc.lividHpScale, sc.lividHpScale, EnumChatFormatting.WHITE + "﴾ Livid " + EnumChatFormatting.YELLOW + "6.9M" + EnumChatFormatting.RED + "❤ " + EnumChatFormatting.WHITE + "﴿", null, null); this.buttonList.add(coords); -- cgit From 6cf3309708ca632fdeebd99a2a79f3a3471e549d Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Tue, 10 Nov 2020 23:24:17 -0500 Subject: Add display for time until century cakes run out --- README.md | 7 ++- src/main/java/me/Danker/TheMod.java | 63 ++++++++++++++++----- src/main/java/me/Danker/commands/DHelpCommand.java | 6 +- src/main/java/me/Danker/commands/MoveCommand.java | 10 +++- src/main/java/me/Danker/commands/ScaleCommand.java | 9 ++- .../java/me/Danker/commands/ToggleCommand.java | 60 +++++++++++--------- src/main/java/me/Danker/gui/DankerGui.java | 52 ++++++++++++----- src/main/java/me/Danker/gui/EditLocationsGui.java | 23 ++++++++ .../java/me/Danker/handlers/ConfigHandler.java | 12 ++++ src/main/resources/assets/dsm/icons/cake.png | Bin 0 -> 15381 bytes 10 files changed, 175 insertions(+), 67 deletions(-) create mode 100644 src/main/resources/assets/dsm/icons/cake.png (limited to 'src/main/java/me/Danker/gui') diff --git a/README.md b/README.md index b5ff14b..d00cd12 100644 --- a/README.md +++ b/README.md @@ -28,20 +28,21 @@ Discord Server: https://discord.gg/QsEkNQS - Pet background colors based on level - Golem spawning alerts (toggleable) - Show total skill xp instead of progress to next level +- Show time until century cakes run out - API commands - Update checker ## Commands - /dhelp - Returns this message in-game. - /dsm - Opens the GUI for Danker's Skyblock Mod. -- /toggle - Toggles features. /toggle list returns values of every toggle. +- /toggle - Toggles features. /toggle list returns values of every toggle. - /setkey - Sets API key. - /getkey - Returns key set with /setkey and copies it to your clipboard. - /loot [winter/spooky/f(1-6)/session] - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead. - /display [winter/spooky/f(1-6)/session] - Text display for trackers. /display fishing winter displays winter sea creatures instead. /display auto automatically displays the loot for the slayer quest you have active. - /resetloot - - Resets loot for trackers. /resetloot confirm confirms the reset. -- /move - Moves text display to specified X and Y coordinates. -- /scale - Scales text display to a specified multipler between 0.1x and 10x. +- /move - Moves text display to specified X and Y coordinates. +- /scale - Scales text display to a specified multipler between 0.1x and 10x. - /slayer [player] - Uses API to get slayer xp of a person. If no name is provided, it checks yours. - /skills [player] - Uses API to get skill levels of a person. If no name is provided, it checks yours. - /lobbyskills - Uses API to find the average skills of the lobby, as well the three players with the highest skill average. diff --git a/src/main/java/me/Danker/TheMod.java b/src/main/java/me/Danker/TheMod.java index 242cc17..06416a1 100644 --- a/src/main/java/me/Danker/TheMod.java +++ b/src/main/java/me/Danker/TheMod.java @@ -14,6 +14,7 @@ import java.util.regex.Pattern; import org.lwjgl.input.Keyboard; import org.lwjgl.input.Mouse; +import org.lwjgl.opengl.GL11; import com.google.gson.JsonObject; @@ -54,6 +55,7 @@ import me.Danker.utils.Utils; import net.minecraft.block.Block; import net.minecraft.client.Minecraft; import net.minecraft.client.entity.EntityPlayerSP; +import net.minecraft.client.gui.Gui; import net.minecraft.client.gui.inventory.GuiChest; import net.minecraft.client.settings.KeyBinding; import net.minecraft.entity.Entity; @@ -73,6 +75,7 @@ import net.minecraft.util.BlockPos; import net.minecraft.util.ChatComponentText; import net.minecraft.util.EnumChatFormatting; import net.minecraft.util.IChatComponent; +import net.minecraft.util.ResourceLocation; import net.minecraft.util.StringUtils; import net.minecraft.util.Vec3; import net.minecraftforge.client.ClientCommandHandler; @@ -97,7 +100,6 @@ import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; import net.minecraftforge.fml.common.eventhandler.EventPriority; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; import net.minecraftforge.fml.common.gameevent.InputEvent.KeyInputEvent; -import net.minecraftforge.fml.common.gameevent.PlayerEvent.PlayerChangedDimensionEvent; import net.minecraftforge.fml.common.gameevent.TickEvent; import net.minecraftforge.fml.common.network.FMLNetworkEvent.ClientConnectedToServerEvent; import net.minecraftforge.fml.common.versioning.DefaultArtifactVersion; @@ -139,6 +141,9 @@ public class TheMod static List creeperLines = new ArrayList(); static boolean foundLivid = false; static Entity livid = null; + public static double cakeTime; + + public static final ResourceLocation CAKE_ICON = new ResourceLocation("dsm", "icons/cake.png"); static double dungeonStartTime = 0; static double bloodOpenTime = 0; @@ -158,6 +163,7 @@ public class TheMod public static String ANSWER_COLOUR; public static String SKILL_50_COLOUR; public static String COORDS_COLOUR; + public static String CAKE_COLOUR; @EventHandler public void init(FMLInitializationEvent event) { @@ -376,8 +382,8 @@ public class TheMod for (String solution : riddleSolutions) { if (message.contains(solution)) { String npcName = message.substring(message.indexOf("]") + 2, message.indexOf(":")); - Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText(ANSWER_COLOUR + "" + EnumChatFormatting.BOLD + StringUtils.stripControlCodes(npcName) + MAIN_COLOUR + " has the blessing.")); - break; + Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText(ANSWER_COLOUR + EnumChatFormatting.BOLD + StringUtils.stripControlCodes(npcName) + MAIN_COLOUR + " has the blessing.")); + return; } } } @@ -423,6 +429,11 @@ public class TheMod } } + if (message.contains("Yum! You gain +") && message.contains(" for 48 hours!")) { + cakeTime = System.currentTimeMillis() / 1000 + 172800; // Add 48 hours + ConfigHandler.writeDoubleConfig("misc", "cakeTime", cakeTime); + } + final LootCommand lc = new LootCommand(); final ConfigHandler cf = new ConfigHandler(); boolean wolfRNG = false; @@ -999,8 +1010,10 @@ public class TheMod if (Minecraft.getMinecraft().currentScreen instanceof EditLocationsGui) return; + Minecraft mc = Minecraft.getMinecraft(); + if (tc.coordsToggled) { - EntityPlayer player = Minecraft.getMinecraft().thePlayer; + EntityPlayer player = mc.thePlayer; double xDir = (player.rotationYaw % 360 + 360) % 360; if (xDir > 180) xDir -= 360; @@ -1008,7 +1021,7 @@ public class TheMod double yDir = (double) Math.round(player.rotationPitch * 10d) / 10d; String coordText = COORDS_COLOUR + (int) player.posX + " / " + (int) player.posY + " / " + (int) player.posZ + " (" + xDir + " / " + yDir + ")"; - new TextRenderer(Minecraft.getMinecraft(), coordText, moc.coordsXY[0], moc.coordsXY[1], ScaleCommand.coordsScale); + new TextRenderer(mc, coordText, moc.coordsXY[0], moc.coordsXY[1], ScaleCommand.coordsScale); } if (tc.dungeonTimerToggled && Utils.inDungeons) { @@ -1024,12 +1037,32 @@ public class TheMod EnumChatFormatting.BLUE + Utils.getTimeBetween(dungeonStartTime, bossClearTime) + "\n" + EnumChatFormatting.YELLOW + dungeonDeaths + "\n" + EnumChatFormatting.YELLOW + puzzleFails; - new TextRenderer(Minecraft.getMinecraft(), dungeonTimerText, moc.dungeonTimerXY[0], moc.dungeonTimerXY[1], ScaleCommand.dungeonTimerScale); - new TextRenderer(Minecraft.getMinecraft(), dungeonTimers, (int) (moc.dungeonTimerXY[0] + (80 * ScaleCommand.dungeonTimerScale)), moc.dungeonTimerXY[1], ScaleCommand.dungeonTimerScale); + new TextRenderer(mc, dungeonTimerText, moc.dungeonTimerXY[0], moc.dungeonTimerXY[1], ScaleCommand.dungeonTimerScale); + new TextRenderer(mc, dungeonTimers, (int) (moc.dungeonTimerXY[0] + (80 * ScaleCommand.dungeonTimerScale)), moc.dungeonTimerXY[1], ScaleCommand.dungeonTimerScale); } if (tc.lividSolverToggled && foundLivid && livid != null) { - new TextRenderer(Minecraft.getMinecraft(), livid.getName().replace("" + EnumChatFormatting.BOLD, ""), moc.lividHpXY[0], moc.lividHpXY[1], ScaleCommand.lividHpScale); + new TextRenderer(mc, livid.getName().replace("" + EnumChatFormatting.BOLD, ""), moc.lividHpXY[0], moc.lividHpXY[1], ScaleCommand.lividHpScale); + } + + if (tc.cakeTimerToggled) { + double scale = ScaleCommand.cakeTimerScale; + double scaleReset = (double) Math.pow(scale, -1); + GL11.glScaled(scale, scale, scale); + + double timeNow = System.currentTimeMillis() / 1000; + mc.getTextureManager().bindTexture(CAKE_ICON); + Gui.drawModalRectWithCustomSizedTexture(moc.cakeTimerXY[0], moc.cakeTimerXY[1], 0, 0, 16, 16, 16, 16); + + String cakeText; + if (cakeTime - timeNow < 0) { + cakeText = EnumChatFormatting.RED + "NONE"; + } else { + cakeText = CAKE_COLOUR + Utils.getTimeBetween(timeNow, cakeTime); + } + new TextRenderer(mc, cakeText, moc.cakeTimerXY[0] + 20, moc.cakeTimerXY[1] + 5, 1); + + GL11.glScaled(scaleReset, scaleReset, scaleReset); } if (!ds.display.equals("off")) { @@ -1335,8 +1368,8 @@ public class TheMod EnumChatFormatting.AQUA + bossesBetween; if (tc.splitFishing) { - new TextRenderer(Minecraft.getMinecraft(), dropsTextTwo, (int) (moc.displayXY[0] + (160 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); - new TextRenderer(Minecraft.getMinecraft(), countTextTwo, (int) (moc.displayXY[0] + (270 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); + new TextRenderer(mc, dropsTextTwo, (int) (moc.displayXY[0] + (160 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); + new TextRenderer(mc, countTextTwo, (int) (moc.displayXY[0] + (270 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); } else { dropsText += "\n" + dropsTextTwo; countText += "\n" + countTextTwo; @@ -1396,8 +1429,8 @@ public class TheMod EnumChatFormatting.AQUA + bossesBetween; if (tc.splitFishing) { - new TextRenderer(Minecraft.getMinecraft(), dropsTextTwo, (int) (moc.displayXY[0] + (160 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); - new TextRenderer(Minecraft.getMinecraft(), countTextTwo, (int) (moc.displayXY[0] + (270 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); + new TextRenderer(mc, dropsTextTwo, (int) (moc.displayXY[0] + (160 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); + new TextRenderer(mc, countTextTwo, (int) (moc.displayXY[0] + (270 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); } else { dropsText += "\n" + dropsTextTwo; countText += "\n" + countTextTwo; @@ -1769,15 +1802,15 @@ public class TheMod ds.display = "off"; cf.writeStringConfig("misc", "display", "off"); } - new TextRenderer(Minecraft.getMinecraft(), dropsText, moc.displayXY[0], moc.displayXY[1], ScaleCommand.displayScale); - new TextRenderer(Minecraft.getMinecraft(), countText, (int) (moc.displayXY[0] + (110 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); + new TextRenderer(mc, dropsText, moc.displayXY[0], moc.displayXY[1], ScaleCommand.displayScale); + new TextRenderer(mc, countText, (int) (moc.displayXY[0] + (110 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); } if (showTitle) { Utils.drawTitle(titleText); } if (showSkill) { - new TextRenderer(Minecraft.getMinecraft(), skillText, moc.skill50XY[0], moc.skill50XY[1], ScaleCommand.skill50Scale); + new TextRenderer(mc, skillText, moc.skill50XY[0], moc.skill50XY[1], ScaleCommand.skill50Scale); } } diff --git a/src/main/java/me/Danker/commands/DHelpCommand.java b/src/main/java/me/Danker/commands/DHelpCommand.java index c4fd618..90c2be8 100644 --- a/src/main/java/me/Danker/commands/DHelpCommand.java +++ b/src/main/java/me/Danker/commands/DHelpCommand.java @@ -34,14 +34,14 @@ public class DHelpCommand extends CommandBase { EnumChatFormatting.GOLD + " Commands, " + EnumChatFormatting.GREEN + " Keybinds.\n" + EnumChatFormatting.GOLD + " /dhelp" + EnumChatFormatting.AQUA + " - Returns this message.\n" + EnumChatFormatting.GOLD + " /dsm" + EnumChatFormatting.AQUA + " - Opens the GUI for Danker's Skyblock Mod.\n" + - EnumChatFormatting.GOLD + " /toggle " + EnumChatFormatting.AQUA + " - Toggles features. /toggle list returns values of every toggle.\n" + + EnumChatFormatting.GOLD + " /toggle " + EnumChatFormatting.AQUA + " - Toggles features. /toggle list returns values of every toggle.\n" + EnumChatFormatting.GOLD + " /setkey " + EnumChatFormatting.AQUA + " - Sets API key.\n" + EnumChatFormatting.GOLD + " /getkey" + EnumChatFormatting.AQUA + " - Returns key set with /setkey and copies it to your clipboard.\n" + EnumChatFormatting.GOLD + " /loot [winter/festival/spooky/f(1-6)/session]" + EnumChatFormatting.AQUA + " - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead.\n" + EnumChatFormatting.GOLD + " /display [winter/festival/spooky/f(1-6)/session]" + EnumChatFormatting.AQUA + " - Text display for trackers. /display fishing winter displays winter sea creatures instead. /display auto automatically displays the loot for the slayer quest you have active.\n" + EnumChatFormatting.GOLD + " /resetloot " + EnumChatFormatting.AQUA + " - Resets loot for trackers. /resetloot confirm confirms the reset.\n" + - EnumChatFormatting.GOLD + " /move " + EnumChatFormatting.AQUA + " - Moves text display to specified X and Y coordinates.\n" + - EnumChatFormatting.GOLD + " /scale " + EnumChatFormatting.AQUA + " - Scales text display to a specified multipler between 0.1x and 10x.\n" + + EnumChatFormatting.GOLD + " /move " + EnumChatFormatting.AQUA + " - Moves text display to specified X and Y coordinates.\n" + + EnumChatFormatting.GOLD + " /scale " + EnumChatFormatting.AQUA + " - Scales text display to a specified multipler between 0.1x and 10x.\n" + EnumChatFormatting.GOLD + " /slayer [player]" + EnumChatFormatting.AQUA + " - Uses API to get slayer xp of a person. If no name is provided, it checks yours.\n" + EnumChatFormatting.GOLD + " /skills [player]" + EnumChatFormatting.AQUA + " - Uses API to get skill levels of a person. If no name is provided, it checks yours.\n" + EnumChatFormatting.GOLD + " /lobbyskills" + EnumChatFormatting.AQUA + " - Uses API to find the average skills of the lobby, as well the three players with the highest skill average.\n" + diff --git a/src/main/java/me/Danker/commands/MoveCommand.java b/src/main/java/me/Danker/commands/MoveCommand.java index 1a68528..a3f5e3b 100644 --- a/src/main/java/me/Danker/commands/MoveCommand.java +++ b/src/main/java/me/Danker/commands/MoveCommand.java @@ -19,6 +19,7 @@ public class MoveCommand extends CommandBase { public static int[] dungeonTimerXY = {0, 0}; public static int[] skill50XY = {0, 0}; public static int[] lividHpXY = {0, 0}; + public static int[] cakeTimerXY = {0, 0}; @Override public String getCommandName() { @@ -27,7 +28,7 @@ public class MoveCommand extends CommandBase { @Override public String getCommandUsage(ICommandSender arg0) { - return "/" + getCommandName() + " "; + return "/" + getCommandName() + " "; } @Override @@ -38,7 +39,7 @@ public class MoveCommand extends CommandBase { @Override public List addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) { if (args.length == 1) { - return getListOfStringsMatchingLastWord(args, "coords", "display", "dungeontimer", "skill50", "lividhp"); + return getListOfStringsMatchingLastWord(args, "coords", "display", "dungeontimer", "skill50", "lividhp", "caketimer"); } return null; } @@ -83,6 +84,11 @@ public class MoveCommand extends CommandBase { cf.writeIntConfig("locations", "lividHpX", lividHpXY[0]); cf.writeIntConfig("locations", "lividHpY", lividHpXY[1]); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Livid HP has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); + } else if (arg1[0].equalsIgnoreCase("caketimer")) { + cakeTimerXY[0] = Integer.parseInt(arg1[1]); + cakeTimerXY[1] = Integer.parseInt(arg1[2]); + cf.writeIntConfig("locations", "cakeTimerX", cakeTimerXY[0]); + cf.writeIntConfig("locations", "cakeTimerY", cakeTimerXY[1]); } else { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); } diff --git a/src/main/java/me/Danker/commands/ScaleCommand.java b/src/main/java/me/Danker/commands/ScaleCommand.java index 0fdbafd..fa4c51d 100644 --- a/src/main/java/me/Danker/commands/ScaleCommand.java +++ b/src/main/java/me/Danker/commands/ScaleCommand.java @@ -19,6 +19,7 @@ public class ScaleCommand extends CommandBase { public static double dungeonTimerScale; public static double skill50Scale; public static double lividHpScale; + public static double cakeTimerScale; @Override public String getCommandName() { @@ -27,7 +28,7 @@ public class ScaleCommand extends CommandBase { @Override public String getCommandUsage(ICommandSender arg0) { - return "/" + getCommandName() + " "; + return "/" + getCommandName() + " "; } @Override @@ -38,7 +39,7 @@ public class ScaleCommand extends CommandBase { @Override public List addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) { if (args.length == 1) { - return getListOfStringsMatchingLastWord(args, "coords", "display", "dungeontimer", "skill50", "lividhp"); + return getListOfStringsMatchingLastWord(args, "coords", "display", "dungeontimer", "skill50", "lividhp", "caketimer"); } return null; } @@ -78,6 +79,10 @@ public class ScaleCommand extends CommandBase { lividHpScale = scaleAmount; ConfigHandler.writeDoubleConfig("scales", "lividHpScale", lividHpScale); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Livid HP has been scaled to " + TheMod.SECONDARY_COLOUR + lividHpScale + "x")); + } else if (arg1[0].equalsIgnoreCase("caketimer")) { + cakeTimerScale = scaleAmount; + ConfigHandler.writeDoubleConfig("scales", "cakeTimerScale", cakeTimerScale); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Cake timer has been scaled to " + TheMod.SECONDARY_COLOUR + cakeTimerScale + "x")); } else { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); } diff --git a/src/main/java/me/Danker/commands/ToggleCommand.java b/src/main/java/me/Danker/commands/ToggleCommand.java index 27b55f0..473c29a 100644 --- a/src/main/java/me/Danker/commands/ToggleCommand.java +++ b/src/main/java/me/Danker/commands/ToggleCommand.java @@ -33,6 +33,7 @@ public class ToggleCommand extends CommandBase implements ICommand { public static boolean skill50DisplayToggled; public static boolean outlineTextToggled; public static boolean midasStaffMessages; + public static boolean cakeTimerToggled; public static boolean lividSolverToggled; // Puzzle Solvers public static boolean threeManToggled; @@ -49,7 +50,7 @@ public class ToggleCommand extends CommandBase implements ICommand { public String getCommandUsage(ICommandSender arg0) { return "/" + getCommandName() + " "; + "outlinetext/midasstaffmessages/caketimer/lividsolver/threemanpuzzle/oruopuzzle/blazepuzzle/creeperpuzzle/list>"; } @Override @@ -64,8 +65,8 @@ public class ToggleCommand extends CommandBase implements ICommand { "splitfishing", "chatmaddox", "spiritbearalerts", "aotd", "lividdagger", "sceptremessages", "petcolors", "dungeontimer", "golemalerts", "expertiselore", "skill50display", "outlinetext", "midasstaffmessages", - "lividsolver", "threemanpuzzle", "oruopuzzle", "blazepuzzle", "creeperpuzzle", - "list"); + "caketimer", "lividsolver", "threemanpuzzle", "oruopuzzle", "blazepuzzle", + "creeperpuzzle", "list"); } return null; } @@ -152,7 +153,11 @@ public class ToggleCommand extends CommandBase implements ICommand { midasStaffMessages = !midasStaffMessages; cf.writeBooleanConfig("toggles", "MidasStaffMessages", midasStaffMessages); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Midas Staff messages have been set to " + TheMod.SECONDARY_COLOUR + midasStaffMessages + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("lividsolver")) { + } else if (arg1[0].equalsIgnoreCase("caketimer")) { + cakeTimerToggled = !cakeTimerToggled; + cf.writeBooleanConfig("toggles", "CakeTimer", cakeTimerToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Cake timer has been set to " + TheMod.SECONDARY_COLOUR + cakeTimerToggled + TheMod.MAIN_COLOUR + ".")); + } else if (arg1[0].equalsIgnoreCase("lividsolver")) { lividSolverToggled = !lividSolverToggled; cf.writeBooleanConfig("toggles", "LividSolver", lividSolverToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Livid solver has been set to " + TheMod.SECONDARY_COLOUR + lividSolverToggled + TheMod.MAIN_COLOUR + ".")); @@ -173,29 +178,30 @@ public class ToggleCommand extends CommandBase implements ICommand { cf.writeBooleanConfig("creeperpuzzle", "CreeperPuzzle", creeperToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Creeper puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + creeperToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("list")) { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.GREEN + "Guild party notifications: " + EnumChatFormatting.DARK_GREEN + gpartyToggled + "\n" + - EnumChatFormatting.GREEN + " Coord/Angle display: " + EnumChatFormatting.DARK_GREEN + coordsToggled + "\n" + - EnumChatFormatting.GREEN + " Golden T6 enchants: " + EnumChatFormatting.DARK_GREEN + goldenToggled + "\n" + - EnumChatFormatting.GREEN + " Counting total 20% slayer drops: " + EnumChatFormatting.DARK_GREEN + slayerCountTotal + "\n" + - EnumChatFormatting.GREEN + " Slayer RNGesus alerts: " + EnumChatFormatting.DARK_GREEN + rngesusAlerts + "\n" + - EnumChatFormatting.GREEN + " Split fishing display: " + EnumChatFormatting.DARK_GREEN + splitFishing + "\n" + - EnumChatFormatting.GREEN + " Chat Maddox menu: " + EnumChatFormatting.DARK_GREEN + chatMaddoxToggled + "\n" + - EnumChatFormatting.GREEN + " Spirit Bear alerts: " + EnumChatFormatting.DARK_GREEN + spiritBearAlerts + "\n" + - EnumChatFormatting.GREEN + " Block AOTD ability: " + EnumChatFormatting.DARK_GREEN + aotdToggled + "\n" + - EnumChatFormatting.GREEN + " Block Livid Dagger ability: " + EnumChatFormatting.DARK_GREEN + lividDaggerToggled + "\n" + - EnumChatFormatting.GREEN + " Spirit Sceptre messages: " + EnumChatFormatting.DARK_GREEN + sceptreMessages + "\n" + - EnumChatFormatting.GREEN + " Pet colours: " + EnumChatFormatting.DARK_GREEN + petColoursToggled + "\n" + - EnumChatFormatting.GREEN + " Dungeon timer: " + EnumChatFormatting.DARK_GREEN + dungeonTimerToggled + "\n" + - EnumChatFormatting.GREEN + " Golem spawn alerts: " + EnumChatFormatting.DARK_GREEN + golemAlertToggled + "\n" + - EnumChatFormatting.GREEN + " Expertise in lore: " + EnumChatFormatting.DARK_GREEN + expertiseLoreToggled + "\n" + - EnumChatFormatting.GREEN + " Skill 50 display: " + EnumChatFormatting.DARK_GREEN + skill50DisplayToggled + "\n" + - EnumChatFormatting.GREEN + " Outline displayed text: " + EnumChatFormatting.DARK_GREEN + outlineTextToggled + "\n" + - EnumChatFormatting.GREEN + " Midas Staff messages: " + EnumChatFormatting.DARK_GREEN + midasStaffMessages + "\n" + - EnumChatFormatting.GREEN + " Livid solver: " + EnumChatFormatting.DARK_GREEN + lividSolverToggled + "\n" + - EnumChatFormatting.GREEN + " Three man puzzle solver: " + EnumChatFormatting.DARK_GREEN + threeManToggled + "\n" + - EnumChatFormatting.GREEN + " Oruo trivia solver: " + EnumChatFormatting.DARK_GREEN + oruoToggled + "\n" + - EnumChatFormatting.GREEN + " Blaze puzzle solver: " + EnumChatFormatting.DARK_GREEN + blazeToggled + "\n" + - EnumChatFormatting.GREEN + " Creeper puzzle solver: " + EnumChatFormatting.DARK_GREEN + creeperToggled)); + player.addChatMessage(new ChatComponentText(TheMod.TYPE_COLOUR + "Guild party notifications: " + TheMod.VALUE_COLOUR + gpartyToggled + "\n" + + TheMod.TYPE_COLOUR + " Coord/Angle display: " + TheMod.VALUE_COLOUR + coordsToggled + "\n" + + TheMod.TYPE_COLOUR + " Golden T6 enchants: " + TheMod.VALUE_COLOUR + goldenToggled + "\n" + + TheMod.TYPE_COLOUR + " Counting total 20% slayer drops: " + TheMod.VALUE_COLOUR + slayerCountTotal + "\n" + + TheMod.TYPE_COLOUR + " Slayer RNGesus alerts: " + TheMod.VALUE_COLOUR + rngesusAlerts + "\n" + + TheMod.TYPE_COLOUR + " Split fishing display: " + TheMod.VALUE_COLOUR + splitFishing + "\n" + + TheMod.TYPE_COLOUR + " Chat Maddox menu: " + TheMod.VALUE_COLOUR + chatMaddoxToggled + "\n" + + TheMod.TYPE_COLOUR + " Spirit Bear alerts: " + TheMod.VALUE_COLOUR + spiritBearAlerts + "\n" + + TheMod.TYPE_COLOUR + " Block AOTD ability: " + TheMod.VALUE_COLOUR + aotdToggled + "\n" + + TheMod.TYPE_COLOUR + " Block Livid Dagger ability: " + TheMod.VALUE_COLOUR + lividDaggerToggled + "\n" + + TheMod.TYPE_COLOUR + " Spirit Sceptre messages: " + TheMod.VALUE_COLOUR + sceptreMessages + "\n" + + TheMod.TYPE_COLOUR + " Pet colours: " + TheMod.VALUE_COLOUR + petColoursToggled + "\n" + + TheMod.TYPE_COLOUR + " Dungeon timer: " + TheMod.VALUE_COLOUR + dungeonTimerToggled + "\n" + + TheMod.TYPE_COLOUR + " Golem spawn alerts: " + TheMod.VALUE_COLOUR + golemAlertToggled + "\n" + + TheMod.TYPE_COLOUR + " Expertise in lore: " + TheMod.VALUE_COLOUR + expertiseLoreToggled + "\n" + + TheMod.TYPE_COLOUR + " Skill 50 display: " + TheMod.VALUE_COLOUR + skill50DisplayToggled + "\n" + + TheMod.TYPE_COLOUR + " Outline displayed text: " + TheMod.VALUE_COLOUR + outlineTextToggled + "\n" + + TheMod.TYPE_COLOUR + " Midas Staff messages: " + TheMod.VALUE_COLOUR + midasStaffMessages + "\n" + + TheMod.TYPE_COLOUR + " Cake timer: " + TheMod.VALUE_COLOUR + cakeTimerToggled + "\n" + + TheMod.TYPE_COLOUR + " Livid solver: " + TheMod.VALUE_COLOUR + lividSolverToggled + "\n" + + TheMod.TYPE_COLOUR + " Three man puzzle solver: " + TheMod.VALUE_COLOUR + threeManToggled + "\n" + + TheMod.TYPE_COLOUR + " Oruo trivia solver: " + TheMod.VALUE_COLOUR + oruoToggled + "\n" + + TheMod.TYPE_COLOUR + " Blaze puzzle solver: " + TheMod.VALUE_COLOUR + blazeToggled + "\n" + + TheMod.TYPE_COLOUR + " Creeper puzzle solver: " + TheMod.VALUE_COLOUR + creeperToggled)); } else { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); } diff --git a/src/main/java/me/Danker/gui/DankerGui.java b/src/main/java/me/Danker/gui/DankerGui.java index 15e0fa5..1bf7911 100644 --- a/src/main/java/me/Danker/gui/DankerGui.java +++ b/src/main/java/me/Danker/gui/DankerGui.java @@ -8,6 +8,7 @@ import java.net.URISyntaxException; import me.Danker.TheMod; import me.Danker.commands.ToggleCommand; import me.Danker.handlers.ConfigHandler; +import me.Danker.handlers.TextRenderer; import me.Danker.utils.Utils; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiButton; @@ -46,6 +47,7 @@ public class DankerGui extends GuiScreen { private GuiButton skill50Display; private GuiButton outlineText; private GuiButton midasStaffMessages; + private GuiButton cakeTimer; private GuiButton lividSolver; public DankerGui(int page) { @@ -81,21 +83,24 @@ public class DankerGui extends GuiScreen { dungeonTimer = new GuiButton(0, width / 2 - 100, (int) (height * 0.6), "Display Dungeon Timers: " + Utils.getColouredBoolean(ToggleCommand.dungeonTimerToggled)); coords = new GuiButton(0, width / 2 - 100, (int) (height * 0.7), "Coordinate/Angle Display: " + Utils.getColouredBoolean(ToggleCommand.coordsToggled)); // Page 2 - gparty = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Guild Party Notifications: " + Utils.getColouredBoolean(ToggleCommand.gpartyToggled)); - goldenEnch = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Golden T10/T6/T4 Enchantments: " + Utils.getColouredBoolean(ToggleCommand.goldenToggled)); - slayerCount = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Count Total 20% Drops: " + Utils.getColouredBoolean(ToggleCommand.slayerCountTotal)); - chatMaddox = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Click Chat to Open Maddox: " + Utils.getColouredBoolean(ToggleCommand.chatMaddoxToggled)); - spiritBearAlert = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Spirit Bear Spawn Alerts: " + Utils.getColouredBoolean(ToggleCommand.spiritBearAlerts)); + cakeTimer = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Cake Timer: " + Utils.getColouredBoolean(ToggleCommand.cakeTimerToggled)); + skill50Display = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Display Progress To Skill Level 50: " + Utils.getColouredBoolean(ToggleCommand.skill50DisplayToggled)); + gparty = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Guild Party Notifications: " + Utils.getColouredBoolean(ToggleCommand.gpartyToggled)); + slayerCount = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Count Total 20% Drops: " + Utils.getColouredBoolean(ToggleCommand.slayerCountTotal)); + chatMaddox = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Click Chat to Open Maddox: " + Utils.getColouredBoolean(ToggleCommand.chatMaddoxToggled)); aotd = new GuiButton(0, width / 2 - 100, (int) (height * 0.6), "Disable AOTD Ability: " + Utils.getColouredBoolean(ToggleCommand.aotdToggled)); lividDagger = new GuiButton(0, width / 2 - 100, (int) (height * 0.7), "Disable Livid Dagger Ability: " + Utils.getColouredBoolean(ToggleCommand.lividDaggerToggled)); // Page 3 - sceptreMessages = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Spirit Sceptre Messages: " + Utils.getColouredBoolean(ToggleCommand.sceptreMessages)); - midasStaffMessages = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Midas Staff Messages: " + Utils.getColouredBoolean(ToggleCommand.midasStaffMessages)); - petColours = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Colour Pet Backgrounds: " + Utils.getColouredBoolean(ToggleCommand.petColoursToggled)); - golemAlerts = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Alert When Golem Spawns: " + Utils.getColouredBoolean(ToggleCommand.golemAlertToggled)); - expertiseLore = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Expertise Kills In Lore: " + Utils.getColouredBoolean(ToggleCommand.expertiseLoreToggled)); - skill50Display = new GuiButton(0, width / 2 - 100, (int) (height * 0.6), "Display Progress To Skill Level 50: " + Utils.getColouredBoolean(ToggleCommand.skill50DisplayToggled)); + spiritBearAlert = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Spirit Bear Spawn Alerts: " + Utils.getColouredBoolean(ToggleCommand.spiritBearAlerts)); + sceptreMessages = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Spirit Sceptre Messages: " + Utils.getColouredBoolean(ToggleCommand.sceptreMessages)); + midasStaffMessages = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Midas Staff Messages: " + Utils.getColouredBoolean(ToggleCommand.midasStaffMessages)); + goldenEnch = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Golden T10/T6/T4 Enchantments: " + Utils.getColouredBoolean(ToggleCommand.goldenToggled)); + petColours = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Colour Pet Backgrounds: " + Utils.getColouredBoolean(ToggleCommand.petColoursToggled)); + expertiseLore = new GuiButton(0, width / 2 - 100, (int) (height * 0.6), "Expertise Kills In Lore: " + Utils.getColouredBoolean(ToggleCommand.expertiseLoreToggled)); lividSolver = new GuiButton(0, width / 2 - 100, (int) (height * 0.7), "Find Correct Livid: " + Utils.getColouredBoolean(ToggleCommand.lividSolverToggled)); + // Page 4 + golemAlerts = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Alert When Golem Spawns: " + Utils.getColouredBoolean(ToggleCommand.golemAlertToggled)); + rngesusAlert = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "RNGesus Alerts: " + Utils.getColouredBoolean(ToggleCommand.rngesusAlerts)); if (page == 1) { this.buttonList.add(changeDisplay); @@ -107,25 +112,31 @@ public class DankerGui extends GuiScreen { this.buttonList.add(coords); this.buttonList.add(nextPage); } else if (page == 2) { + this.buttonList.add(cakeTimer); + this.buttonList.add(skill50Display); this.buttonList.add(gparty); - this.buttonList.add(goldenEnch); this.buttonList.add(slayerCount); this.buttonList.add(chatMaddox); - this.buttonList.add(spiritBearAlert); this.buttonList.add(aotd); this.buttonList.add(lividDagger); this.buttonList.add(nextPage); this.buttonList.add(backPage); } else if (page == 3) { + this.buttonList.add(spiritBearAlert); this.buttonList.add(sceptreMessages); this.buttonList.add(midasStaffMessages); + this.buttonList.add(goldenEnch); this.buttonList.add(petColours); - this.buttonList.add(golemAlerts); this.buttonList.add(expertiseLore); - this.buttonList.add(skill50Display); this.buttonList.add(lividSolver); + this.buttonList.add(nextPage); + this.buttonList.add(backPage); + } else if (page == 4) { + this.buttonList.add(golemAlerts); + this.buttonList.add(rngesusAlert); this.buttonList.add(backPage); } + this.buttonList.add(githubLink); this.buttonList.add(discordLink); this.buttonList.add(closeGUI); @@ -134,6 +145,9 @@ public class DankerGui extends GuiScreen { @Override public void drawScreen(int mouseX, int mouseY, float partialTicks) { this.drawDefaultBackground(); + String pageText = "Page: " + page + "/4"; + int pageWidth = mc.fontRendererObj.getStringWidth(pageText); + new TextRenderer(mc, pageText, width / 2 - pageWidth / 2, 10, 1D); super.drawScreen(mouseX, mouseY, partialTicks); } @@ -235,6 +249,14 @@ public class DankerGui extends GuiScreen { ToggleCommand.lividSolverToggled = !ToggleCommand.lividSolverToggled; ConfigHandler.writeBooleanConfig("toggles", "LividSolver", ToggleCommand.lividSolverToggled); lividSolver.displayString = "Find Correct Livid: " + Utils.getColouredBoolean(ToggleCommand.lividSolverToggled); + } else if (button == rngesusAlert) { + ToggleCommand.rngesusAlerts = !ToggleCommand.rngesusAlerts; + ConfigHandler.writeBooleanConfig("toggles", "RNGesusAlerts", ToggleCommand.rngesusAlerts); + rngesusAlert.displayString = "RNGesus Alerts: " + Utils.getColouredBoolean(ToggleCommand.rngesusAlerts); + } else if (button == cakeTimer) { + ToggleCommand.cakeTimerToggled = !ToggleCommand.cakeTimerToggled; + ConfigHandler.writeBooleanConfig("toggles", "CakeTimer", ToggleCommand.cakeTimerToggled); + cakeTimer.displayString = "Cake Timer: " + Utils.getColouredBoolean(ToggleCommand.cakeTimerToggled); } } diff --git a/src/main/java/me/Danker/gui/EditLocationsGui.java b/src/main/java/me/Danker/gui/EditLocationsGui.java index c902c6c..d8034e6 100644 --- a/src/main/java/me/Danker/gui/EditLocationsGui.java +++ b/src/main/java/me/Danker/gui/EditLocationsGui.java @@ -1,11 +1,14 @@ package me.Danker.gui; +import org.lwjgl.opengl.GL11; + import me.Danker.TheMod; import me.Danker.commands.MoveCommand; import me.Danker.commands.ScaleCommand; import me.Danker.gui.buttons.LocationButton; import me.Danker.handlers.ConfigHandler; import me.Danker.utils.Utils; +import net.minecraft.client.gui.Gui; import net.minecraft.client.gui.GuiButton; import net.minecraft.client.gui.GuiScreen; import net.minecraft.util.EnumChatFormatting; @@ -21,6 +24,7 @@ public class EditLocationsGui extends GuiScreen { private LocationButton coords; private LocationButton skill50; private LocationButton lividHP; + private LocationButton cakeTimer; @Override public boolean doesGuiPauseGame() { @@ -75,10 +79,12 @@ public class EditLocationsGui extends GuiScreen { coords = new LocationButton(0, moc.coordsXY[0], moc.coordsXY[1], 141 * sc.coordsScale, 12 * sc.coordsScale, sc.coordsScale, TheMod.COORDS_COLOUR + "74 / 14 / -26 (141.1 / 6.7)", null, null); skill50 = new LocationButton(0, moc.skill50XY[0], moc.skill50XY[1], 233 * sc.skill50Scale, 12 * sc.skill50Scale, sc.skill50Scale, TheMod.SKILL_50_COLOUR + "+3.5 Farming (28,882,117.7/55,172,425) 52.34%", null, null); lividHP = new LocationButton(0, moc.lividHpXY[0], moc.lividHpXY[1], 85 * sc.lividHpScale, 12 * sc.lividHpScale, sc.lividHpScale, EnumChatFormatting.WHITE + "﴾ Livid " + EnumChatFormatting.YELLOW + "6.9M" + EnumChatFormatting.RED + "❤ " + EnumChatFormatting.WHITE + "﴿", null, null); + cakeTimer = new LocationButton(0, moc.cakeTimerXY[0], moc.cakeTimerXY[1] + 5, 85 * sc.cakeTimerScale, 18 * sc.cakeTimerScale, sc.cakeTimerScale, TheMod.CAKE_COLOUR + " 11h16m", null, null); this.buttonList.add(coords); this.buttonList.add(dungeonTimer); this.buttonList.add(lividHP); + this.buttonList.add(cakeTimer); this.buttonList.add(display); this.buttonList.add(skill50); } @@ -87,6 +93,14 @@ public class EditLocationsGui extends GuiScreen { public void drawScreen(int mouseX, int mouseY, float partialTicks) { this.drawDefaultBackground(); mouseMoved(mouseX, mouseY); + + double scale = ScaleCommand.cakeTimerScale; + double scaleReset = (double) Math.pow(scale, -1); + GL11.glScaled(scale, scale, scale); + mc.getTextureManager().bindTexture(TheMod.CAKE_ICON); + Gui.drawModalRectWithCustomSizedTexture(MoveCommand.cakeTimerXY[0], MoveCommand.cakeTimerXY[1], 0, 0, 16, 16, 16, 16); + GL11.glScaled(scaleReset, scaleReset, scaleReset); + super.drawScreen(mouseX, mouseY, partialTicks); } @@ -120,6 +134,11 @@ public class EditLocationsGui extends GuiScreen { MoveCommand.lividHpXY[1] += yMoved; lividHP.xPosition = MoveCommand.lividHpXY[0]; lividHP.yPosition = MoveCommand.lividHpXY[1]; + } else if (moving.equals("cakeTimer")) { + MoveCommand.cakeTimerXY[0] += xMoved; + MoveCommand.cakeTimerXY[1] += yMoved; + cakeTimer.xPosition = MoveCommand.cakeTimerXY[0]; + cakeTimer.yPosition = MoveCommand.cakeTimerXY[1]; } this.buttonList.clear(); initGui(); @@ -142,6 +161,8 @@ public class EditLocationsGui extends GuiScreen { moving = "skill50"; } else if (button == lividHP) { moving = "lividHP"; + } else if (button == cakeTimer) { + moving = "cakeTimer"; } } } @@ -160,6 +181,8 @@ public class EditLocationsGui extends GuiScreen { ConfigHandler.writeIntConfig("locations", "skill50Y", MoveCommand.skill50XY[1]); ConfigHandler.writeIntConfig("locations", "lividHpX", MoveCommand.lividHpXY[0]); ConfigHandler.writeIntConfig("locations", "lividHpY", MoveCommand.lividHpXY[1]); + ConfigHandler.writeIntConfig("locations", "cakeTimerX", MoveCommand.cakeTimerXY[0]); + ConfigHandler.writeIntConfig("locations", "cakeTimerY", MoveCommand.cakeTimerXY[1]); } } diff --git a/src/main/java/me/Danker/handlers/ConfigHandler.java b/src/main/java/me/Danker/handlers/ConfigHandler.java index 98cc35e..7473e43 100644 --- a/src/main/java/me/Danker/handlers/ConfigHandler.java +++ b/src/main/java/me/Danker/handlers/ConfigHandler.java @@ -191,6 +191,7 @@ public class ConfigHandler { if (!hasKey("toggles", "Skill50Display")) writeBooleanConfig("toggles", "Skill50Display", false); if (!hasKey("toggles", "OutlineText")) writeBooleanConfig("toggles", "OutlineText", false); if (!hasKey("toggles", "MidasStaffMessages")) writeBooleanConfig("toggles", "MidasStaffMessages", true); + if (!hasKey("toggles", "CakeTimer")) writeBooleanConfig("toggles", "CakeTimer", false); if (!hasKey("toggles", "LividSolver")) writeBooleanConfig("toggles", "LividSolver", false); // Puzzle Solvers if (!hasKey("toggles", "ThreeManPuzzle")) writeBooleanConfig("toggles", "ThreeManPuzzle", false); @@ -336,6 +337,7 @@ public class ConfigHandler { if (!hasKey("misc", "autoDisplay")) writeBooleanConfig("misc", "autoDisplay", false); if (!hasKey("misc", "skill50Time")) writeIntConfig("misc", "skill50Time", 3); if (!hasKey("misc", "trueChatMaddoxEnabled")) writeBooleanConfig("misc", "trueChatMaddoxEnabled", true); + if (!hasKey("misc", "cakeTime")) writeDoubleConfig("misc", "cakeTime", 0); ScaledResolution scaled = new ScaledResolution(Minecraft.getMinecraft()); int height = scaled.getScaledHeight(); @@ -349,11 +351,14 @@ public class ConfigHandler { if (!hasKey("locations", "skill50Y")) writeIntConfig("locations", "skill50Y", 10); if (!hasKey("locations", "lividHpX")) writeIntConfig("locations", "lividHpX", 40); if (!hasKey("locations", "lividHpY")) writeIntConfig("locations", "lividHpY", 20); + if (!hasKey("locations", "cakeTimerX")) writeIntConfig("locations", "cakeTimerX", 40); + if (!hasKey("locations", "cakeTimerY")) writeIntConfig("locations", "cakeTimerY", 30); if (!hasKey("scales", "coordsScale")) writeDoubleConfig("scales", "coordsScale", 1); if (!hasKey("scales", "displayScale")) writeDoubleConfig("scales", "displayScale", 1); if (!hasKey("scales", "dungeonTimerScale")) writeDoubleConfig("scales", "dungeonTimerScale", 1); if (!hasKey("scales", "skill50Scale")) writeDoubleConfig("scales", "skill50Scale", 1); if (!hasKey("scales", "lividHpScale")) writeDoubleConfig("scales", "lividHpScale", 1); + if (!hasKey("scales", "cakeTimerScale")) writeDoubleConfig("scales", "cakeTimerScale", 1); if (!hasKey("colors", "main")) writeStringConfig("colors", "main", "" + EnumChatFormatting.GREEN); if (!hasKey("colors", "secondary")) writeStringConfig("colors", "secondary", "" + EnumChatFormatting.DARK_GREEN); @@ -365,6 +370,7 @@ public class ConfigHandler { if (!hasKey("colors", "answer")) writeStringConfig("colors", "answer", "" + EnumChatFormatting.DARK_GREEN); if (!hasKey("colors", "skill50Display")) writeStringConfig("colors", "skill50Display", "" + EnumChatFormatting.AQUA); if (!hasKey("colors", "coordsDisplay")) writeStringConfig("colors", "coordsDisplay", "" + EnumChatFormatting.WHITE); + if (!hasKey("colors", "cakeDisplay")) writeStringConfig("colors", "cakeDisplay", "" + EnumChatFormatting.GOLD); final ToggleCommand tf = new ToggleCommand(); tf.gpartyToggled = getBoolean("toggles", "GParty"); @@ -385,6 +391,7 @@ public class ConfigHandler { tf.skill50DisplayToggled = getBoolean("toggles", "Skill50Display"); tf.outlineTextToggled = getBoolean("toggles", "OutlineText"); tf.midasStaffMessages = getBoolean("toggles", "MidasStaffMessages"); + tf.cakeTimerToggled = getBoolean("toggles", "CakeTimer"); tf.lividSolverToggled = getBoolean("toggles", "LividSolver"); // Puzzle Solvers tf.threeManToggled = getBoolean("toggles", "ThreeManPuzzle"); @@ -537,6 +544,7 @@ public class ConfigHandler { ds.auto = getBoolean("misc", "autoDisplay"); TheMod.SKILL_TIME = getInt("misc", "skill50Time") * 20; tf.trueChatMaddoxEnabled = getBoolean("misc", "trueChatMaddoxEnabled"); + TheMod.cakeTime = getDouble("misc", "cakeTime"); final MoveCommand moc = new MoveCommand(); moc.coordsXY[0] = getInt("locations", "coordsX"); @@ -549,6 +557,8 @@ public class ConfigHandler { moc.skill50XY[1] = getInt("locations", "skill50Y"); moc.lividHpXY[0] = getInt("locations", "lividHpX"); moc.lividHpXY[1] = getInt("locations", "lividHpY"); + moc.cakeTimerXY[0] = getInt("locations", "cakeTimerX"); + moc.cakeTimerXY[1] = getInt("locations", "cakeTimerY"); final ScaleCommand sc = new ScaleCommand(); sc.coordsScale = getDouble("scales", "coordsScale"); @@ -556,6 +566,7 @@ public class ConfigHandler { sc.dungeonTimerScale = getDouble("scales", "dungeonTimerScale"); sc.skill50Scale = getDouble("scales", "skill50Scale"); sc.lividHpScale = getDouble("scales", "lividHpScale"); + sc.cakeTimerScale = getDouble("scales", "cakeTimerScale"); TheMod.MAIN_COLOUR = getString("colors", "main"); TheMod.SECONDARY_COLOUR = getString("colors", "secondary"); @@ -567,6 +578,7 @@ public class ConfigHandler { TheMod.ANSWER_COLOUR = getString("colors", "answer"); TheMod.SKILL_50_COLOUR = getString("colors", "skill50Display"); TheMod.COORDS_COLOUR = getString("colors", "coordsDisplay"); + TheMod.CAKE_COLOUR = getString("colors", "cakeDisplay"); } } diff --git a/src/main/resources/assets/dsm/icons/cake.png b/src/main/resources/assets/dsm/icons/cake.png new file mode 100644 index 0000000..c3f0c7e Binary files /dev/null and b/src/main/resources/assets/dsm/icons/cake.png differ -- cgit From db03ce14fde088c15dc366e70d937338de8721dc Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Sat, 14 Nov 2020 18:39:14 -0500 Subject: Add option to hide heal messages --- README.md | 3 ++- src/main/java/me/Danker/TheMod.java | 25 ++++++++++++++-------- src/main/java/me/Danker/commands/DHelpCommand.java | 2 +- .../java/me/Danker/commands/ToggleCommand.java | 12 ++++++++--- src/main/java/me/Danker/gui/DankerGui.java | 21 ++++++++++++------ .../java/me/Danker/handlers/ConfigHandler.java | 2 ++ 6 files changed, 44 insertions(+), 21 deletions(-) (limited to 'src/main/java/me/Danker/gui') diff --git a/README.md b/README.md index d00cd12..7177fe2 100644 --- a/README.md +++ b/README.md @@ -15,6 +15,7 @@ Discord Server: https://discord.gg/QsEkNQS - Block AOTD ability (toggleable) - Disable Spirit Sceptre messages (toggleable) - Disable Midas Staff messages (toggleable) +- Disable heal messages (toggleable) - Slayer item tracker (with graphic display) (scalable) - RNGesus drop alerts (toggleable) - Click in chat to open Maddox (toggleable) @@ -35,7 +36,7 @@ Discord Server: https://discord.gg/QsEkNQS ## Commands - /dhelp - Returns this message in-game. - /dsm - Opens the GUI for Danker's Skyblock Mod. -- /toggle - Toggles features. /toggle list returns values of every toggle. +- /toggle - Toggles features. /toggle list returns values of every toggle. - /setkey - Sets API key. - /getkey - Returns key set with /setkey and copies it to your clipboard. - /loot [winter/spooky/f(1-6)/session] - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead. diff --git a/src/main/java/me/Danker/TheMod.java b/src/main/java/me/Danker/TheMod.java index 4131a39..bed2b69 100644 --- a/src/main/java/me/Danker/TheMod.java +++ b/src/main/java/me/Danker/TheMod.java @@ -398,6 +398,22 @@ public class TheMod if (message.contains(":")) return; + // Spirit Sceptre + if (!tc.sceptreMessages && message.contains("Your Spirit Sceptre hit ")) { + event.setCanceled(true); + return; + } + // Midas Staff + if (!tc.midasStaffMessages && message.contains("Your Molten Wave hit ")) { + event.setCanceled(true); + return; + } + // Heals + if (!tc.healMessages && message.contains(" health!") && (message.contains("You healed ") || message.contains(" healed you for "))) { + event.setCanceled(true); + return; + } + if (ToggleCommand.oruoToggled && Utils.inDungeons) { // Don't set every answer to wrong with this question if (message.contains("What SkyBlock year is it?")) triviaAnswers = null; @@ -997,15 +1013,6 @@ public class TheMod if (tc.spiritBearAlerts && message.contains("The Spirit Bear has appeared!")) { Utils.createTitle(EnumChatFormatting.DARK_PURPLE + "SPIRIT BEAR", 2); } - - // Spirit Sceptre - if (!tc.sceptreMessages && message.contains("Your Spirit Sceptre hit ")) { - event.setCanceled(true); - } - // Midas Staff - if (!tc.midasStaffMessages && message.contains("Your Molten Wave hit ")) { - event.setCanceled(true); - } } @SubscribeEvent diff --git a/src/main/java/me/Danker/commands/DHelpCommand.java b/src/main/java/me/Danker/commands/DHelpCommand.java index 90c2be8..abbc3c8 100644 --- a/src/main/java/me/Danker/commands/DHelpCommand.java +++ b/src/main/java/me/Danker/commands/DHelpCommand.java @@ -34,7 +34,7 @@ public class DHelpCommand extends CommandBase { EnumChatFormatting.GOLD + " Commands, " + EnumChatFormatting.GREEN + " Keybinds.\n" + EnumChatFormatting.GOLD + " /dhelp" + EnumChatFormatting.AQUA + " - Returns this message.\n" + EnumChatFormatting.GOLD + " /dsm" + EnumChatFormatting.AQUA + " - Opens the GUI for Danker's Skyblock Mod.\n" + - EnumChatFormatting.GOLD + " /toggle " + EnumChatFormatting.AQUA + " - Toggles features. /toggle list returns values of every toggle.\n" + + EnumChatFormatting.GOLD + " /toggle " + EnumChatFormatting.AQUA + " - Toggles features. /toggle list returns values of every toggle.\n" + EnumChatFormatting.GOLD + " /setkey " + EnumChatFormatting.AQUA + " - Sets API key.\n" + EnumChatFormatting.GOLD + " /getkey" + EnumChatFormatting.AQUA + " - Returns key set with /setkey and copies it to your clipboard.\n" + EnumChatFormatting.GOLD + " /loot [winter/festival/spooky/f(1-6)/session]" + EnumChatFormatting.AQUA + " - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead.\n" + diff --git a/src/main/java/me/Danker/commands/ToggleCommand.java b/src/main/java/me/Danker/commands/ToggleCommand.java index 473c29a..25b3ff3 100644 --- a/src/main/java/me/Danker/commands/ToggleCommand.java +++ b/src/main/java/me/Danker/commands/ToggleCommand.java @@ -33,6 +33,7 @@ public class ToggleCommand extends CommandBase implements ICommand { public static boolean skill50DisplayToggled; public static boolean outlineTextToggled; public static boolean midasStaffMessages; + public static boolean healMessages; public static boolean cakeTimerToggled; public static boolean lividSolverToggled; // Puzzle Solvers @@ -50,7 +51,7 @@ public class ToggleCommand extends CommandBase implements ICommand { public String getCommandUsage(ICommandSender arg0) { return "/" + getCommandName() + " "; + "outlinetext/midasstaffmessages/healmessages/caketimer/lividsolver/threemanpuzzle/oruopuzzle/blazepuzzle/creeperpuzzle/list>"; } @Override @@ -65,8 +66,8 @@ public class ToggleCommand extends CommandBase implements ICommand { "splitfishing", "chatmaddox", "spiritbearalerts", "aotd", "lividdagger", "sceptremessages", "petcolors", "dungeontimer", "golemalerts", "expertiselore", "skill50display", "outlinetext", "midasstaffmessages", - "caketimer", "lividsolver", "threemanpuzzle", "oruopuzzle", "blazepuzzle", - "creeperpuzzle", "list"); + "healmessages", "caketimer", "lividsolver", "threemanpuzzle", "oruopuzzle", + "blazepuzzle", "creeperpuzzle", "list"); } return null; } @@ -153,6 +154,10 @@ public class ToggleCommand extends CommandBase implements ICommand { midasStaffMessages = !midasStaffMessages; cf.writeBooleanConfig("toggles", "MidasStaffMessages", midasStaffMessages); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Midas Staff messages have been set to " + TheMod.SECONDARY_COLOUR + midasStaffMessages + TheMod.MAIN_COLOUR + ".")); + } else if (arg1[0].equalsIgnoreCase("healmessages")) { + healMessages = !healMessages; + cf.writeBooleanConfig("toggles", "HealMessages", healMessages); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Heal messages have been set to " + TheMod.SECONDARY_COLOUR + healMessages + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("caketimer")) { cakeTimerToggled = !cakeTimerToggled; cf.writeBooleanConfig("toggles", "CakeTimer", cakeTimerToggled); @@ -196,6 +201,7 @@ public class ToggleCommand extends CommandBase implements ICommand { TheMod.TYPE_COLOUR + " Skill 50 display: " + TheMod.VALUE_COLOUR + skill50DisplayToggled + "\n" + TheMod.TYPE_COLOUR + " Outline displayed text: " + TheMod.VALUE_COLOUR + outlineTextToggled + "\n" + TheMod.TYPE_COLOUR + " Midas Staff messages: " + TheMod.VALUE_COLOUR + midasStaffMessages + "\n" + + TheMod.TYPE_COLOUR + " Heal messages: " + TheMod.VALUE_COLOUR + healMessages + "\n" + TheMod.TYPE_COLOUR + " Cake timer: " + TheMod.VALUE_COLOUR + cakeTimerToggled + "\n" + TheMod.TYPE_COLOUR + " Livid solver: " + TheMod.VALUE_COLOUR + lividSolverToggled + "\n" + TheMod.TYPE_COLOUR + " Three man puzzle solver: " + TheMod.VALUE_COLOUR + threeManToggled + "\n" + diff --git a/src/main/java/me/Danker/gui/DankerGui.java b/src/main/java/me/Danker/gui/DankerGui.java index 1bf7911..d77df14 100644 --- a/src/main/java/me/Danker/gui/DankerGui.java +++ b/src/main/java/me/Danker/gui/DankerGui.java @@ -47,6 +47,7 @@ public class DankerGui extends GuiScreen { private GuiButton skill50Display; private GuiButton outlineText; private GuiButton midasStaffMessages; + private GuiButton healMessages; private GuiButton cakeTimer; private GuiButton lividSolver; @@ -94,13 +95,14 @@ public class DankerGui extends GuiScreen { spiritBearAlert = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Spirit Bear Spawn Alerts: " + Utils.getColouredBoolean(ToggleCommand.spiritBearAlerts)); sceptreMessages = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Spirit Sceptre Messages: " + Utils.getColouredBoolean(ToggleCommand.sceptreMessages)); midasStaffMessages = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Midas Staff Messages: " + Utils.getColouredBoolean(ToggleCommand.midasStaffMessages)); - goldenEnch = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Golden T10/T6/T4 Enchantments: " + Utils.getColouredBoolean(ToggleCommand.goldenToggled)); - petColours = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Colour Pet Backgrounds: " + Utils.getColouredBoolean(ToggleCommand.petColoursToggled)); - expertiseLore = new GuiButton(0, width / 2 - 100, (int) (height * 0.6), "Expertise Kills In Lore: " + Utils.getColouredBoolean(ToggleCommand.expertiseLoreToggled)); - lividSolver = new GuiButton(0, width / 2 - 100, (int) (height * 0.7), "Find Correct Livid: " + Utils.getColouredBoolean(ToggleCommand.lividSolverToggled)); + healMessages = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Heal Messages: " + Utils.getColouredBoolean(ToggleCommand.healMessages)); + goldenEnch = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Golden T10/T6/T4 Enchantments: " + Utils.getColouredBoolean(ToggleCommand.goldenToggled)); + petColours = new GuiButton(0, width / 2 - 100, (int) (height * 0.6), "Colour Pet Backgrounds: " + Utils.getColouredBoolean(ToggleCommand.petColoursToggled)); + expertiseLore = new GuiButton(0, width / 2 - 100, (int) (height * 0.7), "Expertise Kills In Lore: " + Utils.getColouredBoolean(ToggleCommand.expertiseLoreToggled)); // Page 4 - golemAlerts = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Alert When Golem Spawns: " + Utils.getColouredBoolean(ToggleCommand.golemAlertToggled)); - rngesusAlert = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "RNGesus Alerts: " + Utils.getColouredBoolean(ToggleCommand.rngesusAlerts)); + lividSolver = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Find Correct Livid: " + Utils.getColouredBoolean(ToggleCommand.lividSolverToggled)); + golemAlerts = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Alert When Golem Spawns: " + Utils.getColouredBoolean(ToggleCommand.golemAlertToggled)); + rngesusAlert = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "RNGesus Alerts: " + Utils.getColouredBoolean(ToggleCommand.rngesusAlerts)); if (page == 1) { this.buttonList.add(changeDisplay); @@ -125,13 +127,14 @@ public class DankerGui extends GuiScreen { this.buttonList.add(spiritBearAlert); this.buttonList.add(sceptreMessages); this.buttonList.add(midasStaffMessages); + this.buttonList.add(healMessages); this.buttonList.add(goldenEnch); this.buttonList.add(petColours); this.buttonList.add(expertiseLore); - this.buttonList.add(lividSolver); this.buttonList.add(nextPage); this.buttonList.add(backPage); } else if (page == 4) { + this.buttonList.add(lividSolver); this.buttonList.add(golemAlerts); this.buttonList.add(rngesusAlert); this.buttonList.add(backPage); @@ -257,6 +260,10 @@ public class DankerGui extends GuiScreen { ToggleCommand.cakeTimerToggled = !ToggleCommand.cakeTimerToggled; ConfigHandler.writeBooleanConfig("toggles", "CakeTimer", ToggleCommand.cakeTimerToggled); cakeTimer.displayString = "Cake Timer: " + Utils.getColouredBoolean(ToggleCommand.cakeTimerToggled); + } else if (button == healMessages) { + ToggleCommand.healMessages = !ToggleCommand.healMessages; + ConfigHandler.writeBooleanConfig("toggles", "HealMessages", ToggleCommand.healMessages); + healMessages.displayString = "Heal Messages: " + Utils.getColouredBoolean(ToggleCommand.healMessages); } } diff --git a/src/main/java/me/Danker/handlers/ConfigHandler.java b/src/main/java/me/Danker/handlers/ConfigHandler.java index 7473e43..131076d 100644 --- a/src/main/java/me/Danker/handlers/ConfigHandler.java +++ b/src/main/java/me/Danker/handlers/ConfigHandler.java @@ -191,6 +191,7 @@ public class ConfigHandler { if (!hasKey("toggles", "Skill50Display")) writeBooleanConfig("toggles", "Skill50Display", false); if (!hasKey("toggles", "OutlineText")) writeBooleanConfig("toggles", "OutlineText", false); if (!hasKey("toggles", "MidasStaffMessages")) writeBooleanConfig("toggles", "MidasStaffMessages", true); + if (!hasKey("toggles", "HealMessages")) writeBooleanConfig("toggles", "HealMessages", true); if (!hasKey("toggles", "CakeTimer")) writeBooleanConfig("toggles", "CakeTimer", false); if (!hasKey("toggles", "LividSolver")) writeBooleanConfig("toggles", "LividSolver", false); // Puzzle Solvers @@ -391,6 +392,7 @@ public class ConfigHandler { tf.skill50DisplayToggled = getBoolean("toggles", "Skill50Display"); tf.outlineTextToggled = getBoolean("toggles", "OutlineText"); tf.midasStaffMessages = getBoolean("toggles", "MidasStaffMessages"); + tf.healMessages = getBoolean("toggles", "HealMessages"); tf.cakeTimerToggled = getBoolean("toggles", "CakeTimer"); tf.lividSolverToggled = getBoolean("toggles", "LividSolver"); // Puzzle Solvers -- cgit From 68646a34ea9080228dfe437fedcec84a41c1fd6d Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Thu, 19 Nov 2020 12:05:38 -0500 Subject: Add water puzzle solver, bug fixes Update trivia solutions Limit skills from achievement API to 50 Fix typo in puzzle solvers GUI --- README.md | 2 +- src/main/java/me/Danker/TheMod.java | 131 +++++++++++++++++++-- src/main/java/me/Danker/commands/DHelpCommand.java | 2 +- .../java/me/Danker/commands/SkillsCommand.java | 14 +-- .../java/me/Danker/commands/ToggleCommand.java | 13 +- src/main/java/me/Danker/gui/PuzzleSolversGui.java | 9 +- .../java/me/Danker/handlers/ConfigHandler.java | 2 + 7 files changed, 149 insertions(+), 24 deletions(-) (limited to 'src/main/java/me/Danker/gui') diff --git a/README.md b/README.md index 7177fe2..de9b006 100644 --- a/README.md +++ b/README.md @@ -36,7 +36,7 @@ Discord Server: https://discord.gg/QsEkNQS ## Commands - /dhelp - Returns this message in-game. - /dsm - Opens the GUI for Danker's Skyblock Mod. -- /toggle - Toggles features. /toggle list returns values of every toggle. +- /toggle - Toggles features. /toggle list returns values of every toggle. - /setkey - Sets API key. - /getkey - Returns key set with /setkey and copies it to your clipboard. - /loot [winter/spooky/f(1-6)/session] - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead. diff --git a/src/main/java/me/Danker/TheMod.java b/src/main/java/me/Danker/TheMod.java index bed2b69..56dd272 100644 --- a/src/main/java/me/Danker/TheMod.java +++ b/src/main/java/me/Danker/TheMod.java @@ -78,6 +78,7 @@ import net.minecraft.util.IChatComponent; import net.minecraft.util.ResourceLocation; import net.minecraft.util.StringUtils; import net.minecraft.util.Vec3; +import net.minecraft.world.World; import net.minecraftforge.client.ClientCommandHandler; import net.minecraftforge.client.event.ClientChatReceivedEvent; import net.minecraftforge.client.event.GuiScreenEvent; @@ -136,10 +137,12 @@ public class TheMod static Entity highestBlaze = null; static Entity lowestBlaze = null; // Among Us colours - static int[] creeperLineColours = {0x50EF39, 0xC51111, 0x132ED1, 0x117F2D, 0xED54BA, 0xEF7D0D, 0xF5F557, 0xD6E0F0, 0x6B2FBB, 0x39FEDC}; + static final int[] CREEPER_COLOURS = {0x50EF39, 0xC51111, 0x132ED1, 0x117F2D, 0xED54BA, 0xEF7D0D, 0xF5F557, 0xD6E0F0, 0x6B2FBB, 0x39FEDC}; static boolean drawCreeperLines = false; static Vec3 creeperLocation = new Vec3(0, 0, 0); static List creeperLines = new ArrayList(); + static boolean prevInWaterRoom = false; + static boolean inWaterRoom = false; static boolean foundLivid = false; static Entity livid = null; public static double cakeTime; @@ -242,7 +245,7 @@ public class TheMod triviaSolutions.put("How many unique minions are there?", new String[]{"52 Minions"}); triviaSolutions.put("Which of these enemies does not spawn in the Spider's Den?", new String[]{"Zombie Spider", "Cave Spider", "Wither Skeleton", "Dashing Spooder", "Broodfather", "Night Spider"}); triviaSolutions.put("Which of these monsters only spawns at night?", new String[]{"Zombie Villager", "Ghast"}); - triviaSolutions.put("Which of these is not a dragon in The End?", new String[]{"Zoomer Dragon", "Weak Dragon", "Stonk Dragon", "Holy Dragon", "Boomer Dragon", "Booger Dragon", "Older Dragon"}); + triviaSolutions.put("Which of these is not a dragon in The End?", new String[]{"Zoomer Dragon", "Weak Dragon", "Stonk Dragon", "Holy Dragon", "Boomer Dragon", "Booger Dragon", "Older Dragon", "Elder Dragon"}); String patternString = "(" + String.join("|", t6Enchants.keySet()) + ")"; pattern = Pattern.compile(patternString); @@ -1930,6 +1933,7 @@ public class TheMod @SubscribeEvent public void onTick(TickEvent.ClientTickEvent event) { Minecraft mc = Minecraft.getMinecraft(); + World world = mc.theWorld; EntityPlayerSP player = mc.thePlayer; // Checks every second @@ -1940,7 +1944,7 @@ public class TheMod Utils.checkForDungeons(); } - if (DisplayCommand.auto && mc != null && mc.theWorld != null) { + if (DisplayCommand.auto && mc != null && world != null) { List scoreboard = ScoreboardHandler.getSidebarLines(); boolean found = false; for (String s : scoreboard) { @@ -1975,13 +1979,13 @@ public class TheMod ConfigHandler.writeStringConfig("misc", "display", DisplayCommand.display); } - if (ToggleCommand.creeperToggled && Utils.inDungeons && mc.theWorld != null) { + if (ToggleCommand.creeperToggled && Utils.inDungeons && world != null) { double x = player.posX; double y = player.posY; double z = player.posZ; // Find creepers nearby AxisAlignedBB creeperScan = new AxisAlignedBB(x - 14, y - 8, z - 13, x + 14, y + 8, z + 13); // 28x16x26 cube - List creepers = mc.theWorld.getEntitiesWithinAABB(EntityCreeper.class, creeperScan); + List creepers = world.getEntitiesWithinAABB(EntityCreeper.class, creeperScan); // Check if creeper is nearby if (creepers.size() > 0) { EntityCreeper creeper = creepers.get(0); @@ -1994,7 +1998,7 @@ public class TheMod BlockPos point2 = new BlockPos(creeper.posX + 14, creeper.posY + 10, creeper.posZ + 13); Iterable blocks = BlockPos.getAllInBox(point1, point2); for (BlockPos blockPos : blocks) { - Block block = mc.theWorld.getBlockState(blockPos).getBlock(); + Block block = world.getBlockState(blockPos).getBlock(); if (block == Blocks.sea_lantern || block == Blocks.prismarine) { // Connect block to nearest block on opposite side Vec3 startBlock = new Vec3(blockPos.getX() + 0.5, blockPos.getY() + 0.5, blockPos.getZ() + 0.5); @@ -2012,7 +2016,112 @@ public class TheMod } } - if (ToggleCommand.lividSolverToggled && Utils.inDungeons && !foundLivid && mc.theWorld != null) { + if (ToggleCommand.waterToggled && Utils.inDungeons && world != null) { + // multi thread block checking + new Thread(() -> { + prevInWaterRoom = inWaterRoom; + inWaterRoom = false; + boolean done = false; + for (int x = (int) (player.posX - 25); x < player.posX + 25; x++) { + for (int z = (int) (player.posZ - 25); z < player.posZ + 25; z++) { + BlockPos blockPos = new BlockPos(x, 82, z); + if (world.getBlockState(blockPos).getBlock() == Blocks.piston_head) { + inWaterRoom = true; + if (!prevInWaterRoom && inWaterRoom) { + boolean foundGold = false; + boolean foundClay = false; + boolean foundEmerald = false; + boolean foundQuartz = false; + boolean foundDiamond = false; + + // Detect first blocks near water stream + BlockPos scan1 = new BlockPos(x + 1, 78, z + 1); + BlockPos scan2 = new BlockPos(x - 1, 77, z - 1); + Iterable blocks = BlockPos.getAllInBox(scan1, scan2); + for (BlockPos puzzleBlockPos : blocks) { + Block block = world.getBlockState(puzzleBlockPos).getBlock(); + if (block == Blocks.gold_block) { + foundGold = true; + } else if (block == Blocks.hardened_clay) { + foundClay = true; + } else if (block == Blocks.emerald_block) { + foundEmerald = true; + } else if (block == Blocks.quartz_block) { + foundQuartz = true; + } else if (block == Blocks.diamond_block) { + foundDiamond = true; + } + } + + int variant = 0; + if (foundGold && foundClay) { + variant = 1; + } else if (foundEmerald && foundQuartz) { + variant = 2; + } else if (foundQuartz && foundDiamond) { + variant = 3; + } else if (foundGold && foundQuartz) { + variant = 4; + } + + // Return solution + String purple = ""; + String orange = ""; + String blue = ""; + String green = ""; + String red = ""; + switch (variant) { + case 1: + purple = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.AQUA + "Diamond, " + EnumChatFormatting.RED + "Clay"; + orange = EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.DARK_GRAY + "Coal, " + EnumChatFormatting.GREEN + "Emerald"; + blue = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.GREEN + "Emerald" + EnumChatFormatting.RED + "Clay"; + green = EnumChatFormatting.GREEN + "Emerald"; + red = EnumChatFormatting.GRAY + "None"; + break; + case 2: + purple = EnumChatFormatting.DARK_GRAY + "Coal"; + orange = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.GREEN + "Emerald, " + EnumChatFormatting.RED + "Clay"; + blue = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.AQUA + "Diamond, " + EnumChatFormatting.GREEN + "Emerald"; + green = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.GREEN + "Emerald"; + red = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.DARK_GRAY + "Coal, " + EnumChatFormatting.GREEN + "Emerald"; + break; + case 3: + purple = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.AQUA + "Diamond"; + orange = EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.GREEN + "Emerald"; + blue = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.AQUA + "Diamond"; + green = EnumChatFormatting.YELLOW + "Gold"; + red = EnumChatFormatting.GREEN + "Emerald"; + break; + case 4: + purple = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.GREEN + "Emerald, " + EnumChatFormatting.RED + "Clay"; + orange = EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.DARK_GRAY + "Coal"; + blue = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.DARK_GRAY + "Coal, " + EnumChatFormatting.GREEN + "Emerald, " + EnumChatFormatting.RED + "Clay"; + green = EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.GREEN + "Emerald"; + red = EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.AQUA + "Diamond, " + EnumChatFormatting.GREEN + "Emerald, " + EnumChatFormatting.RED + "Clay"; + break; + default: + player.addChatMessage(new ChatComponentText(ERROR_COLOUR + "Error detecting water puzzle variant.")); + break; + } + player.addChatMessage(new ChatComponentText(DELIMITER_COLOUR + EnumChatFormatting.BOLD + "-------------------\n" + + MAIN_COLOUR + " The following levers must be down:\n " + + EnumChatFormatting.DARK_PURPLE + "Purple: " + purple + "\n " + + EnumChatFormatting.GOLD + "Orange: " + orange + "\n " + + EnumChatFormatting.BLUE + "Blue: " + blue + "\n " + + EnumChatFormatting.GREEN + "Green: " + green + "\n " + + EnumChatFormatting.RED + "Red: " + red + "\n" + + DELIMITER_COLOUR + EnumChatFormatting.BOLD + " -------------------")); + done = true; + break; + } + } + } + if (done) break; + } + }).start(); + } + + if (ToggleCommand.lividSolverToggled && Utils.inDungeons && !foundLivid && world != null) { boolean inF5 = false; List scoreboard = ScoreboardHandler.getSidebarLines(); @@ -2026,7 +2135,7 @@ public class TheMod if (inF5) { List loadedLivids = new ArrayList(); - List entities = mc.theWorld.getLoadedEntityList(); + List entities = world.getLoadedEntityList(); for (Entity entity : entities) { String name = entity.getName(); if (name.contains("Livid") && name.length() > 5 && name.charAt(1) == name.charAt(5) && !loadedLivids.contains(entity)) { @@ -2045,8 +2154,8 @@ public class TheMod // Checks 5 times per second if (tickAmount % 4 == 0) { - if (ToggleCommand.blazeToggled && Utils.inDungeons && mc.theWorld != null) { - List entities = mc.theWorld.getLoadedEntityList(); + if (ToggleCommand.blazeToggled && Utils.inDungeons && world != null) { + List entities = world.getLoadedEntityList(); int highestHealth = 0; highestBlaze = null; int lowestHealth = 99999999; @@ -2126,7 +2235,7 @@ public class TheMod } if (ToggleCommand.creeperToggled && drawCreeperLines && !creeperLines.isEmpty()) { for (int i = 0; i < creeperLines.size(); i++) { - Utils.draw3DLine(creeperLines.get(i)[0], creeperLines.get(i)[1], creeperLineColours[i % 10], event.partialTicks); + Utils.draw3DLine(creeperLines.get(i)[0], creeperLines.get(i)[1], CREEPER_COLOURS[i % 10], event.partialTicks); } } } diff --git a/src/main/java/me/Danker/commands/DHelpCommand.java b/src/main/java/me/Danker/commands/DHelpCommand.java index abbc3c8..b3bdbbf 100644 --- a/src/main/java/me/Danker/commands/DHelpCommand.java +++ b/src/main/java/me/Danker/commands/DHelpCommand.java @@ -34,7 +34,7 @@ public class DHelpCommand extends CommandBase { EnumChatFormatting.GOLD + " Commands, " + EnumChatFormatting.GREEN + " Keybinds.\n" + EnumChatFormatting.GOLD + " /dhelp" + EnumChatFormatting.AQUA + " - Returns this message.\n" + EnumChatFormatting.GOLD + " /dsm" + EnumChatFormatting.AQUA + " - Opens the GUI for Danker's Skyblock Mod.\n" + - EnumChatFormatting.GOLD + " /toggle " + EnumChatFormatting.AQUA + " - Toggles features. /toggle list returns values of every toggle.\n" + + EnumChatFormatting.GOLD + " /toggle " + EnumChatFormatting.AQUA + " - Toggles features. /toggle list returns values of every toggle.\n" + EnumChatFormatting.GOLD + " /setkey " + EnumChatFormatting.AQUA + " - Sets API key.\n" + EnumChatFormatting.GOLD + " /getkey" + EnumChatFormatting.AQUA + " - Returns key set with /setkey and copies it to your clipboard.\n" + EnumChatFormatting.GOLD + " /loot [winter/festival/spooky/f(1-6)/session]" + EnumChatFormatting.AQUA + " - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead.\n" + diff --git a/src/main/java/me/Danker/commands/SkillsCommand.java b/src/main/java/me/Danker/commands/SkillsCommand.java index 7405a84..12bfd93 100644 --- a/src/main/java/me/Danker/commands/SkillsCommand.java +++ b/src/main/java/me/Danker/commands/SkillsCommand.java @@ -144,25 +144,25 @@ public class SkillsCommand extends CommandBase { farmingLevel = achievementObject.get("skyblock_harvester").getAsInt(); } if (achievementObject.has("skyblock_excavator")) { - miningLevel = achievementObject.get("skyblock_excavator").getAsInt(); + miningLevel = Math.min(achievementObject.get("skyblock_excavator").getAsInt(), 50); } if (achievementObject.has("skyblock_combat")) { - combatLevel = achievementObject.get("skyblock_combat").getAsInt(); + combatLevel = Math.min(achievementObject.get("skyblock_combat").getAsInt(), 50); } if (achievementObject.has("skyblock_gatherer")) { - foragingLevel = achievementObject.get("skyblock_gatherer").getAsInt(); + foragingLevel = Math.min(achievementObject.get("skyblock_gatherer").getAsInt(), 50); } if (achievementObject.has("skyblock_angler")) { - fishingLevel = achievementObject.get("skyblock_angler").getAsInt(); + fishingLevel = Math.min(achievementObject.get("skyblock_angler").getAsInt(), 50); } if (achievementObject.has("skyblock_augmentation")) { - enchantingLevel = achievementObject.get("skyblock_augmentation").getAsInt(); + enchantingLevel = Math.min(achievementObject.get("skyblock_augmentation").getAsInt(), 50); } if (achievementObject.has("skyblock_concoctor")) { - alchemyLevel = achievementObject.get("skyblock_concoctor").getAsInt(); + alchemyLevel = Math.min(achievementObject.get("skyblock_concoctor").getAsInt(), 50); } if (achievementObject.has("skyblock_domesticator")) { - tamingLevel = achievementObject.get("skyblock_domesticator").getAsInt(); + tamingLevel = Math.min(achievementObject.get("skyblock_domesticator").getAsInt(), 50); } } diff --git a/src/main/java/me/Danker/commands/ToggleCommand.java b/src/main/java/me/Danker/commands/ToggleCommand.java index 25b3ff3..df39af6 100644 --- a/src/main/java/me/Danker/commands/ToggleCommand.java +++ b/src/main/java/me/Danker/commands/ToggleCommand.java @@ -41,6 +41,7 @@ public class ToggleCommand extends CommandBase implements ICommand { public static boolean oruoToggled; public static boolean blazeToggled; public static boolean creeperToggled; + public static boolean waterToggled; @Override public String getCommandName() { @@ -51,7 +52,8 @@ public class ToggleCommand extends CommandBase implements ICommand { public String getCommandUsage(ICommandSender arg0) { return "/" + getCommandName() + " "; + "outlinetext/midasstaffmessages/healmessages/caketimer/lividsolver/threemanpuzzle/oruopuzzle/" + + "blazepuzzle/creeperpuzzle/waterpuzzle/list>"; } @Override @@ -67,7 +69,7 @@ public class ToggleCommand extends CommandBase implements ICommand { "sceptremessages", "petcolors", "dungeontimer", "golemalerts", "expertiselore", "skill50display", "outlinetext", "midasstaffmessages", "healmessages", "caketimer", "lividsolver", "threemanpuzzle", "oruopuzzle", - "blazepuzzle", "creeperpuzzle", "list"); + "blazepuzzle", "creeperpuzzle", "waterpuzzle", "list"); } return null; } @@ -182,6 +184,10 @@ public class ToggleCommand extends CommandBase implements ICommand { creeperToggled = !creeperToggled; cf.writeBooleanConfig("creeperpuzzle", "CreeperPuzzle", creeperToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Creeper puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + creeperToggled + TheMod.MAIN_COLOUR + ".")); + } else if (arg1[0].equalsIgnoreCase("waterpuzzle")) { + waterToggled = !waterToggled; + cf.writeBooleanConfig("waterpuzzle", "WaterPuzzle", waterToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Water puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + waterToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("list")) { player.addChatMessage(new ChatComponentText(TheMod.TYPE_COLOUR + "Guild party notifications: " + TheMod.VALUE_COLOUR + gpartyToggled + "\n" + TheMod.TYPE_COLOUR + " Coord/Angle display: " + TheMod.VALUE_COLOUR + coordsToggled + "\n" + @@ -207,7 +213,8 @@ public class ToggleCommand extends CommandBase implements ICommand { TheMod.TYPE_COLOUR + " Three man puzzle solver: " + TheMod.VALUE_COLOUR + threeManToggled + "\n" + TheMod.TYPE_COLOUR + " Oruo trivia solver: " + TheMod.VALUE_COLOUR + oruoToggled + "\n" + TheMod.TYPE_COLOUR + " Blaze puzzle solver: " + TheMod.VALUE_COLOUR + blazeToggled + "\n" + - TheMod.TYPE_COLOUR + " Creeper puzzle solver: " + TheMod.VALUE_COLOUR + creeperToggled)); + TheMod.TYPE_COLOUR + " Creeper puzzle solver: " + TheMod.VALUE_COLOUR + creeperToggled + "\n" + + TheMod.TYPE_COLOUR + " Water puzzle solver: " + TheMod.VALUE_COLOUR + waterToggled)); } else { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); } diff --git a/src/main/java/me/Danker/gui/PuzzleSolversGui.java b/src/main/java/me/Danker/gui/PuzzleSolversGui.java index e2fa4ef..4ae97bb 100644 --- a/src/main/java/me/Danker/gui/PuzzleSolversGui.java +++ b/src/main/java/me/Danker/gui/PuzzleSolversGui.java @@ -16,6 +16,7 @@ public class PuzzleSolversGui extends GuiScreen { private GuiButton trivia; private GuiButton blaze; private GuiButton creeper; + private GuiButton water; @Override public boolean doesGuiPauseGame() { @@ -34,13 +35,15 @@ public class PuzzleSolversGui extends GuiScreen { riddle = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Riddle Solver: " + Utils.getColouredBoolean(ToggleCommand.threeManToggled)); trivia = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Trivia Solver: " + Utils.getColouredBoolean(ToggleCommand.oruoToggled)); blaze = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Blaze Solver: " + Utils.getColouredBoolean(ToggleCommand.blazeToggled)); - creeper = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Creeper Solver : " + Utils.getColouredBoolean(ToggleCommand.creeperToggled)); + creeper = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Creeper Solver: " + Utils.getColouredBoolean(ToggleCommand.creeperToggled)); + water = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Water Solver: " + Utils.getColouredBoolean(ToggleCommand.waterToggled)); this.buttonList.add(goBack); this.buttonList.add(riddle); this.buttonList.add(trivia); this.buttonList.add(blaze); this.buttonList.add(creeper); + this.buttonList.add(water); } @Override @@ -69,6 +72,10 @@ public class PuzzleSolversGui extends GuiScreen { ToggleCommand.creeperToggled = !ToggleCommand.creeperToggled; ConfigHandler.writeBooleanConfig("toggles", "CreeperPuzzle", ToggleCommand.creeperToggled); creeper.displayString = "Creeper Solver: " + Utils.getColouredBoolean(ToggleCommand.creeperToggled); + } else if (button == water) { + ToggleCommand.waterToggled = !ToggleCommand.waterToggled; + ConfigHandler.writeBooleanConfig("toggles", "WaterPuzzle", ToggleCommand.waterToggled); + water.displayString = "Water Solver: " + Utils.getColouredBoolean(ToggleCommand.waterToggled); } } diff --git a/src/main/java/me/Danker/handlers/ConfigHandler.java b/src/main/java/me/Danker/handlers/ConfigHandler.java index 131076d..408849c 100644 --- a/src/main/java/me/Danker/handlers/ConfigHandler.java +++ b/src/main/java/me/Danker/handlers/ConfigHandler.java @@ -199,6 +199,7 @@ public class ConfigHandler { if (!hasKey("toggles", "OruoPuzzle")) writeBooleanConfig("toggles", "OruoPuzzle", false); if (!hasKey("toggles", "BlazePuzzle")) writeBooleanConfig("toggles", "BlazePuzzle", false); if (!hasKey("toggles", "CreeperPuzzle")) writeBooleanConfig("toggles", "CreeperPuzzle", false); + if (!hasKey("toggles", "WaterPuzzle")) writeBooleanConfig("toggles", "WaterPuzzle", false); if (!hasKey("api", "APIKey")) writeStringConfig("api", "APIKey", ""); @@ -400,6 +401,7 @@ public class ConfigHandler { tf.oruoToggled = getBoolean("toggles", "OruoPuzzle"); tf.blazeToggled = getBoolean("toggles", "BlazePuzzle"); tf.creeperToggled = getBoolean("toggles", "CreeperPuzzle"); + tf.waterToggled = getBoolean("toggles", "WaterPuzzle"); final BlockSlayerCommand bs = new BlockSlayerCommand(); String onlySlayer = getString("toggles", "BlockSlayer"); -- cgit From b8481811e5e25f2a710053444347295010a6155c Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Fri, 20 Nov 2020 14:44:10 -0500 Subject: Change chat maddox to anywhere while chat is open, fix some dungeon loot Move Adaptive Blade to F2 loot Add Last Breath to F5 loot --- README.md | 2 +- src/main/java/me/Danker/TheMod.java | 54 +++++++++++++--------- .../java/me/Danker/commands/ChatMaddoxCommand.java | 33 ------------- src/main/java/me/Danker/commands/LootCommand.java | 12 +++-- .../java/me/Danker/commands/ToggleCommand.java | 3 +- src/main/java/me/Danker/gui/DankerGui.java | 4 +- .../java/me/Danker/handlers/ConfigHandler.java | 4 +- 7 files changed, 46 insertions(+), 66 deletions(-) delete mode 100644 src/main/java/me/Danker/commands/ChatMaddoxCommand.java (limited to 'src/main/java/me/Danker/gui') diff --git a/README.md b/README.md index de9b006..ab69c1e 100644 --- a/README.md +++ b/README.md @@ -18,7 +18,7 @@ Discord Server: https://discord.gg/QsEkNQS - Disable heal messages (toggleable) - Slayer item tracker (with graphic display) (scalable) - RNGesus drop alerts (toggleable) -- Click in chat to open Maddox (toggleable) +- Click anywhere on-screen to open Maddox (toggleable) - Maddox Menu keybind - Block starting other slayer quests - Fishing tracker (with graphic display) (scalable) diff --git a/src/main/java/me/Danker/TheMod.java b/src/main/java/me/Danker/TheMod.java index 56dd272..65372cc 100644 --- a/src/main/java/me/Danker/TheMod.java +++ b/src/main/java/me/Danker/TheMod.java @@ -21,7 +21,6 @@ import com.google.gson.JsonObject; import me.Danker.commands.ArmourCommand; import me.Danker.commands.BankCommand; import me.Danker.commands.BlockSlayerCommand; -import me.Danker.commands.ChatMaddoxCommand; import me.Danker.commands.DHelpCommand; import me.Danker.commands.DankerGuiCommand; import me.Danker.commands.DisplayCommand; @@ -56,6 +55,7 @@ import net.minecraft.block.Block; import net.minecraft.client.Minecraft; import net.minecraft.client.entity.EntityPlayerSP; import net.minecraft.client.gui.Gui; +import net.minecraft.client.gui.GuiChat; import net.minecraft.client.gui.inventory.GuiChest; import net.minecraft.client.settings.KeyBinding; import net.minecraft.entity.Entity; @@ -102,6 +102,7 @@ import net.minecraftforge.fml.common.eventhandler.EventPriority; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; import net.minecraftforge.fml.common.gameevent.InputEvent.KeyInputEvent; import net.minecraftforge.fml.common.gameevent.TickEvent; +import net.minecraftforge.fml.common.gameevent.TickEvent.Phase; import net.minecraftforge.fml.common.network.FMLNetworkEvent.ClientConnectedToServerEvent; import net.minecraftforge.fml.common.versioning.DefaultArtifactVersion; @@ -124,7 +125,8 @@ public class TheMod public static boolean showSkill = false; public static String skillText = ""; static int tickAmount = 1; - public static String lastMaddoxCommand = "/cb placeholdervalue"; + static String lastMaddoxCommand = "/cb placeholder"; + static double lastMaddoxTime = 0; static KeyBinding[] keyBindings = new KeyBinding[1]; static int lastMouse = -1; static boolean usingLabymod = false; @@ -134,7 +136,7 @@ public class TheMod "The reward isn't in any of our chests", "Both of them are telling the truth."}; static Map triviaSolutions = new HashMap(); static String[] triviaAnswers = null; - static Entity highestBlaze = null; + static Entity highestBlaze = null; static Entity lowestBlaze = null; // Among Us colours static final int[] CREEPER_COLOURS = {0x50EF39, 0xC51111, 0x132ED1, 0x117F2D, 0xED54BA, 0xEF7D0D, 0xF5F557, 0xD6E0F0, 0x6B2FBB, 0x39FEDC}; @@ -276,7 +278,6 @@ public class TheMod ClientCommandHandler.instance.registerCommand(new ImportFishingCommand()); ClientCommandHandler.instance.registerCommand(new ResetLootCommand()); ClientCommandHandler.instance.registerCommand(new ScaleCommand()); - ClientCommandHandler.instance.registerCommand(new ChatMaddoxCommand()); ClientCommandHandler.instance.registerCommand(new SkyblockPlayersCommand()); ClientCommandHandler.instance.registerCommand(new BlockSlayerCommand()); ClientCommandHandler.instance.registerCommand(new DungeonsCommand()); @@ -371,16 +372,6 @@ public class TheMod return; } - // Replace chat messages with Maddox command - List chatSiblings = event.message.getSiblings(); - if (ToggleCommand.trueChatMaddoxEnabled) { - for (IChatComponent sibling : chatSiblings) { - if (sibling.getChatStyle().getChatClickEvent() == null) { - sibling.setChatStyle(sibling.getChatStyle().setChatClickEvent(new ClickEvent(Action.RUN_COMMAND, "/dmodopenmaddoxmenu"))); - } - } - } - // Dungeon chat spoken by an NPC, containing : if (ToggleCommand.threeManToggled && Utils.inDungeons && message.contains("[NPC]")) { for (String solution : riddleSolutions) { @@ -1007,9 +998,10 @@ public class TheMod for (IChatComponent sibling : listOfSiblings) { if (sibling.getUnformattedText().contains("[OPEN MENU]")) { lastMaddoxCommand = sibling.getChatStyle().getChatClickEvent().getValue(); + lastMaddoxTime = System.currentTimeMillis() / 1000; } } - if (tc.chatMaddoxToggled) Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText(MAIN_COLOUR + "Click anywhere in chat to open Maddox")); + if (tc.chatMaddoxToggled) Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText(MAIN_COLOUR + "Open chat then click anywhere on-screen to open Maddox")); } // Spirit Bear alerts @@ -1627,22 +1619,26 @@ public class TheMod dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.BLUE + "Scarf's Studies:\n" + + EnumChatFormatting.DARK_PURPLE + "Adaptive Blades:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulators) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooks) + "\n" + EnumChatFormatting.BLUE + nf.format(lc.scarfStudies) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveSwords) + "\n" + EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f2CoinsSpent) + "\n" + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f2TimeSpent); } else if (ds.display.equals("catacombs_floor_two_session")) { dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.BLUE + "Scarf's Studies:\n" + + EnumChatFormatting.DARK_PURPLE + "Adaptive Blades:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulatorsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooksSession) + "\n" + EnumChatFormatting.BLUE + nf.format(lc.scarfStudiesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveSwordsSession) + "\n" + EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f2CoinsSpentSession) + "\n" + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f2TimeSpentSession); } else if (ds.display.equals("catacombs_floor_three")) { @@ -1652,7 +1648,6 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + "Adaptive Chestplates:\n" + EnumChatFormatting.DARK_PURPLE + "Adaptive Leggings:\n" + EnumChatFormatting.DARK_PURPLE + "Adaptive Boots:\n" + - EnumChatFormatting.DARK_PURPLE + "Adaptive Blades:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulators) + "\n" + @@ -1661,7 +1656,6 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveChests) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveLegs) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveBoots) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveSwords) + "\n" + EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f3CoinsSpent) + "\n" + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f3TimeSpent); } else if (ds.display.equals("catacombs_floor_three_session")) { @@ -1671,7 +1665,6 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + "Adaptive Chestplates:\n" + EnumChatFormatting.DARK_PURPLE + "Adaptive Leggings:\n" + EnumChatFormatting.DARK_PURPLE + "Adaptive Boots:\n" + - EnumChatFormatting.DARK_PURPLE + "Adaptive Blades:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulatorsSession) + "\n" + @@ -1680,7 +1673,6 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveChestsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveLegsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveBootsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveSwordsSession) + "\n" + EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f3CoinsSpentSession) + "\n" + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f3TimeSpentSession); } else if (ds.display.equals("catacombs_floor_four")) { @@ -1737,6 +1729,7 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + "Shadow Chestplates:\n" + EnumChatFormatting.DARK_PURPLE + "Shadow Leggings:\n" + EnumChatFormatting.DARK_PURPLE + "Shadow Boots:\n" + + EnumChatFormatting.GOLD + "Last Breaths:\n" + EnumChatFormatting.GOLD + "Livid Daggers:\n" + EnumChatFormatting.GOLD + "Shadow Furys:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + @@ -1748,6 +1741,7 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssChests) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssLegs) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssBoots) + "\n" + + EnumChatFormatting.GOLD + nf.format(lc.lastBreaths) + "\n" + EnumChatFormatting.GOLD + nf.format(lc.lividDaggers) + "\n" + EnumChatFormatting.GOLD + nf.format(lc.shadowFurys) + "\n" + EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f5CoinsSpent) + "\n" + @@ -1760,6 +1754,7 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + "Shadow Chestplates:\n" + EnumChatFormatting.DARK_PURPLE + "Shadow Leggings:\n" + EnumChatFormatting.DARK_PURPLE + "Shadow Boots:\n" + + EnumChatFormatting.GOLD + "Last Breaths:\n" + EnumChatFormatting.GOLD + "Livid Daggers:\n" + EnumChatFormatting.GOLD + "Shadow Furys:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + @@ -1771,6 +1766,7 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssChestsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssLegsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssBootsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(lc.lastBreathsSession) + "\n" + EnumChatFormatting.GOLD + nf.format(lc.lividDaggersSession) + "\n" + EnumChatFormatting.GOLD + nf.format(lc.shadowFurysSession) + "\n" + EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f5CoinsSpentSession) + "\n" + @@ -1932,6 +1928,8 @@ public class TheMod @SubscribeEvent public void onTick(TickEvent.ClientTickEvent event) { + if (event.phase != Phase.START) return; + Minecraft mc = Minecraft.getMinecraft(); World world = mc.theWorld; EntityPlayerSP player = mc.thePlayer; @@ -2265,10 +2263,9 @@ public class TheMod } @SubscribeEvent - public void onGuiMouseInput(GuiScreenEvent.MouseInputEvent.Pre event) { + public void onGuiMouseInputPre(GuiScreenEvent.MouseInputEvent.Pre event) { if (!Utils.inSkyblock) return; if (Mouse.getEventButton() == lastMouse) return; - lastMouse = Mouse.getEventButton(); if (Mouse.getEventButton() != 0 && Mouse.getEventButton() != 1) return; // Left click or right click if (event.gui instanceof GuiChest) { @@ -2330,7 +2327,7 @@ public class TheMod } } - if (!BlockSlayerCommand.onlySlayerName.equals("")) { + if (!BlockSlayerCommand.onlySlayerName.equals("")) { if (inventoryName.equals("Slayer")) { if (!item.getDisplayName().contains("Revenant Horror") && !item.getDisplayName().contains("Tarantula Broodfather") && !item.getDisplayName().contains("Sven Packmaster")) return; if (!item.getDisplayName().contains(BlockSlayerCommand.onlySlayerName)) { @@ -2354,6 +2351,19 @@ public class TheMod } } + @SubscribeEvent + public void onMouseInputPost(GuiScreenEvent.MouseInputEvent.Post event) { + if (!Utils.inSkyblock) return; + if (Mouse.getEventButton() == lastMouse) return; + if (Mouse.getEventButton() == 0 && event.gui instanceof GuiChat) { + if (ToggleCommand.chatMaddoxToggled && System.currentTimeMillis() / 1000 - lastMaddoxTime < 10) { + Minecraft.getMinecraft().thePlayer.sendChatMessage(lastMaddoxCommand); + } + } + + lastMouse = Mouse.getEventButton(); + } + @SubscribeEvent public void onGuiRender(GuiScreenEvent.BackgroundDrawnEvent event) { if (!Utils.inSkyblock) return; diff --git a/src/main/java/me/Danker/commands/ChatMaddoxCommand.java b/src/main/java/me/Danker/commands/ChatMaddoxCommand.java deleted file mode 100644 index 518f26f..0000000 --- a/src/main/java/me/Danker/commands/ChatMaddoxCommand.java +++ /dev/null @@ -1,33 +0,0 @@ -package me.Danker.commands; - -import me.Danker.TheMod; -import net.minecraft.client.Minecraft; -import net.minecraft.command.CommandBase; -import net.minecraft.command.CommandException; -import net.minecraft.command.ICommandSender; -import net.minecraft.entity.player.EntityPlayer; - -public class ChatMaddoxCommand extends CommandBase { - - @Override - public String getCommandName() { - return "dmodopenmaddoxmenu"; - } - - @Override - public String getCommandUsage(ICommandSender arg0) { - return null; - } - - @Override - public int getRequiredPermissionLevel() { - return 0; - } - - @Override - public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { - if (!ToggleCommand.chatMaddoxToggled) return; - Minecraft.getMinecraft().thePlayer.sendChatMessage(TheMod.lastMaddoxCommand); - } - -} diff --git a/src/main/java/me/Danker/commands/LootCommand.java b/src/main/java/me/Danker/commands/LootCommand.java index 5139157..a7c7ced 100644 --- a/src/main/java/me/Danker/commands/LootCommand.java +++ b/src/main/java/me/Danker/commands/LootCommand.java @@ -105,6 +105,7 @@ public class LootCommand extends CommandBase { public static double f1TimeSpent; // F2 public static int scarfStudies; + public static int adaptiveSwords; public static double f2CoinsSpent; public static double f2TimeSpent; // F3 @@ -112,7 +113,6 @@ public class LootCommand extends CommandBase { public static int adaptiveChests; public static int adaptiveLegs; public static int adaptiveBoots; - public static int adaptiveSwords; public static double f3CoinsSpent; public static double f3TimeSpent; // F4 @@ -131,6 +131,7 @@ public class LootCommand extends CommandBase { public static int shadowAssChests; public static int shadowAssLegs; public static int shadowAssBoots; + public static int lastBreaths; public static int lividDaggers; public static int shadowFurys; public static double f5CoinsSpent; @@ -238,6 +239,7 @@ public class LootCommand extends CommandBase { public static double f1TimeSpentSession = 0; // F2 public static int scarfStudiesSession = 0; + public static int adaptiveSwordsSession = 0; public static double f2CoinsSpentSession = 0; public static double f2TimeSpentSession = 0; // F3 @@ -245,7 +247,6 @@ public class LootCommand extends CommandBase { public static int adaptiveChestsSession = 0; public static int adaptiveLegsSession = 0; public static int adaptiveBootsSession = 0; - public static int adaptiveSwordsSession = 0; public static double f3CoinsSpentSession = 0; public static double f3TimeSpentSession = 0; // F4 @@ -264,6 +265,7 @@ public class LootCommand extends CommandBase { public static int shadowAssChestsSession = 0; public static int shadowAssLegsSession = 0; public static int shadowAssBootsSession = 0; + public static int lastBreathsSession = 0; public static int lividDaggersSession = 0; public static int shadowFurysSession = 0; public static double f5CoinsSpentSession = 0; @@ -717,6 +719,7 @@ public class LootCommand extends CommandBase { EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + EnumChatFormatting.BLUE + " Scarf's Studies: " + nf.format(scarfStudiesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Adaptive Blades: " + nf.format(adaptiveSwordsSession) + "\n" + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f2CoinsSpentSession) + "\n" + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f2TimeSpentSession) + "\n" + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); @@ -727,6 +730,7 @@ public class LootCommand extends CommandBase { EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + EnumChatFormatting.BLUE + " Scarf's Studies: " + nf.format(scarfStudies) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Adaptive Blades: " + nf.format(adaptiveSwords) + "\n" + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f2CoinsSpent) + "\n" + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f2TimeSpent) + "\n" + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); @@ -740,7 +744,6 @@ public class LootCommand extends CommandBase { EnumChatFormatting.DARK_PURPLE + " Adaptive Chestplates: " + nf.format(adaptiveChestsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + " Adaptive Leggings: " + nf.format(adaptiveLegsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + " Adaptive Boots: " + nf.format(adaptiveBootsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Adaptive Blades: " + nf.format(adaptiveSwordsSession) + "\n" + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f3CoinsSpentSession) + "\n" + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f3TimeSpentSession) + "\n" + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); @@ -754,7 +757,6 @@ public class LootCommand extends CommandBase { EnumChatFormatting.DARK_PURPLE + " Adaptive Chestplates: " + nf.format(adaptiveChests) + "\n" + EnumChatFormatting.DARK_PURPLE + " Adaptive Leggings: " + nf.format(adaptiveLegs) + "\n" + EnumChatFormatting.DARK_PURPLE + " Adaptive Boots: " + nf.format(adaptiveBoots) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Adaptive Blades: " + nf.format(adaptiveSwords) + "\n" + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f3CoinsSpent) + "\n" + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f3TimeSpent) + "\n" + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); @@ -801,6 +803,7 @@ public class LootCommand extends CommandBase { EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Chests: " + nf.format(shadowAssChestsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Legs: " + nf.format(shadowAssLegsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Boots: " + nf.format(shadowAssBootsSession) + "\n" + + EnumChatFormatting.GOLD + " Last Breaths: " + nf.format(lastBreathsSession) + "\n" + EnumChatFormatting.GOLD + " Livid Daggers: " + nf.format(lividDaggersSession) + "\n" + EnumChatFormatting.GOLD + " Shadow Furys: " + nf.format(shadowFurysSession) + "\n" + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f5CoinsSpentSession) + "\n" + @@ -817,6 +820,7 @@ public class LootCommand extends CommandBase { EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Chests: " + nf.format(shadowAssChests) + "\n" + EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Legs: " + nf.format(shadowAssLegs) + "\n" + EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Boots: " + nf.format(shadowAssBoots) + "\n" + + EnumChatFormatting.GOLD + " Last Breaths: " + nf.format(lastBreaths) + "\n" + EnumChatFormatting.GOLD + " Livid Daggers: " + nf.format(lividDaggers) + "\n" + EnumChatFormatting.GOLD + " Shadow Furys: " + nf.format(shadowFurys) + "\n" + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f5CoinsSpent) + "\n" + diff --git a/src/main/java/me/Danker/commands/ToggleCommand.java b/src/main/java/me/Danker/commands/ToggleCommand.java index df39af6..563c403 100644 --- a/src/main/java/me/Danker/commands/ToggleCommand.java +++ b/src/main/java/me/Danker/commands/ToggleCommand.java @@ -21,7 +21,6 @@ public class ToggleCommand extends CommandBase implements ICommand { public static boolean rngesusAlerts; public static boolean splitFishing; public static boolean chatMaddoxToggled; - public static boolean trueChatMaddoxEnabled; public static boolean spiritBearAlerts; public static boolean aotdToggled; public static boolean lividDaggerToggled; @@ -111,7 +110,7 @@ public class ToggleCommand extends CommandBase implements ICommand { } else if (arg1[0].equalsIgnoreCase("chatmaddox")) { chatMaddoxToggled = !chatMaddoxToggled; cf.writeBooleanConfig("toggles", "ChatMaddox", chatMaddoxToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Chat Maddox menu has been set to " + TheMod.SECONDARY_COLOUR + chatMaddoxToggled + TheMod.MAIN_COLOUR + ".")); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Click screen to open Maddox menu has been set to " + TheMod.SECONDARY_COLOUR + chatMaddoxToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("spiritbearalerts")) { spiritBearAlerts = !spiritBearAlerts; cf.writeBooleanConfig("toggles", "SpiritBearAlerts", spiritBearAlerts); diff --git a/src/main/java/me/Danker/gui/DankerGui.java b/src/main/java/me/Danker/gui/DankerGui.java index d77df14..8667461 100644 --- a/src/main/java/me/Danker/gui/DankerGui.java +++ b/src/main/java/me/Danker/gui/DankerGui.java @@ -88,7 +88,7 @@ public class DankerGui extends GuiScreen { skill50Display = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Display Progress To Skill Level 50: " + Utils.getColouredBoolean(ToggleCommand.skill50DisplayToggled)); gparty = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Guild Party Notifications: " + Utils.getColouredBoolean(ToggleCommand.gpartyToggled)); slayerCount = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Count Total 20% Drops: " + Utils.getColouredBoolean(ToggleCommand.slayerCountTotal)); - chatMaddox = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Click Chat to Open Maddox: " + Utils.getColouredBoolean(ToggleCommand.chatMaddoxToggled)); + chatMaddox = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Click On-Screen to Open Maddox: " + Utils.getColouredBoolean(ToggleCommand.chatMaddoxToggled)); aotd = new GuiButton(0, width / 2 - 100, (int) (height * 0.6), "Disable AOTD Ability: " + Utils.getColouredBoolean(ToggleCommand.aotdToggled)); lividDagger = new GuiButton(0, width / 2 - 100, (int) (height * 0.7), "Disable Livid Dagger Ability: " + Utils.getColouredBoolean(ToggleCommand.lividDaggerToggled)); // Page 3 @@ -239,7 +239,7 @@ public class DankerGui extends GuiScreen { } else if (button == chatMaddox) { ToggleCommand.chatMaddoxToggled = !ToggleCommand.chatMaddoxToggled; ConfigHandler.writeBooleanConfig("toggles", "ChatMaddox", ToggleCommand.chatMaddoxToggled); - chatMaddox.displayString = "Click Chat to Open Maddox: " + Utils.getColouredBoolean(ToggleCommand.chatMaddoxToggled); + chatMaddox.displayString = "Click On-Screen to Open Maddox: " + Utils.getColouredBoolean(ToggleCommand.chatMaddoxToggled); } else if (button == spiritBearAlert) { ToggleCommand.spiritBearAlerts = !ToggleCommand.spiritBearAlerts; ConfigHandler.writeBooleanConfig("toggles", "SpiritBearAlerts", ToggleCommand.spiritBearAlerts); diff --git a/src/main/java/me/Danker/handlers/ConfigHandler.java b/src/main/java/me/Danker/handlers/ConfigHandler.java index 408849c..5a59308 100644 --- a/src/main/java/me/Danker/handlers/ConfigHandler.java +++ b/src/main/java/me/Danker/handlers/ConfigHandler.java @@ -319,6 +319,7 @@ public class ConfigHandler { if (!hasKey("catacombs", "shadowAssassinChest")) writeIntConfig("catacombs", "shadowAssassinChest", 0); if (!hasKey("catacombs", "shadowAssassinLegging")) writeIntConfig("catacombs", "shadowAssassinLegging", 0); if (!hasKey("catacombs", "shadowAssassinBoot")) writeIntConfig("catacombs", "shadowAssassinBoot", 0); + if (!hasKey("catacombs", "lastBreath")) writeIntConfig("catacombs", "lastBreath", 0); if (!hasKey("catacombs", "lividDagger")) writeIntConfig("catacombs", "lividDagger", 0); if (!hasKey("catacombs", "shadowFury")) writeIntConfig("catacombs", "shadowFury", 0); if (!hasKey("catacombs", "floorFiveCoins")) writeDoubleConfig("catacombs", "floorFiveCoins", 0); @@ -338,7 +339,6 @@ public class ConfigHandler { if (!hasKey("misc", "display")) writeStringConfig("misc", "display", "off"); if (!hasKey("misc", "autoDisplay")) writeBooleanConfig("misc", "autoDisplay", false); if (!hasKey("misc", "skill50Time")) writeIntConfig("misc", "skill50Time", 3); - if (!hasKey("misc", "trueChatMaddoxEnabled")) writeBooleanConfig("misc", "trueChatMaddoxEnabled", true); if (!hasKey("misc", "cakeTime")) writeDoubleConfig("misc", "cakeTime", 0); ScaledResolution scaled = new ScaledResolution(Minecraft.getMinecraft()); @@ -527,6 +527,7 @@ public class ConfigHandler { lc.shadowAssChests = getInt("catacombs", "shadowAssassinChest"); lc.shadowAssLegs = getInt("catacombs", "shadowAssassinLegging"); lc.shadowAssBoots = getInt("catacombs", "shadowAssassinBoot"); + lc.lastBreaths = getInt("catacombs", "lastBreath"); lc.lividDaggers = getInt("catacombs", "lividDagger"); lc.shadowFurys = getInt("catacombs", "shadowFury"); lc.f5CoinsSpent = getDouble("catacombs", "floorFiveCoins"); @@ -547,7 +548,6 @@ public class ConfigHandler { ds.display = getString("misc", "display"); ds.auto = getBoolean("misc", "autoDisplay"); TheMod.SKILL_TIME = getInt("misc", "skill50Time") * 20; - tf.trueChatMaddoxEnabled = getBoolean("misc", "trueChatMaddoxEnabled"); TheMod.cakeTime = getDouble("misc", "cakeTime"); final MoveCommand moc = new MoveCommand(); -- cgit From 43c6b9c0387eb0294d12f9de22baad7f9235b86f Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Sat, 21 Nov 2020 19:16:08 -0500 Subject: Access static methods in static ways and remove unused imports --- src/main/java/me/Danker/TheMod.java | 1510 ++++++++++---------- .../java/me/Danker/commands/ArmourCommand.java | 13 +- src/main/java/me/Danker/commands/BankCommand.java | 10 +- .../me/Danker/commands/BlockSlayerCommand.java | 6 +- .../java/me/Danker/commands/DankerGuiCommand.java | 2 - .../java/me/Danker/commands/DisplayCommand.java | 8 +- .../java/me/Danker/commands/DungeonsCommand.java | 10 +- .../java/me/Danker/commands/GetkeyCommand.java | 8 +- .../java/me/Danker/commands/GuildOfCommand.java | 10 +- .../me/Danker/commands/ImportFishingCommand.java | 258 ++-- .../me/Danker/commands/LobbySkillsCommand.java | 9 +- src/main/java/me/Danker/commands/MoveCommand.java | 26 +- src/main/java/me/Danker/commands/PetsCommand.java | 10 +- .../me/Danker/commands/ReloadConfigCommand.java | 4 +- .../java/me/Danker/commands/ResetLootCommand.java | 260 ++-- src/main/java/me/Danker/commands/ScaleCommand.java | 1 - .../java/me/Danker/commands/SetkeyCommand.java | 4 +- .../java/me/Danker/commands/SkillsCommand.java | 12 +- .../me/Danker/commands/SkyblockPlayersCommand.java | 6 +- .../java/me/Danker/commands/SlayerCommand.java | 10 +- .../java/me/Danker/commands/ToggleCommand.java | 54 +- src/main/java/me/Danker/gui/DankerGui.java | 1 - src/main/java/me/Danker/gui/EditLocationsGui.java | 15 +- src/main/java/me/Danker/handlers/APIHandler.java | 1 - .../java/me/Danker/handlers/ConfigHandler.java | 335 +++-- 25 files changed, 1247 insertions(+), 1336 deletions(-) (limited to 'src/main/java/me/Danker/gui') diff --git a/src/main/java/me/Danker/TheMod.java b/src/main/java/me/Danker/TheMod.java index 65372cc..8cb1203 100644 --- a/src/main/java/me/Danker/TheMod.java +++ b/src/main/java/me/Danker/TheMod.java @@ -91,7 +91,6 @@ import net.minecraftforge.event.entity.player.ItemTooltipEvent; import net.minecraftforge.event.entity.player.PlayerInteractEvent; import net.minecraftforge.event.world.WorldEvent; import net.minecraftforge.fml.client.registry.ClientRegistry; -import net.minecraftforge.fml.common.FMLCommonHandler; import net.minecraftforge.fml.common.Loader; import net.minecraftforge.fml.common.Mod; import net.minecraftforge.fml.common.Mod.EventHandler; @@ -173,12 +172,10 @@ public class TheMod @EventHandler public void init(FMLInitializationEvent event) { - FMLCommonHandler.instance().bus().register(this); MinecraftForge.EVENT_BUS.register(this); MinecraftForge.EVENT_BUS.register(new PacketHandler()); - final ConfigHandler cf = new ConfigHandler(); - cf.reloadConfig(); + ConfigHandler.reloadConfig(); // For golden enchants t6Enchants.put("9Angler VI", "6Angler VI"); @@ -299,11 +296,10 @@ public class TheMod // MULTI THREAD DRIFTING new Thread(() -> { - APIHandler ah = new APIHandler(); EntityPlayer player = Minecraft.getMinecraft().thePlayer; System.err.println("Checking for updates..."); - JsonObject latestRelease = ah.getResponse("https://api.github.com/repos/bowser0000/SkyblockMod/releases/latest"); + JsonObject latestRelease = APIHandler.getResponse("https://api.github.com/repos/bowser0000/SkyblockMod/releases/latest"); String latestTag = latestRelease.get("tag_name").getAsString(); DefaultArtifactVersion currentVersion = new DefaultArtifactVersion(VERSION); @@ -335,7 +331,6 @@ public class TheMod // It randomly broke, so I had to make it the highest priority @SubscribeEvent(priority = EventPriority.HIGHEST) public void onChat(ClientChatReceivedEvent event) { - final ToggleCommand tc = new ToggleCommand(); String message = StringUtils.stripControlCodes(event.message.getUnformattedText()); if (!Utils.inSkyblock) return; @@ -344,7 +339,7 @@ public class TheMod if (event.type == 2) { String[] actionBarSections = event.message.getUnformattedText().split(" {3,}"); for (String section : actionBarSections) { - if (tc.skill50DisplayToggled) { + if (ToggleCommand.skill50DisplayToggled) { if (section.contains("+") && section.contains("/") && section.contains("(")) { if (section.contains("Runecrafting")) return; @@ -393,17 +388,17 @@ public class TheMod if (message.contains(":")) return; // Spirit Sceptre - if (!tc.sceptreMessages && message.contains("Your Spirit Sceptre hit ")) { + if (!ToggleCommand.sceptreMessages && message.contains("Your Spirit Sceptre hit ")) { event.setCanceled(true); return; } // Midas Staff - if (!tc.midasStaffMessages && message.contains("Your Molten Wave hit ")) { + if (!ToggleCommand.midasStaffMessages && message.contains("Your Molten Wave hit ")) { event.setCanceled(true); return; } // Heals - if (!tc.healMessages && message.contains(" health!") && (message.contains("You healed ") || message.contains(" healed you for "))) { + if (!ToggleCommand.healMessages && message.contains(" health!") && (message.contains("You healed ") || message.contains(" healed you for "))) { event.setCanceled(true); return; } @@ -436,7 +431,7 @@ public class TheMod } } - if (tc.gpartyToggled) { + if (ToggleCommand.gpartyToggled) { if (message.contains(" has invited all members of ")) { try { final SystemTray tray = SystemTray.getSystemTray(); @@ -453,7 +448,7 @@ public class TheMod } } - if (tc.golemAlertToggled) { + if (ToggleCommand.golemAlertToggled) { if (message.contains("The ground begins to shake as an Endstone Protector rises from below!")) { Utils.createTitle(EnumChatFormatting.RED + "GOLEM SPAWNING!", 3); } @@ -464,8 +459,6 @@ public class TheMod ConfigHandler.writeDoubleConfig("misc", "cakeTime", cakeTime); } - final LootCommand lc = new LootCommand(); - final ConfigHandler cf = new ConfigHandler(); boolean wolfRNG = false; boolean spiderRNG = false; boolean zombieRNG = false; @@ -476,304 +469,303 @@ public class TheMod for (String s : scoreboard) { String sCleaned = ScoreboardHandler.cleanSB(s); if (sCleaned.contains("Sven Packmaster")) { - lc.wolfBooks++; - cf.writeIntConfig("wolf", "book", lc.wolfBooks); + LootCommand.wolfBooks++; + ConfigHandler.writeIntConfig("wolf", "book", LootCommand.wolfBooks); } else if (sCleaned.contains("Tarantula Broodfather")) { - lc.spiderBooks++; - cf.writeIntConfig("spider", "book", lc.spiderBooks); + LootCommand.spiderBooks++; + ConfigHandler.writeIntConfig("spider", "book", LootCommand.spiderBooks); } else if (sCleaned.contains("Revenant Horror")) { - lc.zombieBooks++; - cf.writeIntConfig("zombie", "book", lc.zombieBooks); + LootCommand.zombieBooks++; + ConfigHandler.writeIntConfig("zombie", "book", LootCommand.zombieBooks); } } } // Wolf if (message.contains("Talk to Maddox to claim your Wolf Slayer XP!")) { - lc.wolfSvens++; - lc.wolfSvensSession++; - if (lc.wolfBosses != -1) { - lc.wolfBosses++; + LootCommand.wolfSvens++; + LootCommand.wolfSvensSession++; + if (LootCommand.wolfBosses != -1) { + LootCommand.wolfBosses++; } - if (lc.wolfBossesSession != -1) { - lc.wolfBossesSession++; + if (LootCommand.wolfBossesSession != -1) { + LootCommand.wolfBossesSession++; } - cf.writeIntConfig("wolf", "svens", lc.wolfSvens); - cf.writeIntConfig("wolf", "bossRNG", lc.wolfBosses); + ConfigHandler.writeIntConfig("wolf", "svens", LootCommand.wolfSvens); + ConfigHandler.writeIntConfig("wolf", "bossRNG", LootCommand.wolfBosses); } else if (message.contains("RARE DROP! (Hamster Wheel)")) { - lc.wolfWheelsDrops++; - lc.wolfWheelsDropsSession++; - cf.writeIntConfig("wolf", "wheelDrops", lc.wolfWheelsDrops); + LootCommand.wolfWheelsDrops++; + LootCommand.wolfWheelsDropsSession++; + ConfigHandler.writeIntConfig("wolf", "wheelDrops", LootCommand.wolfWheelsDrops); } else if (message.contains("VERY RARE DROP! (") && message.contains(" Spirit Rune I)")) { // Removing the unicode here *should* fix rune drops not counting - lc.wolfSpirits++; - lc.wolfSpiritsSession++; - cf.writeIntConfig("wolf", "spirit", lc.wolfSpirits); + LootCommand.wolfSpirits++; + LootCommand.wolfSpiritsSession++; + ConfigHandler.writeIntConfig("wolf", "spirit", LootCommand.wolfSpirits); } else if (message.contains("CRAZY RARE DROP! (Red Claw Egg)")) { wolfRNG = true; - lc.wolfEggs++; - lc.wolfEggsSession++; - cf.writeIntConfig("wolf", "egg", lc.wolfEggs); - if (tc.rngesusAlerts) Utils.createTitle(EnumChatFormatting.DARK_RED + "RED CLAW EGG!", 3); + LootCommand.wolfEggs++; + LootCommand.wolfEggsSession++; + ConfigHandler.writeIntConfig("wolf", "egg", LootCommand.wolfEggs); + if (ToggleCommand.rngesusAlerts) Utils.createTitle(EnumChatFormatting.DARK_RED + "RED CLAW EGG!", 3); } else if (message.contains("CRAZY RARE DROP! (") && message.contains(" Couture Rune I)")) { wolfRNG = true; - lc.wolfCoutures++; - lc.wolfCouturesSession++; - cf.writeIntConfig("wolf", "couture", lc.wolfCoutures); - if (tc.rngesusAlerts) Utils.createTitle(EnumChatFormatting.GOLD + "COUTURE RUNE!", 3); + LootCommand.wolfCoutures++; + LootCommand.wolfCouturesSession++; + ConfigHandler.writeIntConfig("wolf", "couture", LootCommand.wolfCoutures); + if (ToggleCommand.rngesusAlerts) Utils.createTitle(EnumChatFormatting.GOLD + "COUTURE RUNE!", 3); } else if (message.contains("CRAZY RARE DROP! (Grizzly Bait)") || message.contains("CRAZY RARE DROP! (Rename Me)")) { // How did Skyblock devs even manage to make this item Rename Me wolfRNG = true; - lc.wolfBaits++; - lc.wolfBaitsSession++; - cf.writeIntConfig("wolf", "bait", lc.wolfBaits); - if (tc.rngesusAlerts) Utils.createTitle(EnumChatFormatting.AQUA + "GRIZZLY BAIT!", 3); + LootCommand.wolfBaits++; + LootCommand.wolfBaitsSession++; + ConfigHandler.writeIntConfig("wolf", "bait", LootCommand.wolfBaits); + if (ToggleCommand.rngesusAlerts) Utils.createTitle(EnumChatFormatting.AQUA + "GRIZZLY BAIT!", 3); } else if (message.contains("CRAZY RARE DROP! (Overflux Capacitor)")) { wolfRNG = true; - lc.wolfFluxes++; - lc.wolfFluxesSession++; - cf.writeIntConfig("wolf", "flux", lc.wolfFluxes); - if (tc.rngesusAlerts) Utils.createTitle(EnumChatFormatting.DARK_PURPLE + "OVERFLUX CAPACITOR!", 5); + LootCommand.wolfFluxes++; + LootCommand.wolfFluxesSession++; + ConfigHandler.writeIntConfig("wolf", "flux", LootCommand.wolfFluxes); + if (ToggleCommand.rngesusAlerts) Utils.createTitle(EnumChatFormatting.DARK_PURPLE + "OVERFLUX CAPACITOR!", 5); } else if (message.contains("Talk to Maddox to claim your Spider Slayer XP!")) { // Spider - lc.spiderTarantulas++; - lc.spiderTarantulasSession++; - if (lc.spiderBosses != -1) { - lc.spiderBosses++; + LootCommand.spiderTarantulas++; + LootCommand.spiderTarantulasSession++; + if (LootCommand.spiderBosses != -1) { + LootCommand.spiderBosses++; } - if (lc.spiderBossesSession != -1) { - lc.spiderBossesSession++; + if (LootCommand.spiderBossesSession != -1) { + LootCommand.spiderBossesSession++; } - cf.writeIntConfig("spider", "tarantulas", lc.spiderTarantulas); - cf.writeIntConfig("spider", "bossRNG", lc.spiderBosses); + ConfigHandler.writeIntConfig("spider", "tarantulas", LootCommand.spiderTarantulas); + ConfigHandler.writeIntConfig("spider", "bossRNG", LootCommand.spiderBosses); } else if (message.contains("RARE DROP! (Toxic Arrow Poison)")) { - lc.spiderTAPDrops++; - lc.spiderTAPDropsSession++; - cf.writeIntConfig("spider", "tapDrops", lc.spiderTAPDrops); + LootCommand.spiderTAPDrops++; + LootCommand.spiderTAPDropsSession++; + ConfigHandler.writeIntConfig("spider", "tapDrops", LootCommand.spiderTAPDrops); } else if (message.contains("VERY RARE DROP! (") && message.contains(" Bite Rune I)")) { - lc.spiderBites++; - lc.spiderBitesSession++; - cf.writeIntConfig("spider", "bite", lc.spiderBites); + LootCommand.spiderBites++; + LootCommand.spiderBitesSession++; + ConfigHandler.writeIntConfig("spider", "bite", LootCommand.spiderBites); } else if (message.contains("VERY RARE DROP! (Spider Catalyst)")) { - lc.spiderCatalysts++; - lc.spiderCatalystsSession++; - cf.writeIntConfig("spider", "catalyst", lc.spiderCatalysts); + LootCommand.spiderCatalysts++; + LootCommand.spiderCatalystsSession++; + ConfigHandler.writeIntConfig("spider", "catalyst", LootCommand.spiderCatalysts); } else if (message.contains("CRAZY RARE DROP! (Fly Swatter)")) { spiderRNG = true; - lc.spiderSwatters++; - lc.spiderSwattersSession++; - cf.writeIntConfig("spider", "swatter", lc.spiderSwatters); - if (tc.rngesusAlerts) Utils.createTitle(EnumChatFormatting.LIGHT_PURPLE + "FLY SWATTER!", 3); + LootCommand.spiderSwatters++; + LootCommand.spiderSwattersSession++; + ConfigHandler.writeIntConfig("spider", "swatter", LootCommand.spiderSwatters); + if (ToggleCommand.rngesusAlerts) Utils.createTitle(EnumChatFormatting.LIGHT_PURPLE + "FLY SWATTER!", 3); } else if (message.contains("CRAZY RARE DROP! (Tarantula Talisman")) { spiderRNG = true; - lc.spiderTalismans++; - lc.spiderTalismansSession++; - cf.writeIntConfig("spider", "talisman", lc.spiderTalismans); - if (tc.rngesusAlerts) Utils.createTitle(EnumChatFormatting.DARK_PURPLE + "TARANTULA TALISMAN!", 3); + LootCommand.spiderTalismans++; + LootCommand.spiderTalismansSession++; + ConfigHandler.writeIntConfig("spider", "talisman", LootCommand.spiderTalismans); + if (ToggleCommand.rngesusAlerts) Utils.createTitle(EnumChatFormatting.DARK_PURPLE + "TARANTULA TALISMAN!", 3); } else if (message.contains("CRAZY RARE DROP! (Digested Mosquito)")) { spiderRNG = true; - lc.spiderMosquitos++; - lc.spiderMosquitosSession++; - cf.writeIntConfig("spider", "mosquito", lc.spiderMosquitos); - if (tc.rngesusAlerts) Utils.createTitle(EnumChatFormatting.GOLD + "DIGESTED MOSQUITO!", 5); + LootCommand.spiderMosquitos++; + LootCommand.spiderMosquitosSession++; + ConfigHandler.writeIntConfig("spider", "mosquito", LootCommand.spiderMosquitos); + if (ToggleCommand.rngesusAlerts) Utils.createTitle(EnumChatFormatting.GOLD + "DIGESTED MOSQUITO!", 5); } else if (message.contains("Talk to Maddox to claim your Zombie Slayer XP!")) { // Zombie - lc.zombieRevs++; - lc.zombieRevsSession++; - if (lc.zombieBosses != -1) { - lc.zombieBosses++; + LootCommand.zombieRevs++; + LootCommand.zombieRevsSession++; + if (LootCommand.zombieBosses != -1) { + LootCommand.zombieBosses++; } - if (lc.zombieBossesSession != 1) { - lc.zombieBossesSession++; + if (LootCommand.zombieBossesSession != 1) { + LootCommand.zombieBossesSession++; } - cf.writeIntConfig("zombie", "revs", lc.zombieRevs); - cf.writeIntConfig("zombie", "bossRNG", lc.zombieBosses); + ConfigHandler.writeIntConfig("zombie", "revs", LootCommand.zombieRevs); + ConfigHandler.writeIntConfig("zombie", "bossRNG", LootCommand.zombieBosses); } else if (message.contains("RARE DROP! (Foul Flesh)")) { - lc.zombieFoulFleshDrops++; - lc.zombieFoulFleshDropsSession++; - cf.writeIntConfig("zombie", "foulFleshDrops", lc.zombieFoulFleshDrops); + LootCommand.zombieFoulFleshDrops++; + LootCommand.zombieFoulFleshDropsSession++; + ConfigHandler.writeIntConfig("zombie", "foulFleshDrops", LootCommand.zombieFoulFleshDrops); } else if (message.contains("VERY RARE DROP! (Revenant Catalyst)")) { - lc.zombieRevCatas++; - lc.zombieRevCatasSession++; - cf.writeIntConfig("zombie", "revCatalyst", lc.zombieRevCatas); + LootCommand.zombieRevCatas++; + LootCommand.zombieRevCatasSession++; + ConfigHandler.writeIntConfig("zombie", "revCatalyst", LootCommand.zombieRevCatas); } else if (message.contains("VERY RARE DROP! (") && message.contains(" Pestilence Rune I)")) { - lc.zombiePestilences++; - lc.zombiePestilencesSession++; - cf.writeIntConfig("zombie", "pestilence", lc.zombiePestilences); + LootCommand.zombiePestilences++; + LootCommand.zombiePestilencesSession++; + ConfigHandler.writeIntConfig("zombie", "pestilence", LootCommand.zombiePestilences); } else if (message.contains("VERY RARE DROP! (Undead Catalyst)")) { - lc.zombieUndeadCatas++; - lc.zombieUndeadCatasSession++; - cf.writeIntConfig("zombie", "undeadCatalyst", lc.zombieUndeadCatas); + LootCommand.zombieUndeadCatas++; + LootCommand.zombieUndeadCatasSession++; + ConfigHandler.writeIntConfig("zombie", "undeadCatalyst", LootCommand.zombieUndeadCatas); } else if (message.contains("CRAZY RARE DROP! (Beheaded Horror)")) { zombieRNG = true; - lc.zombieBeheadeds++; - lc.zombieBeheadedsSession++; - cf.writeIntConfig("zombie", "beheaded", lc.zombieBeheadeds); - if (tc.rngesusAlerts) Utils.createTitle(EnumChatFormatting.DARK_PURPLE + "BEHEADED HORROR!", 3); + LootCommand.zombieBeheadeds++; + LootCommand.zombieBeheadedsSession++; + ConfigHandler.writeIntConfig("zombie", "beheaded", LootCommand.zombieBeheadeds); + if (ToggleCommand.rngesusAlerts) Utils.createTitle(EnumChatFormatting.DARK_PURPLE + "BEHEADED HORROR!", 3); } else if (message.contains("CRAZY RARE DROP! (") && message.contains(" Snake Rune I)")) { zombieRNG = true; - lc.zombieSnakes++; - lc.zombieSnakesSession++; - cf.writeIntConfig("zombie", "snake", lc.zombieSnakes); - if (tc.rngesusAlerts) Utils.createTitle(EnumChatFormatting.DARK_GREEN + "SNAKE RUNE!", 3); + LootCommand.zombieSnakes++; + LootCommand.zombieSnakesSession++; + ConfigHandler.writeIntConfig("zombie", "snake", LootCommand.zombieSnakes); + if (ToggleCommand.rngesusAlerts) Utils.createTitle(EnumChatFormatting.DARK_GREEN + "SNAKE RUNE!", 3); } else if (message.contains("CRAZY RARE DROP! (Scythe Blade)")) { zombieRNG = true; - lc.zombieScythes++; - lc.zombieScythesSession++; - cf.writeIntConfig("zombie", "scythe", lc.zombieScythes); - if (tc.rngesusAlerts) Utils.createTitle(EnumChatFormatting.GOLD + "SCYTHE BLADE!", 5); + LootCommand.zombieScythes++; + LootCommand.zombieScythesSession++; + ConfigHandler.writeIntConfig("zombie", "scythe", LootCommand.zombieScythes); + if (ToggleCommand.rngesusAlerts) Utils.createTitle(EnumChatFormatting.GOLD + "SCYTHE BLADE!", 5); } else if (message.contains("GOOD CATCH!")) { // Fishing - lc.goodCatches++; - lc.goodCatchesSession++; - cf.writeIntConfig("fishing", "goodCatch", lc.goodCatches); + LootCommand.goodCatches++; + LootCommand.goodCatchesSession++; + ConfigHandler.writeIntConfig("fishing", "goodCatch", LootCommand.goodCatches); } else if (message.contains("GREAT CATCH!")) { - lc.greatCatches++; - lc.greatCatchesSession++; - cf.writeIntConfig("fishing", "greatCatch", lc.greatCatches); + LootCommand.greatCatches++; + LootCommand.greatCatchesSession++; + ConfigHandler.writeIntConfig("fishing", "greatCatch", LootCommand.greatCatches); } else if (message.contains("A Squid appeared")) { - lc.squids++; - lc.squidsSession++; - cf.writeIntConfig("fishing", "squid", lc.squids); + LootCommand.squids++; + LootCommand.squidsSession++; + ConfigHandler.writeIntConfig("fishing", "squid", LootCommand.squids); increaseSeaCreatures(); } else if (message.contains("You caught a Sea Walker")) { - lc.seaWalkers++; - lc.seaWalkersSession++; - cf.writeIntConfig("fishing", "seaWalker", lc.seaWalkers); + LootCommand.seaWalkers++; + LootCommand.seaWalkersSession++; + ConfigHandler.writeIntConfig("fishing", "seaWalker", LootCommand.seaWalkers); increaseSeaCreatures(); } else if (message.contains("Pitch darkness reveals a Night Squid")) { - lc.nightSquids++; - lc.nightSquidsSession++; - cf.writeIntConfig("fishing", "nightSquid", lc.nightSquids); + LootCommand.nightSquids++; + LootCommand.nightSquidsSession++; + ConfigHandler.writeIntConfig("fishing", "nightSquid", LootCommand.nightSquids); increaseSeaCreatures(); } else if (message.contains("You stumbled upon a Sea Guardian")) { - lc.seaGuardians++; - lc.seaGuardiansSession++; - cf.writeIntConfig("fishing", "seaGuardian", lc.seaGuardians); + LootCommand.seaGuardians++; + LootCommand.seaGuardiansSession++; + ConfigHandler.writeIntConfig("fishing", "seaGuardian", LootCommand.seaGuardians); increaseSeaCreatures(); } else if (message.contains("It looks like you've disrupted the Sea Witch's brewing session. Watch out, she's furious")) { - lc.seaWitches++; - lc.seaWitchesSession++; - cf.writeIntConfig("fishing", "seaWitch", lc.seaWitches); + LootCommand.seaWitches++; + LootCommand.seaWitchesSession++; + ConfigHandler.writeIntConfig("fishing", "seaWitch", LootCommand.seaWitches); increaseSeaCreatures(); } else if (message.contains("You reeled in a Sea Archer")) { - lc.seaArchers++; - lc.seaArchersSession++; - cf.writeIntConfig("fishing", "seaArcher", lc.seaArchers); + LootCommand.seaArchers++; + LootCommand.seaArchersSession++; + ConfigHandler.writeIntConfig("fishing", "seaArcher", LootCommand.seaArchers); increaseSeaCreatures(); } else if (message.contains("The Monster of the Deep has emerged")) { - lc.monsterOfTheDeeps++; - lc.monsterOfTheDeepsSession++; - cf.writeIntConfig("fishing", "monsterOfDeep", lc.monsterOfTheDeeps); + LootCommand.monsterOfTheDeeps++; + LootCommand.monsterOfTheDeepsSession++; + ConfigHandler.writeIntConfig("fishing", "monsterOfDeep", LootCommand.monsterOfTheDeeps); increaseSeaCreatures(); } else if (message.contains("Huh? A Catfish")) { - lc.catfishes++; - lc.catfishesSession++; - cf.writeIntConfig("fishing", "catfish", lc.catfishes); + LootCommand.catfishes++; + LootCommand.catfishesSession++; + ConfigHandler.writeIntConfig("fishing", "catfish", LootCommand.catfishes); increaseSeaCreatures(); } else if (message.contains("Is this even a fish? It's the Carrot King")) { - lc.carrotKings++; - lc.carrotKingsSession++; - cf.writeIntConfig("fishing", "carrotKing", lc.carrotKings); + LootCommand.carrotKings++; + LootCommand.carrotKingsSession++; + ConfigHandler.writeIntConfig("fishing", "carrotKing", LootCommand.carrotKings); increaseSeaCreatures(); } else if (message.contains("Gross! A Sea Leech")) { - lc.seaLeeches++; - lc.seaLeechesSession++; - cf.writeIntConfig("fishing", "seaLeech", lc.seaLeeches); + LootCommand.seaLeeches++; + LootCommand.seaLeechesSession++; + ConfigHandler.writeIntConfig("fishing", "seaLeech", LootCommand.seaLeeches); increaseSeaCreatures(); } else if (message.contains("You've discovered a Guardian Defender of the sea")) { - lc.guardianDefenders++; - lc.guardianDefendersSession++; - cf.writeIntConfig("fishing", "guardianDefender", lc.guardianDefenders); + LootCommand.guardianDefenders++; + LootCommand.guardianDefendersSession++; + ConfigHandler.writeIntConfig("fishing", "guardianDefender", LootCommand.guardianDefenders); increaseSeaCreatures(); } else if (message.contains("You have awoken the Deep Sea Protector, prepare for a battle")) { - lc.deepSeaProtectors++; - lc.deepSeaProtectorsSession++; - cf.writeIntConfig("fishing", "deepSeaProtector", lc.deepSeaProtectors); + LootCommand.deepSeaProtectors++; + LootCommand.deepSeaProtectorsSession++; + ConfigHandler.writeIntConfig("fishing", "deepSeaProtector", LootCommand.deepSeaProtectors); increaseSeaCreatures(); } else if (message.contains("The Water Hydra has come to test your strength")) { - lc.hydras++; - lc.hydrasSession++; - cf.writeIntConfig("fishing", "hydra", lc.hydras); + LootCommand.hydras++; + LootCommand.hydrasSession++; + ConfigHandler.writeIntConfig("fishing", "hydra", LootCommand.hydras); increaseSeaCreatures(); } else if (message.contains("The Sea Emperor arises from the depths")) { increaseSeaCreatures(); - lc.seaEmperors++; - lc.empTime = System.currentTimeMillis() / 1000; - lc.empSCs = 0; - lc.seaEmperorsSession++; - lc.empTimeSession = System.currentTimeMillis() / 1000; - lc.empSCsSession = 0; - cf.writeIntConfig("fishing", "seaEmperor", lc.seaEmperors); - cf.writeDoubleConfig("fishing", "empTime", lc.empTime); - cf.writeIntConfig("fishing", "empSC", lc.empSCs); + LootCommand.seaEmperors++; + LootCommand.empTime = System.currentTimeMillis() / 1000; + LootCommand.empSCs = 0; + LootCommand.seaEmperorsSession++; + LootCommand.empTimeSession = System.currentTimeMillis() / 1000; + LootCommand.empSCsSession = 0; + ConfigHandler.writeIntConfig("fishing", "seaEmperor", LootCommand.seaEmperors); + ConfigHandler.writeDoubleConfig("fishing", "empTime", LootCommand.empTime); + ConfigHandler.writeIntConfig("fishing", "empSC", LootCommand.empSCs); } else if (message.contains("Frozen Steve fell into the pond long ago")) { // Fishing Winter - lc.frozenSteves++; - lc.frozenStevesSession++; - cf.writeIntConfig("fishing", "frozenSteve", lc.frozenSteves); + LootCommand.frozenSteves++; + LootCommand.frozenStevesSession++; + ConfigHandler.writeIntConfig("fishing", "frozenSteve", LootCommand.frozenSteves); increaseSeaCreatures(); } else if (message.contains("It's a snowman! He looks harmless")) { - lc.frostyTheSnowmans++; - lc.frostyTheSnowmansSession++; - cf.writeIntConfig("fishing", "snowman", lc.frostyTheSnowmans); + LootCommand.frostyTheSnowmans++; + LootCommand.frostyTheSnowmansSession++; + ConfigHandler.writeIntConfig("fishing", "snowman", LootCommand.frostyTheSnowmans); increaseSeaCreatures(); } else if (message.contains("stole Jerry's Gifts...get them back")) { - lc.grinches++; - lc.grinchesSession++; - cf.writeIntConfig("fishing", "grinch", lc.grinches); + LootCommand.grinches++; + LootCommand.grinchesSession++; + ConfigHandler.writeIntConfig("fishing", "grinch", LootCommand.grinches); increaseSeaCreatures(); } else if (message.contains("What is this creature")) { + LootCommand.yetis++; + LootCommand.yetiTime = System.currentTimeMillis() / 1000; + LootCommand.yetiSCs = 0; + LootCommand.yetisSession++; + LootCommand.yetiTimeSession = System.currentTimeMillis() / 1000; + LootCommand.yetiSCsSession = 0; + ConfigHandler.writeIntConfig("fishing", "yeti", LootCommand.yetis); + ConfigHandler.writeDoubleConfig("fishing", "yetiTime", LootCommand.yetiTime); + ConfigHandler.writeIntConfig("fishing", "yetiSC", LootCommand.yetiSCs); increaseSeaCreatures(); - - lc.yetis++; - lc.yetiTime = System.currentTimeMillis() / 1000; - lc.yetiSCs = 0; - lc.yetisSession++; - lc.yetiTimeSession = System.currentTimeMillis() / 1000; - lc.yetiSCsSession = 0; - cf.writeIntConfig("fishing", "yeti", lc.yetis); - cf.writeDoubleConfig("fishing", "yetiTime", lc.yetiTime); - cf.writeIntConfig("fishing", "yetiSC", lc.yetiSCs); } else if (message.contains("A tiny fin emerges from the water, you've caught a Nurse Shark")) { // Fishing Festival - lc.nurseSharks++; - lc.nurseSharksSession++; - cf.writeIntConfig("fishing", "nurseShark", lc.nurseSharks); + LootCommand.nurseSharks++; + LootCommand.nurseSharksSession++; + ConfigHandler.writeIntConfig("fishing", "nurseShark", LootCommand.nurseSharks); increaseSeaCreatures(); } else if (message.contains("You spot a fin as blue as the water it came from, it's a Blue Shark")) { - lc.blueSharks++; - lc.blueSharksSession++; - cf.writeIntConfig("fishing", "blueShark", lc.blueSharks); + LootCommand.blueSharks++; + LootCommand.blueSharksSession++; + ConfigHandler.writeIntConfig("fishing", "blueShark", LootCommand.blueSharks); increaseSeaCreatures(); } else if (message.contains("A striped beast bounds from the depths, the wild Tiger Shark")) { - lc.tigerSharks++; - lc.tigerSharksSession++; - cf.writeIntConfig("fishing", "tigerShark", lc.tigerSharks); + LootCommand.tigerSharks++; + LootCommand.tigerSharksSession++; + ConfigHandler.writeIntConfig("fishing", "tigerShark", LootCommand.tigerSharks); increaseSeaCreatures(); } else if (message.contains("Hide no longer, a Great White Shark has tracked your scent and thirsts for your blood")) { - lc.greatWhiteSharks++; - lc.greatWhiteSharksSession++; - cf.writeIntConfig("fishing", "greatWhiteShark", lc.greatWhiteSharks); + LootCommand.greatWhiteSharks++; + LootCommand.greatWhiteSharksSession++; + ConfigHandler.writeIntConfig("fishing", "greatWhiteShark", LootCommand.greatWhiteSharks); increaseSeaCreatures(); } else if (message.contains("Phew! It's only a Scarecrow")) { - lc.scarecrows++; - lc.scarecrowsSession++; - cf.writeIntConfig("fishing", "scarecrow", lc.scarecrows); + LootCommand.scarecrows++; + LootCommand.scarecrowsSession++; + ConfigHandler.writeIntConfig("fishing", "scarecrow", LootCommand.scarecrows); increaseSeaCreatures(); } else if (message.contains("You hear trotting from beneath the waves, you caught a Nightmare")) { - lc.nightmares++; - lc.nightmaresSession++; - cf.writeIntConfig("fishing", "nightmare", lc.nightmares); + LootCommand.nightmares++; + LootCommand.nightmaresSession++; + ConfigHandler.writeIntConfig("fishing", "nightmare", LootCommand.nightmares); increaseSeaCreatures(); } else if (message.contains("It must be a full moon, a Werewolf appears")) { - lc.werewolfs++; - lc.werewolfsSession++; - cf.writeIntConfig("fishing", "werewolf", lc.werewolfs); + LootCommand.werewolfs++; + LootCommand.werewolfsSession++; + ConfigHandler.writeIntConfig("fishing", "werewolf", LootCommand.werewolfs); increaseSeaCreatures(); } else if (message.contains("The spirit of a long lost Phantom Fisher has come to haunt you")) { - lc.phantomFishers++; - lc.phantomFishersSession++; - cf.writeIntConfig("fishing", "phantomFisher", lc.phantomFishers); + LootCommand.phantomFishers++; + LootCommand.phantomFishersSession++; + ConfigHandler.writeIntConfig("fishing", "phantomFisher", LootCommand.phantomFishers); increaseSeaCreatures(); } else if (message.contains("This can't be! The manifestation of death himself")) { - lc.grimReapers++; - lc.grimReapersSession++; - cf.writeIntConfig("fishing", "grimReaper", lc.grimReapers); + LootCommand.grimReapers++; + LootCommand.grimReapersSession++; + ConfigHandler.writeIntConfig("fishing", "grimReaper", LootCommand.grimReapers); increaseSeaCreatures(); } else if (message.contains("Dungeon starts in 1 second.")) { // Dungeons Stuff dungeonStartTime = System.currentTimeMillis() / 1000 + 1; @@ -799,29 +791,29 @@ public class TheMod if (sCleaned.contains("The Catacombs (")) { // Add time to floor if (sCleaned.contains("F1")) { - lc.f1TimeSpent = Math.floor(lc.f1TimeSpent + timeToAdd); - lc.f1TimeSpentSession = Math.floor(lc.f1TimeSpentSession + timeToAdd); - cf.writeDoubleConfig("catacombs", "floorOneTime", lc.f1TimeSpent); + LootCommand.f1TimeSpent = Math.floor(LootCommand.f1TimeSpent + timeToAdd); + LootCommand.f1TimeSpentSession = Math.floor(LootCommand.f1TimeSpentSession + timeToAdd); + ConfigHandler.writeDoubleConfig("catacombs", "floorOneTime", LootCommand.f1TimeSpent); } else if (sCleaned.contains("F2")) { - lc.f2TimeSpent = Math.floor(lc.f2TimeSpent + timeToAdd); - lc.f2TimeSpentSession = Math.floor(lc.f2TimeSpentSession + timeToAdd); - cf.writeDoubleConfig("catacombs", "floorTwoTime", lc.f2TimeSpent); + LootCommand.f2TimeSpent = Math.floor(LootCommand.f2TimeSpent + timeToAdd); + LootCommand.f2TimeSpentSession = Math.floor(LootCommand.f2TimeSpentSession + timeToAdd); + ConfigHandler.writeDoubleConfig("catacombs", "floorTwoTime", LootCommand.f2TimeSpent); } else if (sCleaned.contains("F3")) { - lc.f3TimeSpent = Math.floor(lc.f3TimeSpent + timeToAdd); - lc.f3TimeSpentSession = Math.floor(lc.f3TimeSpentSession + timeToAdd); - cf.writeDoubleConfig("catacombs", "floorThreeTime", lc.f3TimeSpent); + LootCommand.f3TimeSpent = Math.floor(LootCommand.f3TimeSpent + timeToAdd); + LootCommand.f3TimeSpentSession = Math.floor(LootCommand.f3TimeSpentSession + timeToAdd); + ConfigHandler.writeDoubleConfig("catacombs", "floorThreeTime", LootCommand.f3TimeSpent); } else if (sCleaned.contains("F4")) { - lc.f4TimeSpent = Math.floor(lc.f4TimeSpent + timeToAdd); - lc.f4TimeSpentSession = Math.floor(lc.f4TimeSpentSession + timeToAdd); - cf.writeDoubleConfig("catacombs", "floorFourTime", lc.f4TimeSpent); + LootCommand.f4TimeSpent = Math.floor(LootCommand.f4TimeSpent + timeToAdd); + LootCommand.f4TimeSpentSession = Math.floor(LootCommand.f4TimeSpentSession + timeToAdd); + ConfigHandler.writeDoubleConfig("catacombs", "floorFourTime", LootCommand.f4TimeSpent); } else if (sCleaned.contains("F5")) { - lc.f5TimeSpent = Math.floor(lc.f5TimeSpent + timeToAdd); - lc.f5TimeSpentSession = Math.floor(lc.f5TimeSpentSession + timeToAdd); - cf.writeDoubleConfig("catacombs", "floorFiveTime", lc.f5TimeSpent); + LootCommand.f5TimeSpent = Math.floor(LootCommand.f5TimeSpent + timeToAdd); + LootCommand.f5TimeSpentSession = Math.floor(LootCommand.f5TimeSpentSession + timeToAdd); + ConfigHandler.writeDoubleConfig("catacombs", "floorFiveTime", LootCommand.f5TimeSpent); } else if (sCleaned.contains("F6")) { - lc.f6TimeSpent = Math.floor(lc.f6TimeSpent + timeToAdd); - lc.f6TimeSpentSession = Math.floor(lc.f6TimeSpentSession + timeToAdd); - cf.writeDoubleConfig("catacombs", "floorSixTime", lc.f6TimeSpent); + LootCommand.f6TimeSpent = Math.floor(LootCommand.f6TimeSpent + timeToAdd); + LootCommand.f6TimeSpentSession = Math.floor(LootCommand.f6TimeSpentSession + timeToAdd); + ConfigHandler.writeDoubleConfig("catacombs", "floorSixTime", LootCommand.f6TimeSpent); } } else if (sCleaned.contains("Time Elapsed:")) { // Get floor time @@ -835,160 +827,160 @@ public class TheMod } if (wolfRNG) { - lc.wolfTime = System.currentTimeMillis() / 1000; - lc.wolfBosses = 0; - lc.wolfTimeSession = System.currentTimeMillis() / 1000; - lc.wolfBossesSession = 0; - cf.writeDoubleConfig("wolf", "timeRNG", lc.wolfTime); - cf.writeIntConfig("wolf", "bossRNG", 0); + LootCommand.wolfTime = System.currentTimeMillis() / 1000; + LootCommand.wolfBosses = 0; + LootCommand.wolfTimeSession = System.currentTimeMillis() / 1000; + LootCommand.wolfBossesSession = 0; + ConfigHandler.writeDoubleConfig("wolf", "timeRNG", LootCommand.wolfTime); + ConfigHandler.writeIntConfig("wolf", "bossRNG", 0); } if (spiderRNG) { - lc.spiderTime = System.currentTimeMillis() / 1000; - lc.spiderBosses = 0; - lc.spiderTimeSession = System.currentTimeMillis() / 1000; - lc.spiderBossesSession = 0; - cf.writeDoubleConfig("spider", "timeRNG", lc.spiderTime); - cf.writeIntConfig("spider", "bossRNG", 0); + LootCommand.spiderTime = System.currentTimeMillis() / 1000; + LootCommand.spiderBosses = 0; + LootCommand.spiderTimeSession = System.currentTimeMillis() / 1000; + LootCommand.spiderBossesSession = 0; + ConfigHandler.writeDoubleConfig("spider", "timeRNG", LootCommand.spiderTime); + ConfigHandler.writeIntConfig("spider", "bossRNG", 0); } if (zombieRNG) { - lc.zombieTime = System.currentTimeMillis() / 1000; - lc.zombieBosses = 0; - lc.zombieTimeSession = System.currentTimeMillis() / 1000; - lc.zombieBossesSession = 0; - cf.writeDoubleConfig("zombie", "timeRNG", lc.zombieTime); - cf.writeIntConfig("zombie", "bossRNG", 0); + LootCommand.zombieTime = System.currentTimeMillis() / 1000; + LootCommand.zombieBosses = 0; + LootCommand.zombieTimeSession = System.currentTimeMillis() / 1000; + LootCommand.zombieBossesSession = 0; + ConfigHandler.writeDoubleConfig("zombie", "timeRNG", LootCommand.zombieTime); + ConfigHandler.writeIntConfig("zombie", "bossRNG", 0); } // Dungeons Trackers if (message.contains(" ")) { if (message.contains("Recombobulator 3000")) { - lc.recombobulators++; - lc.recombobulatorsSession++; - cf.writeIntConfig("catacombs", "recombobulator", lc.recombobulators); + LootCommand.recombobulators++; + LootCommand.recombobulatorsSession++; + ConfigHandler.writeIntConfig("catacombs", "recombobulator", LootCommand.recombobulators); } else if (message.contains("Fuming Potato Book")) { - lc.fumingPotatoBooks++; - lc.fumingPotatoBooksSession++; - cf.writeIntConfig("catacombs", "fumingBooks", lc.fumingPotatoBooks); + LootCommand.fumingPotatoBooks++; + LootCommand.fumingPotatoBooksSession++; + ConfigHandler.writeIntConfig("catacombs", "fumingBooks", LootCommand.fumingPotatoBooks); } else if (message.contains("Bonzo's Staff")) { // F1 - lc.bonzoStaffs++; - lc.bonzoStaffsSession++; - cf.writeIntConfig("catacombs", "bonzoStaff", lc.bonzoStaffs); + LootCommand.bonzoStaffs++; + LootCommand.bonzoStaffsSession++; + ConfigHandler.writeIntConfig("catacombs", "bonzoStaff", LootCommand.bonzoStaffs); } else if (message.contains("Scarf's Studies")) { // F2 - lc.scarfStudies++; - lc.scarfStudiesSession++; - cf.writeIntConfig("catacombs", "scarfStudies", lc.scarfStudies); + LootCommand.scarfStudies++; + LootCommand.scarfStudiesSession++; + ConfigHandler.writeIntConfig("catacombs", "scarfStudies", LootCommand.scarfStudies); } else if (message.contains("Adaptive Helmet")) { // F3 - lc.adaptiveHelms++; - lc.adaptiveHelmsSession++; - cf.writeIntConfig("catacombs", "adaptiveHelm", lc.adaptiveHelms); + LootCommand.adaptiveHelms++; + LootCommand.adaptiveHelmsSession++; + ConfigHandler.writeIntConfig("catacombs", "adaptiveHelm", LootCommand.adaptiveHelms); } else if (message.contains("Adaptive Chestplate")) { - lc.adaptiveChests++; - lc.adaptiveChestsSession++; - cf.writeIntConfig("catacombs", "adaptiveChest", lc.adaptiveChests); + LootCommand.adaptiveChests++; + LootCommand.adaptiveChestsSession++; + ConfigHandler.writeIntConfig("catacombs", "adaptiveChest", LootCommand.adaptiveChests); } else if (message.contains("Adaptive Leggings")) { - lc.adaptiveLegs++; - lc.adaptiveLegsSession++; - cf.writeIntConfig("catacombs", "adaptiveLegging", lc.adaptiveLegs); + LootCommand.adaptiveLegs++; + LootCommand.adaptiveLegsSession++; + ConfigHandler.writeIntConfig("catacombs", "adaptiveLegging", LootCommand.adaptiveLegs); } else if (message.contains("Adaptive Boots")) { - lc.adaptiveBoots++; - lc.adaptiveBootsSession++; - cf.writeIntConfig("catacombs", "adaptiveBoot", lc.adaptiveBoots); + LootCommand.adaptiveBoots++; + LootCommand.adaptiveBootsSession++; + ConfigHandler.writeIntConfig("catacombs", "adaptiveBoot", LootCommand.adaptiveBoots); } else if (message.contains("Adaptive Blade")) { - lc.adaptiveSwords++; - lc.adaptiveSwordsSession++; - cf.writeIntConfig("catacombs", "adaptiveSword", lc.adaptiveSwords); + LootCommand.adaptiveSwords++; + LootCommand.adaptiveSwordsSession++; + ConfigHandler.writeIntConfig("catacombs", "adaptiveSword", LootCommand.adaptiveSwords); } else if (message.contains("Spirit Wing")) { // F4 - lc.spiritWings++; - lc.spiritWingsSession++; - cf.writeIntConfig("catacombs", "spiritWing", lc.spiritWings); + LootCommand.spiritWings++; + LootCommand.spiritWingsSession++; + ConfigHandler.writeIntConfig("catacombs", "spiritWing", LootCommand.spiritWings); } else if (message.contains("Spirit Bone")) { - lc.spiritBones++; - lc.spiritBonesSession++; - cf.writeIntConfig("catacombs", "spiritBone", lc.spiritBones); + LootCommand.spiritBones++; + LootCommand.spiritBonesSession++; + ConfigHandler.writeIntConfig("catacombs", "spiritBone", LootCommand.spiritBones); } else if (message.contains("Spirit Boots")) { - lc.spiritBoots++; - lc.spiritBootsSession++; - cf.writeIntConfig("catacombs", "spiritBoot", lc.spiritBoots); + LootCommand.spiritBoots++; + LootCommand.spiritBootsSession++; + ConfigHandler.writeIntConfig("catacombs", "spiritBoot", LootCommand.spiritBoots); } else if (message.contains("[Lvl 1] Spirit")) { String formattedMessage = event.message.getFormattedText(); // Unicode colour code messes up here, just gonna remove the symbols if (formattedMessage.contains("5Spirit")) { - lc.epicSpiritPets++; - lc.epicSpiritPetsSession++; - cf.writeIntConfig("catacombs", "spiritPetEpic", lc.epicSpiritPets); + LootCommand.epicSpiritPets++; + LootCommand.epicSpiritPetsSession++; + ConfigHandler.writeIntConfig("catacombs", "spiritPetEpic", LootCommand.epicSpiritPets); } else if (formattedMessage.contains("6Spirit")) { - lc.legSpiritPets++; - lc.legSpiritPetsSession++; - cf.writeIntConfig("catacombs", "spiritPetLeg", lc.legSpiritPets); + LootCommand.legSpiritPets++; + LootCommand.legSpiritPetsSession++; + ConfigHandler.writeIntConfig("catacombs", "spiritPetLeg", LootCommand.legSpiritPets); } } else if (message.contains("Spirit Sword")) { - lc.spiritSwords++; - lc.spiritSwordsSession++; - cf.writeIntConfig("catacombs", "spiritSword", lc.spiritSwords); + LootCommand.spiritSwords++; + LootCommand.spiritSwordsSession++; + ConfigHandler.writeIntConfig("catacombs", "spiritSword", LootCommand.spiritSwords); } else if (message.contains("Spirit Bow")) { - lc.spiritBows++; - lc.spiritBowsSession++; - cf.writeIntConfig("catacombs", "spiritBow", lc.spiritBows); + LootCommand.spiritBows++; + LootCommand.spiritBowsSession++; + ConfigHandler.writeIntConfig("catacombs", "spiritBow", LootCommand.spiritBows); } else if (message.contains("Warped Stone")) { // F5 - lc.warpedStones++; - lc.warpedStonesSession++; - cf.writeIntConfig("catacombs", "warpedStone", lc.warpedStones); + LootCommand.warpedStones++; + LootCommand.warpedStonesSession++; + ConfigHandler.writeIntConfig("catacombs", "warpedStone", LootCommand.warpedStones); } else if (message.contains("Shadow Assassin Helmet")) { - lc.shadowAssHelms++; - lc.shadowAssHelmsSession++; - cf.writeIntConfig("catacombs", "shadowAssassinHelm", lc.shadowAssHelms); + LootCommand.shadowAssHelms++; + LootCommand.shadowAssHelmsSession++; + ConfigHandler.writeIntConfig("catacombs", "shadowAssassinHelm", LootCommand.shadowAssHelms); } else if (message.contains("Shadow Assassin Chestplate")) { - lc.shadowAssChests++; - lc.shadowAssChestsSession++; - cf.writeIntConfig("catacombs", "shadowAssassinChest", lc.shadowAssChests); + LootCommand.shadowAssChests++; + LootCommand.shadowAssChestsSession++; + ConfigHandler.writeIntConfig("catacombs", "shadowAssassinChest", LootCommand.shadowAssChests); } else if (message.contains("Shadow Assassin Leggings")) { - lc.shadowAssLegs++; - lc.shadowAssLegsSession++; - cf.writeIntConfig("catacombs", "shadowAssassinLegging", lc.shadowAssLegs); + LootCommand.shadowAssLegs++; + LootCommand.shadowAssLegsSession++; + ConfigHandler.writeIntConfig("catacombs", "shadowAssassinLegging", LootCommand.shadowAssLegs); } else if (message.contains("Shadow Assassin Boots")) { - lc.shadowAssBoots++; - lc.shadowAssBootsSession++; - cf.writeIntConfig("catacombs", "shadowAssassinBoot", lc.shadowAssBoots); + LootCommand.shadowAssBoots++; + LootCommand.shadowAssBootsSession++; + ConfigHandler.writeIntConfig("catacombs", "shadowAssassinBoot", LootCommand.shadowAssBoots); } else if (message.contains("Livid Dagger")) { - lc.lividDaggers++; - lc.lividDaggersSession++; - cf.writeIntConfig("catacombs", "lividDagger", lc.lividDaggers); + LootCommand.lividDaggers++; + LootCommand.lividDaggersSession++; + ConfigHandler.writeIntConfig("catacombs", "lividDagger", LootCommand.lividDaggers); } else if (message.contains("Shadow Fury")) { - lc.shadowFurys++; - lc.shadowFurysSession++; - cf.writeIntConfig("catacombs", "shadowFury", lc.shadowFurys); + LootCommand.shadowFurys++; + LootCommand.shadowFurysSession++; + ConfigHandler.writeIntConfig("catacombs", "shadowFury", LootCommand.shadowFurys); } else if (message.contains("Ancient Rose")) { // F6 - lc.ancientRoses++; - lc.ancientRosesSession++; - cf.writeIntConfig("catacombs", "ancientRose", lc.ancientRoses); + LootCommand.ancientRoses++; + LootCommand.ancientRosesSession++; + ConfigHandler.writeIntConfig("catacombs", "ancientRose", LootCommand.ancientRoses); } else if (message.contains("Precursor Eye")) { - lc.precursorEyes++; - lc.precursorEyesSession++; - cf.writeIntConfig("catacombs", "precursorEye", lc.precursorEyes); + LootCommand.precursorEyes++; + LootCommand.precursorEyesSession++; + ConfigHandler.writeIntConfig("catacombs", "precursorEye", LootCommand.precursorEyes); } else if (message.contains("Giant's Sword")) { - lc.giantsSwords++; - lc.giantsSwordsSession++; - cf.writeIntConfig("catacombs", "giantsSword", lc.giantsSwords); + LootCommand.giantsSwords++; + LootCommand.giantsSwordsSession++; + ConfigHandler.writeIntConfig("catacombs", "giantsSword", LootCommand.giantsSwords); } else if (message.contains("Necromancer Lord Helmet")) { - lc.necroLordHelms++; - lc.necroLordHelmsSession++; - cf.writeIntConfig("catacombs", "necroLordHelm", lc.necroLordHelms); + LootCommand.necroLordHelms++; + LootCommand.necroLordHelmsSession++; + ConfigHandler.writeIntConfig("catacombs", "necroLordHelm", LootCommand.necroLordHelms); } else if (message.contains("Necromancer Lord Chestplate")) { - lc.necroLordChests++; - lc.necroLordChestsSession++; - cf.writeIntConfig("catacombs", "necroLordChest", lc.necroLordChests); + LootCommand.necroLordChests++; + LootCommand.necroLordChestsSession++; + ConfigHandler.writeIntConfig("catacombs", "necroLordChest", LootCommand.necroLordChests); } else if (message.contains("Necromancer Lord Leggings")) { - lc.necroLordLegs++; - lc.necroLordLegsSession++; - cf.writeIntConfig("catacombs", "necroLordLegging", lc.necroLordLegs); + LootCommand.necroLordLegs++; + LootCommand.necroLordLegsSession++; + ConfigHandler.writeIntConfig("catacombs", "necroLordLegging", LootCommand.necroLordLegs); } else if (message.contains("Necromancer Lord Boots")) { - lc.necroLordBoots++; - lc.necroLordBootsSession++; - cf.writeIntConfig("catacombs", "necroLordBoot", lc.necroLordBoots); + LootCommand.necroLordBoots++; + LootCommand.necroLordBootsSession++; + ConfigHandler.writeIntConfig("catacombs", "necroLordBoot", LootCommand.necroLordBoots); } else if (message.contains("Necromancer Sword")) { - lc.necroSwords++; - lc.necroSwordsSession++; - cf.writeIntConfig("catacombs", "necroSword", lc.necroSwords); + LootCommand.necroSwords++; + LootCommand.necroSwordsSession++; + ConfigHandler.writeIntConfig("catacombs", "necroSword", LootCommand.necroSwords); } } @@ -1001,11 +993,11 @@ public class TheMod lastMaddoxTime = System.currentTimeMillis() / 1000; } } - if (tc.chatMaddoxToggled) Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText(MAIN_COLOUR + "Open chat then click anywhere on-screen to open Maddox")); + if (ToggleCommand.chatMaddoxToggled) Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText(MAIN_COLOUR + "Open chat then click anywhere on-screen to open Maddox")); } // Spirit Bear alerts - if (tc.spiritBearAlerts && message.contains("The Spirit Bear has appeared!")) { + if (ToggleCommand.spiritBearAlerts && message.contains("The Spirit Bear has appeared!")) { Utils.createTitle(EnumChatFormatting.DARK_PURPLE + "SPIRIT BEAR", 2); } } @@ -1026,15 +1018,11 @@ public class TheMod } public void renderEverything() { - final ToggleCommand tc = new ToggleCommand(); - final MoveCommand moc = new MoveCommand(); - final DisplayCommand ds = new DisplayCommand(); - if (Minecraft.getMinecraft().currentScreen instanceof EditLocationsGui) return; Minecraft mc = Minecraft.getMinecraft(); - if (tc.coordsToggled) { + if (ToggleCommand.coordsToggled) { EntityPlayer player = mc.thePlayer; double xDir = (player.rotationYaw % 360 + 360) % 360; @@ -1043,10 +1031,10 @@ public class TheMod double yDir = (double) Math.round(player.rotationPitch * 10d) / 10d; String coordText = COORDS_COLOUR + (int) player.posX + " / " + (int) player.posY + " / " + (int) player.posZ + " (" + xDir + " / " + yDir + ")"; - new TextRenderer(mc, coordText, moc.coordsXY[0], moc.coordsXY[1], ScaleCommand.coordsScale); + new TextRenderer(mc, coordText, MoveCommand.coordsXY[0], MoveCommand.coordsXY[1], ScaleCommand.coordsScale); } - if (tc.dungeonTimerToggled && Utils.inDungeons) { + if (ToggleCommand.dungeonTimerToggled && Utils.inDungeons) { String dungeonTimerText = EnumChatFormatting.GRAY + "Wither Doors:\n" + EnumChatFormatting.DARK_RED + "Blood Open:\n" + EnumChatFormatting.RED + "Watcher Clear:\n" + @@ -1059,22 +1047,22 @@ public class TheMod EnumChatFormatting.BLUE + Utils.getTimeBetween(dungeonStartTime, bossClearTime) + "\n" + EnumChatFormatting.YELLOW + dungeonDeaths + "\n" + EnumChatFormatting.YELLOW + puzzleFails; - new TextRenderer(mc, dungeonTimerText, moc.dungeonTimerXY[0], moc.dungeonTimerXY[1], ScaleCommand.dungeonTimerScale); - new TextRenderer(mc, dungeonTimers, (int) (moc.dungeonTimerXY[0] + (80 * ScaleCommand.dungeonTimerScale)), moc.dungeonTimerXY[1], ScaleCommand.dungeonTimerScale); + new TextRenderer(mc, dungeonTimerText, MoveCommand.dungeonTimerXY[0], MoveCommand.dungeonTimerXY[1], ScaleCommand.dungeonTimerScale); + new TextRenderer(mc, dungeonTimers, (int) (MoveCommand.dungeonTimerXY[0] + (80 * ScaleCommand.dungeonTimerScale)), MoveCommand.dungeonTimerXY[1], ScaleCommand.dungeonTimerScale); } - if (tc.lividSolverToggled && foundLivid && livid != null) { - new TextRenderer(mc, livid.getName().replace("" + EnumChatFormatting.BOLD, ""), moc.lividHpXY[0], moc.lividHpXY[1], ScaleCommand.lividHpScale); + if (ToggleCommand.lividSolverToggled && foundLivid && livid != null) { + new TextRenderer(mc, livid.getName().replace("" + EnumChatFormatting.BOLD, ""), MoveCommand.lividHpXY[0], MoveCommand.lividHpXY[1], ScaleCommand.lividHpScale); } - if (tc.cakeTimerToggled && Utils.inSkyblock) { + if (ToggleCommand.cakeTimerToggled && Utils.inSkyblock) { double scale = ScaleCommand.cakeTimerScale; double scaleReset = (double) Math.pow(scale, -1); GL11.glScaled(scale, scale, scale); double timeNow = System.currentTimeMillis() / 1000; mc.getTextureManager().bindTexture(CAKE_ICON); - Gui.drawModalRectWithCustomSizedTexture(moc.cakeTimerXY[0], moc.cakeTimerXY[1], 0, 0, 16, 16, 16, 16); + Gui.drawModalRectWithCustomSizedTexture(MoveCommand.cakeTimerXY[0], MoveCommand.cakeTimerXY[1], 0, 0, 16, 16, 16, 16); String cakeText; if (cakeTime - timeNow < 0) { @@ -1082,13 +1070,12 @@ public class TheMod } else { cakeText = CAKE_COLOUR + Utils.getTimeBetween(timeNow, cakeTime); } - new TextRenderer(mc, cakeText, moc.cakeTimerXY[0] + 20, moc.cakeTimerXY[1] + 5, 1); + new TextRenderer(mc, cakeText, MoveCommand.cakeTimerXY[0] + 20, MoveCommand.cakeTimerXY[1] + 5, 1); GL11.glScaled(scaleReset, scaleReset, scaleReset); } - if (!ds.display.equals("off")) { - final LootCommand lc = new LootCommand(); + if (!DisplayCommand.display.equals("off")) { String dropsText = ""; String countText = ""; String timeBetween = "Never"; @@ -1097,21 +1084,21 @@ public class TheMod double timeNow = System.currentTimeMillis() / 1000; NumberFormat nf = NumberFormat.getIntegerInstance(Locale.US); - if (ds.display.equals("wolf")) { - if (lc.wolfTime == -1) { + if (DisplayCommand.display.equals("wolf")) { + if (LootCommand.wolfTime == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(lc.wolfTime, timeNow); + timeBetween = Utils.getTimeBetween(LootCommand.wolfTime, timeNow); } - if (lc.wolfBosses == -1) { + if (LootCommand.wolfBosses == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(lc.wolfBosses); + bossesBetween = nf.format(LootCommand.wolfBosses); } - if (tc.slayerCountTotal) { - drop20 = nf.format(lc.wolfWheels); + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(LootCommand.wolfWheels); } else { - drop20 = nf.format(lc.wolfWheelsDrops) + " times"; + drop20 = nf.format(LootCommand.wolfWheelsDrops) + " times"; } dropsText = EnumChatFormatting.GOLD + "Svens Killed:\n" + @@ -1125,32 +1112,32 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + "Overfluxes:\n" + EnumChatFormatting.AQUA + "Time Since RNG:\n" + EnumChatFormatting.AQUA + "Bosses Since RNG:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.wolfSvens) + "\n" + - EnumChatFormatting.GREEN + nf.format(lc.wolfTeeth) + "\n" + + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.wolfSvens) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.wolfTeeth) + "\n" + EnumChatFormatting.BLUE + drop20 + "\n" + - EnumChatFormatting.AQUA + lc.wolfSpirits + "\n" + - EnumChatFormatting.WHITE + lc.wolfBooks + "\n" + - EnumChatFormatting.DARK_RED + lc.wolfEggs + "\n" + - EnumChatFormatting.GOLD + lc.wolfCoutures + "\n" + - EnumChatFormatting.AQUA + lc.wolfBaits + "\n" + - EnumChatFormatting.DARK_PURPLE + lc.wolfFluxes + "\n" + + EnumChatFormatting.AQUA + LootCommand.wolfSpirits + "\n" + + EnumChatFormatting.WHITE + LootCommand.wolfBooks + "\n" + + EnumChatFormatting.DARK_RED + LootCommand.wolfEggs + "\n" + + EnumChatFormatting.GOLD + LootCommand.wolfCoutures + "\n" + + EnumChatFormatting.AQUA + LootCommand.wolfBaits + "\n" + + EnumChatFormatting.DARK_PURPLE + LootCommand.wolfFluxes + "\n" + EnumChatFormatting.AQUA + timeBetween + "\n" + EnumChatFormatting.AQUA + bossesBetween; - } else if (ds.display.equals("wolf_session")) { - if (lc.wolfTimeSession == -1) { + } else if (DisplayCommand.display.equals("wolf_session")) { + if (LootCommand.wolfTimeSession == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(lc.wolfTimeSession, timeNow); + timeBetween = Utils.getTimeBetween(LootCommand.wolfTimeSession, timeNow); } - if (lc.wolfBossesSession == -1) { + if (LootCommand.wolfBossesSession == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(lc.wolfBossesSession); + bossesBetween = nf.format(LootCommand.wolfBossesSession); } - if (tc.slayerCountTotal) { - drop20 = nf.format(lc.wolfWheelsSession); + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(LootCommand.wolfWheelsSession); } else { - drop20 = nf.format(lc.wolfWheelsDropsSession) + " times"; + drop20 = nf.format(LootCommand.wolfWheelsDropsSession) + " times"; } dropsText = EnumChatFormatting.GOLD + "Svens Killed:\n" + @@ -1164,32 +1151,32 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + "Overfluxes:\n" + EnumChatFormatting.AQUA + "Time Since RNG:\n" + EnumChatFormatting.AQUA + "Bosses Since RNG:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.wolfSvensSession) + "\n" + - EnumChatFormatting.GREEN + nf.format(lc.wolfTeethSession) + "\n" + + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.wolfSvensSession) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.wolfTeethSession) + "\n" + EnumChatFormatting.BLUE + drop20 + "\n" + - EnumChatFormatting.AQUA + lc.wolfSpiritsSession + "\n" + - EnumChatFormatting.WHITE + lc.wolfBooksSession + "\n" + - EnumChatFormatting.DARK_RED + lc.wolfEggsSession + "\n" + - EnumChatFormatting.GOLD + lc.wolfCouturesSession + "\n" + - EnumChatFormatting.AQUA + lc.wolfBaitsSession + "\n" + - EnumChatFormatting.DARK_PURPLE + lc.wolfFluxesSession + "\n" + + EnumChatFormatting.AQUA + LootCommand.wolfSpiritsSession + "\n" + + EnumChatFormatting.WHITE + LootCommand.wolfBooksSession + "\n" + + EnumChatFormatting.DARK_RED + LootCommand.wolfEggsSession + "\n" + + EnumChatFormatting.GOLD + LootCommand.wolfCouturesSession + "\n" + + EnumChatFormatting.AQUA + LootCommand.wolfBaitsSession + "\n" + + EnumChatFormatting.DARK_PURPLE + LootCommand.wolfFluxesSession + "\n" + EnumChatFormatting.AQUA + timeBetween + "\n" + EnumChatFormatting.AQUA + bossesBetween; - } else if (ds.display.equals("spider")) { - if (lc.spiderTime == -1) { + } else if (DisplayCommand.display.equals("spider")) { + if (LootCommand.spiderTime == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(lc.spiderTime, timeNow); + timeBetween = Utils.getTimeBetween(LootCommand.spiderTime, timeNow); } - if (lc.spiderBosses == -1) { + if (LootCommand.spiderBosses == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(lc.spiderBosses); + bossesBetween = nf.format(LootCommand.spiderBosses); } - if (tc.slayerCountTotal) { - drop20 = nf.format(lc.spiderTAP); + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(LootCommand.spiderTAP); } else { - drop20 = nf.format(lc.spiderTAPDrops) + " times"; + drop20 = nf.format(LootCommand.spiderTAPDrops) + " times"; } dropsText = EnumChatFormatting.GOLD + "Tarantulas Killed:\n" + @@ -1203,32 +1190,32 @@ public class TheMod EnumChatFormatting.GOLD + "Digested Mosquitos:\n" + EnumChatFormatting.AQUA + "Time Since RNG:\n" + EnumChatFormatting.AQUA + "Bosses Since RNG:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.spiderTarantulas) + "\n" + - EnumChatFormatting.GREEN + nf.format(lc.spiderWebs) + "\n" + + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.spiderTarantulas) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.spiderWebs) + "\n" + EnumChatFormatting.DARK_GREEN + drop20 + "\n" + - EnumChatFormatting.DARK_GRAY + lc.spiderBites + "\n" + - EnumChatFormatting.WHITE + lc.spiderBooks + "\n" + - EnumChatFormatting.AQUA + lc.spiderCatalysts + "\n" + - EnumChatFormatting.DARK_PURPLE + lc.spiderTalismans + "\n" + - EnumChatFormatting.LIGHT_PURPLE + lc.spiderSwatters + "\n" + - EnumChatFormatting.GOLD + lc.spiderMosquitos + "\n" + + EnumChatFormatting.DARK_GRAY + LootCommand.spiderBites + "\n" + + EnumChatFormatting.WHITE + LootCommand.spiderBooks + "\n" + + EnumChatFormatting.AQUA + LootCommand.spiderCatalysts + "\n" + + EnumChatFormatting.DARK_PURPLE + LootCommand.spiderTalismans + "\n" + + EnumChatFormatting.LIGHT_PURPLE + LootCommand.spiderSwatters + "\n" + + EnumChatFormatting.GOLD + LootCommand.spiderMosquitos + "\n" + EnumChatFormatting.AQUA + timeBetween + "\n" + EnumChatFormatting.AQUA + bossesBetween; - } else if (ds.display.equals("spider_session")) { - if (lc.spiderTimeSession == -1) { + } else if (DisplayCommand.display.equals("spider_session")) { + if (LootCommand.spiderTimeSession == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(lc.spiderTimeSession, timeNow); + timeBetween = Utils.getTimeBetween(LootCommand.spiderTimeSession, timeNow); } - if (lc.spiderBossesSession == -1) { + if (LootCommand.spiderBossesSession == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(lc.spiderBossesSession); + bossesBetween = nf.format(LootCommand.spiderBossesSession); } - if (tc.slayerCountTotal) { - drop20 = nf.format(lc.spiderTAPSession); + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(LootCommand.spiderTAPSession); } else { - drop20 = nf.format(lc.spiderTAPDropsSession) + " times"; + drop20 = nf.format(LootCommand.spiderTAPDropsSession) + " times"; } dropsText = EnumChatFormatting.GOLD + "Tarantulas Killed:\n" + @@ -1242,32 +1229,32 @@ public class TheMod EnumChatFormatting.GOLD + "Digested Mosquitos:\n" + EnumChatFormatting.AQUA + "Time Since RNG:\n" + EnumChatFormatting.AQUA + "Bosses Since RNG:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.spiderTarantulasSession) + "\n" + - EnumChatFormatting.GREEN + nf.format(lc.spiderWebsSession) + "\n" + + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.spiderTarantulasSession) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.spiderWebsSession) + "\n" + EnumChatFormatting.DARK_GREEN + drop20 + "\n" + - EnumChatFormatting.DARK_GRAY + lc.spiderBitesSession + "\n" + - EnumChatFormatting.WHITE + lc.spiderBooksSession + "\n" + - EnumChatFormatting.AQUA + lc.spiderCatalystsSession + "\n" + - EnumChatFormatting.DARK_PURPLE + lc.spiderTalismansSession + "\n" + - EnumChatFormatting.LIGHT_PURPLE + lc.spiderSwattersSession + "\n" + - EnumChatFormatting.GOLD + lc.spiderMosquitosSession + "\n" + + EnumChatFormatting.DARK_GRAY + LootCommand.spiderBitesSession + "\n" + + EnumChatFormatting.WHITE + LootCommand.spiderBooksSession + "\n" + + EnumChatFormatting.AQUA + LootCommand.spiderCatalystsSession + "\n" + + EnumChatFormatting.DARK_PURPLE + LootCommand.spiderTalismansSession + "\n" + + EnumChatFormatting.LIGHT_PURPLE + LootCommand.spiderSwattersSession + "\n" + + EnumChatFormatting.GOLD + LootCommand.spiderMosquitosSession + "\n" + EnumChatFormatting.AQUA + timeBetween + "\n" + EnumChatFormatting.AQUA + bossesBetween; - } else if (ds.display.equals("zombie")) { - if (lc.zombieTime == -1) { + } else if (DisplayCommand.display.equals("zombie")) { + if (LootCommand.zombieTime == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(lc.zombieTime, timeNow); + timeBetween = Utils.getTimeBetween(LootCommand.zombieTime, timeNow); } - if (lc.zombieBosses == -1) { + if (LootCommand.zombieBosses == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(lc.zombieBosses); + bossesBetween = nf.format(LootCommand.zombieBosses); } - if (tc.slayerCountTotal) { - drop20 = nf.format(lc.zombieFoulFlesh); + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(LootCommand.zombieFoulFlesh); } else { - drop20 = nf.format(lc.zombieFoulFleshDrops) + " times"; + drop20 = nf.format(LootCommand.zombieFoulFleshDrops) + " times"; } dropsText = EnumChatFormatting.GOLD + "Revs Killed:\n" + @@ -1282,33 +1269,33 @@ public class TheMod EnumChatFormatting.GOLD + "Scythe Blades:\n" + EnumChatFormatting.AQUA + "Time Since RNG:\n" + EnumChatFormatting.AQUA + "Bosses Since RNG:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.zombieRevs) + "\n" + - EnumChatFormatting.GREEN + nf.format(lc.zombieRevFlesh) + "\n" + + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.zombieRevs) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.zombieRevFlesh) + "\n" + EnumChatFormatting.BLUE + drop20 + "\n" + - EnumChatFormatting.DARK_GREEN + lc.zombiePestilences + "\n" + - EnumChatFormatting.WHITE + lc.zombieBooks + "\n" + - EnumChatFormatting.AQUA + lc.zombieUndeadCatas + "\n" + - EnumChatFormatting.DARK_PURPLE + lc.zombieBeheadeds + "\n" + - EnumChatFormatting.RED + lc.zombieRevCatas + "\n" + - EnumChatFormatting.DARK_GREEN + lc.zombieSnakes + "\n" + - EnumChatFormatting.GOLD + lc.zombieScythes + "\n" + + EnumChatFormatting.DARK_GREEN + LootCommand.zombiePestilences + "\n" + + EnumChatFormatting.WHITE + LootCommand.zombieBooks + "\n" + + EnumChatFormatting.AQUA + LootCommand.zombieUndeadCatas + "\n" + + EnumChatFormatting.DARK_PURPLE + LootCommand.zombieBeheadeds + "\n" + + EnumChatFormatting.RED + LootCommand.zombieRevCatas + "\n" + + EnumChatFormatting.DARK_GREEN + LootCommand.zombieSnakes + "\n" + + EnumChatFormatting.GOLD + LootCommand.zombieScythes + "\n" + EnumChatFormatting.AQUA + timeBetween + "\n" + EnumChatFormatting.AQUA + bossesBetween; - } else if (ds.display.equals("zombie_session")) { - if (lc.zombieTimeSession == -1) { + } else if (DisplayCommand.display.equals("zombie_session")) { + if (LootCommand.zombieTimeSession == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(lc.zombieTimeSession, timeNow); + timeBetween = Utils.getTimeBetween(LootCommand.zombieTimeSession, timeNow); } - if (lc.zombieBossesSession == -1) { + if (LootCommand.zombieBossesSession == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(lc.zombieBossesSession); + bossesBetween = nf.format(LootCommand.zombieBossesSession); } - if (tc.slayerCountTotal) { - drop20 = nf.format(lc.zombieFoulFleshSession); + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(LootCommand.zombieFoulFleshSession); } else { - drop20 = nf.format(lc.zombieFoulFleshDropsSession) + " times"; + drop20 = nf.format(LootCommand.zombieFoulFleshDropsSession) + " times"; } dropsText = EnumChatFormatting.GOLD + "Revs Killed:\n" + @@ -1323,28 +1310,28 @@ public class TheMod EnumChatFormatting.GOLD + "Scythe Blades:\n" + EnumChatFormatting.AQUA + "Time Since RNG:\n" + EnumChatFormatting.AQUA + "Bosses Since RNG:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.zombieRevsSession) + "\n" + - EnumChatFormatting.GREEN + nf.format(lc.zombieRevFleshSession) + "\n" + + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.zombieRevsSession) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.zombieRevFleshSession) + "\n" + EnumChatFormatting.BLUE + drop20 + "\n" + - EnumChatFormatting.DARK_GREEN + lc.zombiePestilencesSession + "\n" + - EnumChatFormatting.WHITE + lc.zombieBooksSession + "\n" + - EnumChatFormatting.AQUA + lc.zombieUndeadCatasSession + "\n" + - EnumChatFormatting.DARK_PURPLE + lc.zombieBeheadedsSession + "\n" + - EnumChatFormatting.RED + lc.zombieRevCatasSession + "\n" + - EnumChatFormatting.DARK_GREEN + lc.zombieSnakesSession + "\n" + - EnumChatFormatting.GOLD + lc.zombieScythes + "\n" + + EnumChatFormatting.DARK_GREEN + LootCommand.zombiePestilencesSession + "\n" + + EnumChatFormatting.WHITE + LootCommand.zombieBooksSession + "\n" + + EnumChatFormatting.AQUA + LootCommand.zombieUndeadCatasSession + "\n" + + EnumChatFormatting.DARK_PURPLE + LootCommand.zombieBeheadedsSession + "\n" + + EnumChatFormatting.RED + LootCommand.zombieRevCatasSession + "\n" + + EnumChatFormatting.DARK_GREEN + LootCommand.zombieSnakesSession + "\n" + + EnumChatFormatting.GOLD + LootCommand.zombieScythes + "\n" + EnumChatFormatting.AQUA + timeBetween + "\n" + EnumChatFormatting.AQUA + bossesBetween; - } else if (ds.display.equals("fishing")) { - if (lc.empTime == -1) { + } else if (DisplayCommand.display.equals("fishing")) { + if (LootCommand.empTime == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(lc.empTime, timeNow); + timeBetween = Utils.getTimeBetween(LootCommand.empTime, timeNow); } - if (lc.empSCs == -1) { + if (LootCommand.empSCs == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(lc.empSCs); + bossesBetween = nf.format(LootCommand.empSCs); } dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + @@ -1357,16 +1344,16 @@ public class TheMod EnumChatFormatting.DARK_AQUA + "Sea Guardians:\n" + EnumChatFormatting.BLUE + "Sea Witches:\n" + EnumChatFormatting.GREEN + "Sea Archers:"; - countText = EnumChatFormatting.AQUA + nf.format(lc.seaCreatures) + "\n" + - EnumChatFormatting.AQUA + nf.format(lc.fishingMilestone) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.goodCatches) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.greatCatches) + "\n" + - EnumChatFormatting.GRAY + nf.format(lc.squids) + "\n" + - EnumChatFormatting.GREEN + nf.format(lc.seaWalkers) + "\n" + - EnumChatFormatting.DARK_GRAY + nf.format(lc.nightSquids) + "\n" + - EnumChatFormatting.DARK_AQUA + nf.format(lc.seaGuardians) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.seaWitches) + "\n" + - EnumChatFormatting.GREEN + nf.format(lc.seaArchers); + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreatures) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestone) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatches) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatches) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.squids) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.seaWalkers) + "\n" + + EnumChatFormatting.DARK_GRAY + nf.format(LootCommand.nightSquids) + "\n" + + EnumChatFormatting.DARK_AQUA + nf.format(LootCommand.seaGuardians) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.seaWitches) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.seaArchers); // Seperated to save vertical space String dropsTextTwo = EnumChatFormatting.GREEN + "Monster of Deeps:\n" + EnumChatFormatting.YELLOW + "Catfishes:\n" + @@ -1378,34 +1365,34 @@ public class TheMod EnumChatFormatting.GOLD + "Sea Emperors:\n" + EnumChatFormatting.AQUA + "Time Since Emp:\n" + EnumChatFormatting.AQUA + "Creatures Since Emp:"; - String countTextTwo = EnumChatFormatting.GREEN + nf.format(lc.monsterOfTheDeeps) + "\n" + - EnumChatFormatting.YELLOW + nf.format(lc.catfishes) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.carrotKings) + "\n" + - EnumChatFormatting.GRAY + nf.format(lc.seaLeeches) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.guardianDefenders) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.deepSeaProtectors) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.hydras) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.seaEmperors) + "\n" + + String countTextTwo = EnumChatFormatting.GREEN + nf.format(LootCommand.monsterOfTheDeeps) + "\n" + + EnumChatFormatting.YELLOW + nf.format(LootCommand.catfishes) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.carrotKings) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.seaLeeches) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.guardianDefenders) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.deepSeaProtectors) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.hydras) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.seaEmperors) + "\n" + EnumChatFormatting.AQUA + timeBetween + "\n" + EnumChatFormatting.AQUA + bossesBetween; - if (tc.splitFishing) { - new TextRenderer(mc, dropsTextTwo, (int) (moc.displayXY[0] + (160 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); - new TextRenderer(mc, countTextTwo, (int) (moc.displayXY[0] + (270 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); + if (ToggleCommand.splitFishing) { + new TextRenderer(mc, dropsTextTwo, (int) (MoveCommand.displayXY[0] + (160 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); + new TextRenderer(mc, countTextTwo, (int) (MoveCommand.displayXY[0] + (270 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); } else { dropsText += "\n" + dropsTextTwo; countText += "\n" + countTextTwo; } - } else if (ds.display.equals("fishing_session")) { - if (lc.empTimeSession == -1) { + } else if (DisplayCommand.display.equals("fishing_session")) { + if (LootCommand.empTimeSession == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(lc.empTimeSession, timeNow); + timeBetween = Utils.getTimeBetween(LootCommand.empTimeSession, timeNow); } - if (lc.empSCsSession == -1) { + if (LootCommand.empSCsSession == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(lc.empSCsSession); + bossesBetween = nf.format(LootCommand.empSCsSession); } dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + @@ -1418,16 +1405,16 @@ public class TheMod EnumChatFormatting.DARK_AQUA + "Sea Guardians:\n" + EnumChatFormatting.BLUE + "Sea Witches:\n" + EnumChatFormatting.GREEN + "Sea Archers:"; - countText = EnumChatFormatting.AQUA + nf.format(lc.seaCreaturesSession) + "\n" + - EnumChatFormatting.AQUA + nf.format(lc.fishingMilestoneSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.goodCatchesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.greatCatchesSession) + "\n" + - EnumChatFormatting.GRAY + nf.format(lc.squidsSession) + "\n" + - EnumChatFormatting.GREEN + nf.format(lc.seaWalkersSession) + "\n" + - EnumChatFormatting.DARK_GRAY + nf.format(lc.nightSquidsSession) + "\n" + - EnumChatFormatting.DARK_AQUA + nf.format(lc.seaGuardiansSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.seaWitchesSession) + "\n" + - EnumChatFormatting.GREEN + nf.format(lc.seaArchersSession); + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreaturesSession) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestoneSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatchesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatchesSession) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.squidsSession) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.seaWalkersSession) + "\n" + + EnumChatFormatting.DARK_GRAY + nf.format(LootCommand.nightSquidsSession) + "\n" + + EnumChatFormatting.DARK_AQUA + nf.format(LootCommand.seaGuardiansSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.seaWitchesSession) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.seaArchersSession); // Seperated to save vertical space String dropsTextTwo = EnumChatFormatting.GREEN + "Monster of Deeps:\n" + EnumChatFormatting.YELLOW + "Catfishes:\n" + @@ -1439,34 +1426,34 @@ public class TheMod EnumChatFormatting.GOLD + "Sea Emperors:\n" + EnumChatFormatting.AQUA + "Time Since Emp:\n" + EnumChatFormatting.AQUA + "Creatures Since Emp:"; - String countTextTwo = EnumChatFormatting.GREEN + nf.format(lc.monsterOfTheDeepsSession) + "\n" + - EnumChatFormatting.YELLOW + nf.format(lc.catfishesSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.carrotKingsSession) + "\n" + - EnumChatFormatting.GRAY + nf.format(lc.seaLeechesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.guardianDefendersSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.deepSeaProtectorsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.hydrasSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.seaEmperorsSession) + "\n" + + String countTextTwo = EnumChatFormatting.GREEN + nf.format(LootCommand.monsterOfTheDeepsSession) + "\n" + + EnumChatFormatting.YELLOW + nf.format(LootCommand.catfishesSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.carrotKingsSession) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.seaLeechesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.guardianDefendersSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.deepSeaProtectorsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.hydrasSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.seaEmperorsSession) + "\n" + EnumChatFormatting.AQUA + timeBetween + "\n" + EnumChatFormatting.AQUA + bossesBetween; - if (tc.splitFishing) { - new TextRenderer(mc, dropsTextTwo, (int) (moc.displayXY[0] + (160 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); - new TextRenderer(mc, countTextTwo, (int) (moc.displayXY[0] + (270 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); + if (ToggleCommand.splitFishing) { + new TextRenderer(mc, dropsTextTwo, (int) (MoveCommand.displayXY[0] + (160 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); + new TextRenderer(mc, countTextTwo, (int) (MoveCommand.displayXY[0] + (270 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); } else { dropsText += "\n" + dropsTextTwo; countText += "\n" + countTextTwo; } - } else if (ds.display.equals("fishing_winter")) { - if (lc.yetiTime == -1) { + } else if (DisplayCommand.display.equals("fishing_winter")) { + if (LootCommand.yetiTime == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(lc.yetiTime, timeNow); + timeBetween = Utils.getTimeBetween(LootCommand.yetiTime, timeNow); } - if (lc.yetiSCs == -1) { + if (LootCommand.yetiSCs == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(lc.yetiSCs); + bossesBetween = nf.format(LootCommand.yetiSCs); } dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + @@ -1479,26 +1466,26 @@ public class TheMod EnumChatFormatting.GOLD + "Yetis:\n" + EnumChatFormatting.AQUA + "Time Since Yeti:\n" + EnumChatFormatting.AQUA + "Creatures Since Yeti:"; - countText = EnumChatFormatting.AQUA + nf.format(lc.seaCreatures) + "\n" + - EnumChatFormatting.AQUA + nf.format(lc.fishingMilestone) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.goodCatches) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.greatCatches) + "\n" + - EnumChatFormatting.AQUA + nf.format(lc.frozenSteves) + "\n" + - EnumChatFormatting.WHITE + nf.format(lc.frostyTheSnowmans) + "\n" + - EnumChatFormatting.DARK_GREEN + nf.format(lc.grinches) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.yetis) + "\n" + + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreatures) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestone) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatches) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatches) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.frozenSteves) + "\n" + + EnumChatFormatting.WHITE + nf.format(LootCommand.frostyTheSnowmans) + "\n" + + EnumChatFormatting.DARK_GREEN + nf.format(LootCommand.grinches) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.yetis) + "\n" + EnumChatFormatting.AQUA + timeBetween + "\n" + EnumChatFormatting.AQUA + bossesBetween; - } else if (ds.display.equals("fishing_winter_session")) { - if (lc.yetiTimeSession == -1) { + } else if (DisplayCommand.display.equals("fishing_winter_session")) { + if (LootCommand.yetiTimeSession == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(lc.yetiTimeSession, timeNow); + timeBetween = Utils.getTimeBetween(LootCommand.yetiTimeSession, timeNow); } - if (lc.yetiSCsSession == -1) { + if (LootCommand.yetiSCsSession == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(lc.yetiSCsSession); + bossesBetween = nf.format(LootCommand.yetiSCsSession); } dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + @@ -1511,17 +1498,17 @@ public class TheMod EnumChatFormatting.GOLD + "Yetis:\n" + EnumChatFormatting.AQUA + "Time Since Yeti:\n" + EnumChatFormatting.AQUA + "Creatures Since Yeti:"; - countText = EnumChatFormatting.AQUA + nf.format(lc.seaCreaturesSession) + "\n" + - EnumChatFormatting.AQUA + nf.format(lc.fishingMilestoneSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.goodCatchesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.greatCatchesSession) + "\n" + - EnumChatFormatting.AQUA + nf.format(lc.frozenStevesSession) + "\n" + - EnumChatFormatting.WHITE + nf.format(lc.frostyTheSnowmansSession) + "\n" + - EnumChatFormatting.DARK_GREEN + nf.format(lc.grinchesSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.yetisSession) + "\n" + + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreaturesSession) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestoneSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatchesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatchesSession) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.frozenStevesSession) + "\n" + + EnumChatFormatting.WHITE + nf.format(LootCommand.frostyTheSnowmansSession) + "\n" + + EnumChatFormatting.DARK_GREEN + nf.format(LootCommand.grinchesSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.yetisSession) + "\n" + EnumChatFormatting.AQUA + timeBetween + "\n" + EnumChatFormatting.AQUA + bossesBetween; - } else if (ds.display.equals("fishing_festival")) { + } else if (DisplayCommand.display.equals("fishing_festival")) { dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + EnumChatFormatting.AQUA + "Fishing Milestone:\n" + EnumChatFormatting.GOLD + "Good Catches:\n" + @@ -1530,15 +1517,15 @@ public class TheMod EnumChatFormatting.BLUE + "Blue Sharks:\n" + EnumChatFormatting.GOLD + "Tiger Sharks:\n" + EnumChatFormatting.WHITE + "Great White Sharks:"; - countText = EnumChatFormatting.AQUA + nf.format(lc.seaCreatures) + "\n" + - EnumChatFormatting.AQUA + nf.format(lc.fishingMilestone) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.goodCatches) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.greatCatches) + "\n" + - EnumChatFormatting.LIGHT_PURPLE + nf.format(lc.nurseSharks) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.blueSharks) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.tigerSharks) + "\n" + - EnumChatFormatting.WHITE + nf.format(lc.greatWhiteSharks); - } else if (ds.display.equals("fishing_festival_session")) { + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreatures) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestone) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatches) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatches) + "\n" + + EnumChatFormatting.LIGHT_PURPLE + nf.format(LootCommand.nurseSharks) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.blueSharks) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.tigerSharks) + "\n" + + EnumChatFormatting.WHITE + nf.format(LootCommand.greatWhiteSharks); + } else if (DisplayCommand.display.equals("fishing_festival_session")) { dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + EnumChatFormatting.AQUA + "Fishing Milestone:\n" + EnumChatFormatting.GOLD + "Good Catches:\n" + @@ -1547,15 +1534,15 @@ public class TheMod EnumChatFormatting.BLUE + "Blue Sharks:\n" + EnumChatFormatting.GOLD + "Tiger Sharks:\n" + EnumChatFormatting.WHITE + "Great White Sharks:"; - countText = EnumChatFormatting.AQUA + nf.format(lc.seaCreaturesSession) + "\n" + - EnumChatFormatting.AQUA + nf.format(lc.fishingMilestoneSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.goodCatchesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.greatCatchesSession) + "\n" + - EnumChatFormatting.LIGHT_PURPLE + nf.format(lc.nurseSharksSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.blueSharksSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.tigerSharksSession) + "\n" + - EnumChatFormatting.WHITE + nf.format(lc.greatWhiteSharksSession); - } else if (ds.display.equals("fishing_spooky")) { + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreaturesSession) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestoneSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatchesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatchesSession) + "\n" + + EnumChatFormatting.LIGHT_PURPLE + nf.format(LootCommand.nurseSharksSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.blueSharksSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.tigerSharksSession) + "\n" + + EnumChatFormatting.WHITE + nf.format(LootCommand.greatWhiteSharksSession); + } else if (DisplayCommand.display.equals("fishing_spooky")) { dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + EnumChatFormatting.AQUA + "Fishing Milestone:\n" + EnumChatFormatting.GOLD + "Good Catches:\n" + @@ -1565,16 +1552,16 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + "Werewolves:\n" + EnumChatFormatting.GOLD + "Phantom Fishers:\n" + EnumChatFormatting.GOLD + "Grim Reapers:"; - countText = EnumChatFormatting.AQUA + nf.format(lc.seaCreatures) + "\n" + - EnumChatFormatting.AQUA + nf.format(lc.fishingMilestone) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.goodCatches) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.greatCatches) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.scarecrows) + "\n" + - EnumChatFormatting.GRAY + nf.format(lc.nightmares) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.werewolfs) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.phantomFishers) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.grimReapers); - } else if (ds.display.equals("fishing_spooky_session")) { + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreatures) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestone) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatches) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatches) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.scarecrows) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.nightmares) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.werewolfs) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.phantomFishers) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.grimReapers); + } else if (DisplayCommand.display.equals("fishing_spooky_session")) { dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + EnumChatFormatting.AQUA + "Fishing Milestone:\n" + EnumChatFormatting.GOLD + "Good Catches:\n" + @@ -1584,64 +1571,64 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + "Werewolves:\n" + EnumChatFormatting.GOLD + "Phantom Fishers:\n" + EnumChatFormatting.GOLD + "Grim Reapers:"; - countText = EnumChatFormatting.AQUA + nf.format(lc.seaCreaturesSession) + "\n" + - EnumChatFormatting.AQUA + nf.format(lc.fishingMilestoneSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.goodCatchesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.greatCatchesSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.scarecrowsSession) + "\n" + - EnumChatFormatting.GRAY + nf.format(lc.nightmaresSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.werewolfsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.phantomFishersSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.grimReapersSession); - } else if (ds.display.equals("catacombs_floor_one")) { + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreaturesSession) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestoneSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatchesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatchesSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.scarecrowsSession) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.nightmaresSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.werewolfsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.phantomFishersSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.grimReapersSession); + } else if (DisplayCommand.display.equals("catacombs_floor_one")) { dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.BLUE + "Bonzo's Staffs:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooks) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.bonzoStaffs) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f1CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f1TimeSpent); - } else if (ds.display.equals("catacombs_floor_one_session")) { + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.bonzoStaffs) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f1CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f1TimeSpent); + } else if (DisplayCommand.display.equals("catacombs_floor_one_session")) { dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.BLUE + "Bonzo's Staffs:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.bonzoStaffsSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f1CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f1TimeSpentSession); - } else if (ds.display.equals("catacombs_floor_two")) { + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.bonzoStaffsSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f1CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f1TimeSpentSession); + } else if (DisplayCommand.display.equals("catacombs_floor_two")) { dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.BLUE + "Scarf's Studies:\n" + EnumChatFormatting.DARK_PURPLE + "Adaptive Blades:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooks) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.scarfStudies) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveSwords) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f2CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f2TimeSpent); - } else if (ds.display.equals("catacombs_floor_two_session")) { + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.scarfStudies) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveSwords) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f2CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f2TimeSpent); + } else if (DisplayCommand.display.equals("catacombs_floor_two_session")) { dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.BLUE + "Scarf's Studies:\n" + EnumChatFormatting.DARK_PURPLE + "Adaptive Blades:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.scarfStudiesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveSwordsSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f2CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f2TimeSpentSession); - } else if (ds.display.equals("catacombs_floor_three")) { + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.scarfStudiesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveSwordsSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f2CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f2TimeSpentSession); + } else if (DisplayCommand.display.equals("catacombs_floor_three")) { dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.DARK_PURPLE + "Adaptive Helmets:\n" + @@ -1650,15 +1637,15 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + "Adaptive Boots:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooks) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveHelms) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveChests) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveLegs) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveBoots) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f3CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f3TimeSpent); - } else if (ds.display.equals("catacombs_floor_three_session")) { + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveHelms) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveChests) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveLegs) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveBoots) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f3CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f3TimeSpent); + } else if (DisplayCommand.display.equals("catacombs_floor_three_session")) { dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.DARK_PURPLE + "Adaptive Helmets:\n" + @@ -1667,15 +1654,15 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + "Adaptive Boots:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveHelmsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveChestsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveLegsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.adaptiveBootsSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f3CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f3TimeSpentSession); - } else if (ds.display.equals("catacombs_floor_four")) { + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveHelmsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveChestsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveLegsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveBootsSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f3CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f3TimeSpentSession); + } else if (DisplayCommand.display.equals("catacombs_floor_four")) { dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.DARK_PURPLE + "Spirit Wings:\n" + @@ -1687,18 +1674,18 @@ public class TheMod EnumChatFormatting.GOLD + "Leg Spirit Pets:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooks) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.spiritWings) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.spiritBones) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.spiritBoots) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.spiritSwords) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.spiritBows) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.epicSpiritPets) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.legSpiritPets) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f4CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f4TimeSpent); - } else if (ds.display.equals("catacombs_floor_four_session")) { + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritWings) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritBones) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritBoots) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritSwords) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.spiritBows) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.epicSpiritPets) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.legSpiritPets) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f4CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f4TimeSpent); + } else if (DisplayCommand.display.equals("catacombs_floor_four_session")) { dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.DARK_PURPLE + "Spirit Wings:\n" + @@ -1710,18 +1697,18 @@ public class TheMod EnumChatFormatting.GOLD + "Leg Spirit Pets:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.spiritWingsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.spiritBonesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.spiritBootsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.spiritSwordsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.spiritBowsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.epicSpiritPetsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.legSpiritPetsSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f4CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f4TimeSpentSession); - } else if (ds.display.equals("catacombs_floor_five")) { + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritWingsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritBonesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritBootsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritSwordsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.spiritBowsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.epicSpiritPetsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.legSpiritPetsSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f4CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f4TimeSpentSession); + } else if (DisplayCommand.display.equals("catacombs_floor_five")) { dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.BLUE + "Warped Stones:\n" + @@ -1734,19 +1721,19 @@ public class TheMod EnumChatFormatting.GOLD + "Shadow Furys:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooks) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.warpedStones) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssHelms) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssChests) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssLegs) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssBoots) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.lastBreaths) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.lividDaggers) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.shadowFurys) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f5CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f5TimeSpent); - } else if (ds.display.equals("catacombs_floor_five_session")) { + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.warpedStones) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssHelms) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssChests) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssLegs) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssBoots) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.lastBreaths) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.lividDaggers) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.shadowFurys) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f5CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f5TimeSpent); + } else if (DisplayCommand.display.equals("catacombs_floor_five_session")) { dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.BLUE + "Warped Stones:\n" + @@ -1759,19 +1746,19 @@ public class TheMod EnumChatFormatting.GOLD + "Shadow Furys:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.warpedStonesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssHelmsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssChestsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssLegsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.shadowAssBootsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.lastBreathsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.lividDaggersSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.shadowFurysSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f5CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f5TimeSpentSession); - } else if (ds.display.equals("catacombs_floor_six")) { + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.warpedStonesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssHelmsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssChestsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssLegsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssBootsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.lastBreathsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.lividDaggersSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.shadowFurysSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f5CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f5TimeSpentSession); + } else if (DisplayCommand.display.equals("catacombs_floor_six")) { dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.BLUE + "Ancient Roses:\n" + @@ -1784,19 +1771,19 @@ public class TheMod EnumChatFormatting.GOLD + "Necro Swords:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooks) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.ancientRoses) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.precursorEyes) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.giantsSwords) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.necroLordHelms) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.necroLordChests) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.necroLordLegs) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.necroLordBoots) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.necroSwords) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f6CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f6TimeSpent); - } else if (ds.display.equals("catacombs_floor_six_session")) { + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.ancientRoses) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.precursorEyes) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.giantsSwords) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordHelms) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordChests) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordLegs) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordBoots) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroSwords) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f6CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f6TimeSpent); + } else if (DisplayCommand.display.equals("catacombs_floor_six_session")) { dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + EnumChatFormatting.BLUE + "Ancient Roses:\n" + @@ -1809,34 +1796,32 @@ public class TheMod EnumChatFormatting.GOLD + "Necro Swords:\n" + EnumChatFormatting.AQUA + "Coins Spent:\n" + EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(lc.recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(lc.fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.ancientRosesSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.precursorEyesSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.giantsSwordsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.necroLordHelmsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.necroLordChestsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.necroLordLegsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.necroLordBootsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(lc.necroSwordsSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(lc.f6CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, lc.f6TimeSpentSession); + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.ancientRosesSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.precursorEyesSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.giantsSwordsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordHelmsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordChestsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordLegsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordBootsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroSwordsSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f6CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f6TimeSpentSession); } else { - ConfigHandler cf = new ConfigHandler(); - System.out.println("Display was an unknown value, turning off."); - ds.display = "off"; - cf.writeStringConfig("misc", "display", "off"); + DisplayCommand.display = "off"; + ConfigHandler.writeStringConfig("misc", "display", "off"); } - new TextRenderer(mc, dropsText, moc.displayXY[0], moc.displayXY[1], ScaleCommand.displayScale); - new TextRenderer(mc, countText, (int) (moc.displayXY[0] + (110 * ScaleCommand.displayScale)), moc.displayXY[1], ScaleCommand.displayScale); + new TextRenderer(mc, dropsText, MoveCommand.displayXY[0], MoveCommand.displayXY[1], ScaleCommand.displayScale); + new TextRenderer(mc, countText, (int) (MoveCommand.displayXY[0] + (110 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); } if (showTitle) { Utils.drawTitle(titleText); } if (showSkill) { - new TextRenderer(mc, skillText, moc.skill50XY[0], moc.skill50XY[1], ScaleCommand.skill50Scale); + new TextRenderer(mc, skillText, MoveCommand.skill50XY[0], MoveCommand.skill50XY[1], ScaleCommand.skill50Scale); } } @@ -1848,16 +1833,12 @@ public class TheMod checkItemsNow = System.currentTimeMillis() / 1000; if (checkItemsNow - itemsChecked < 3) return; - final ScoreboardHandler sc = new ScoreboardHandler(); - List scoreboard = sc.getSidebarLines(); + List scoreboard = ScoreboardHandler.getSidebarLines(); for (String line : scoreboard) { - String cleanedLine = sc.cleanSB(line); + String cleanedLine = ScoreboardHandler.cleanSB(line); // If Hypixel lags and scoreboard doesn't update if (cleanedLine.contains("Boss slain!") || cleanedLine.contains("Slay the boss!")) { - final LootCommand lc = new LootCommand(); - final ConfigHandler cf = new ConfigHandler(); - int itemTeeth = Utils.getItems("Wolf Tooth"); int itemWheels = Utils.getItems("Hamster Wheel"); int itemWebs = Utils.getItems("Tarantula Web"); @@ -1868,25 +1849,25 @@ public class TheMod // If no items, are detected, allow check again. Should fix items not being found if (itemTeeth + itemWheels + itemWebs + itemTAP + itemRev + itemFoul > 0) { itemsChecked = System.currentTimeMillis() / 1000; - lc.wolfTeeth += itemTeeth; - lc.wolfWheels += itemWheels; - lc.spiderWebs += itemWebs; - lc.spiderTAP += itemTAP; - lc.zombieRevFlesh += itemRev; - lc.zombieFoulFlesh += itemFoul; - lc.wolfTeethSession += itemTeeth; - lc.wolfWheelsSession += itemWheels; - lc.spiderWebsSession += itemWebs; - lc.spiderTAPSession += itemTAP; - lc.zombieRevFleshSession += itemRev; - lc.zombieFoulFleshSession += itemFoul; + LootCommand.wolfTeeth += itemTeeth; + LootCommand.wolfWheels += itemWheels; + LootCommand.spiderWebs += itemWebs; + LootCommand.spiderTAP += itemTAP; + LootCommand.zombieRevFlesh += itemRev; + LootCommand.zombieFoulFlesh += itemFoul; + LootCommand.wolfTeethSession += itemTeeth; + LootCommand.wolfWheelsSession += itemWheels; + LootCommand.spiderWebsSession += itemWebs; + LootCommand.spiderTAPSession += itemTAP; + LootCommand.zombieRevFleshSession += itemRev; + LootCommand.zombieFoulFleshSession += itemFoul; - cf.writeIntConfig("wolf", "teeth", lc.wolfTeeth); - cf.writeIntConfig("wolf", "wheel", lc.wolfWheels); - cf.writeIntConfig("spider", "web", lc.spiderWebs); - cf.writeIntConfig("spider", "tap", lc.spiderTAP); - cf.writeIntConfig("zombie", "revFlesh", lc.zombieRevFlesh); - cf.writeIntConfig("zombie", "foulFlesh", lc.zombieFoulFlesh); + ConfigHandler.writeIntConfig("wolf", "teeth", LootCommand.wolfTeeth); + ConfigHandler.writeIntConfig("wolf", "wheel", LootCommand.wolfWheels); + ConfigHandler.writeIntConfig("spider", "web", LootCommand.spiderWebs); + ConfigHandler.writeIntConfig("spider", "tap", LootCommand.spiderTAP); + ConfigHandler.writeIntConfig("zombie", "revFlesh", LootCommand.zombieRevFlesh); + ConfigHandler.writeIntConfig("zombie", "foulFlesh", LootCommand.zombieFoulFlesh); } } } @@ -1896,18 +1877,16 @@ public class TheMod @SubscribeEvent(priority = EventPriority.HIGHEST) public void onTooltip(ItemTooltipEvent event) { if (!Utils.inSkyblock) return; - final ToggleCommand tc = new ToggleCommand(); - if (event.toolTip == null) return; ItemStack item = event.itemStack; - if (tc.goldenToggled) { + if (ToggleCommand.goldenToggled) { for (int i = 0; i < event.toolTip.size(); i++) { event.toolTip.set(i, Utils.returnGoldenEnchants(event.toolTip.get(i))); } } - if (tc.expertiseLoreToggled) { + if (ToggleCommand.expertiseLoreToggled) { if (item.hasTagCompound()) { NBTTagCompound tags = item.getSubCompound("ExtraAttributes", false); if (tags != null) { @@ -2272,9 +2251,7 @@ public class TheMod Container containerChest = ((GuiChest) event.gui).inventorySlots; if (containerChest instanceof ContainerChest) { // a lot of declarations here, if you get scarred, my bad - LootCommand lc = new LootCommand(); - ConfigHandler cf = new ConfigHandler(); - GuiChest chest = (GuiChest) event.gui; + GuiChest chest = (GuiChest) event.gui; IInventory inventory = ((ContainerChest) containerChest).getLowerChestInventory(); Slot mouseSlot = chest.getSlotUnderMouse(); if (mouseSlot == null || mouseSlot.getStack() == null) return; @@ -2295,29 +2272,29 @@ public class TheMod String sCleaned = ScoreboardHandler.cleanSB(s); if (sCleaned.contains("The Catacombs (")) { if (sCleaned.contains("F1")) { - lc.f1CoinsSpent += coinsSpent; - lc.f1CoinsSpentSession += coinsSpent; - cf.writeDoubleConfig("catacombs", "floorOneCoins", lc.f1CoinsSpent); + LootCommand.f1CoinsSpent += coinsSpent; + LootCommand.f1CoinsSpentSession += coinsSpent; + ConfigHandler.writeDoubleConfig("catacombs", "floorOneCoins", LootCommand.f1CoinsSpent); } else if (sCleaned.contains("F2")) { - lc.f2CoinsSpent += coinsSpent; - lc.f2CoinsSpentSession += coinsSpent; - cf.writeDoubleConfig("catacombs", "floorTwoCoins", lc.f2CoinsSpent); + LootCommand.f2CoinsSpent += coinsSpent; + LootCommand.f2CoinsSpentSession += coinsSpent; + ConfigHandler.writeDoubleConfig("catacombs", "floorTwoCoins", LootCommand.f2CoinsSpent); } else if (sCleaned.contains("F3")) { - lc.f3CoinsSpent += coinsSpent; - lc.f3CoinsSpentSession += coinsSpent; - cf.writeDoubleConfig("catacombs", "floorThreeCoins", lc.f3CoinsSpent); + LootCommand.f3CoinsSpent += coinsSpent; + LootCommand.f3CoinsSpentSession += coinsSpent; + ConfigHandler.writeDoubleConfig("catacombs", "floorThreeCoins", LootCommand.f3CoinsSpent); } else if (sCleaned.contains("F4")) { - lc.f4CoinsSpent += coinsSpent; - lc.f4CoinsSpentSession += coinsSpent; - cf.writeDoubleConfig("catacombs", "floorFourCoins", lc.f4CoinsSpent); + LootCommand.f4CoinsSpent += coinsSpent; + LootCommand.f4CoinsSpentSession += coinsSpent; + ConfigHandler.writeDoubleConfig("catacombs", "floorFourCoins", LootCommand.f4CoinsSpent); } else if (sCleaned.contains("F5")) { - lc.f5CoinsSpent += coinsSpent; - lc.f5CoinsSpentSession += coinsSpent; - cf.writeDoubleConfig("catacombs", "floorFiveCoins", lc.f5CoinsSpent); + LootCommand.f5CoinsSpent += coinsSpent; + LootCommand.f5CoinsSpentSession += coinsSpent; + ConfigHandler.writeDoubleConfig("catacombs", "floorFiveCoins", LootCommand.f5CoinsSpent); } else if (sCleaned.contains("F6")) { - lc.f6CoinsSpent += coinsSpent; - lc.f6CoinsSpentSession += coinsSpent; - cf.writeDoubleConfig("catacombs", "floorSixCoins", lc.f6CoinsSpent); + LootCommand.f6CoinsSpent += coinsSpent; + LootCommand.f6CoinsSpentSession += coinsSpent; + ConfigHandler.writeDoubleConfig("catacombs", "floorSixCoins", LootCommand.f6CoinsSpent); } break; } @@ -2415,37 +2392,34 @@ public class TheMod } public void increaseSeaCreatures() { - LootCommand lc = new LootCommand(); - ConfigHandler cf = new ConfigHandler(); - - if (lc.empSCs != -1) { - lc.empSCs++; + if (LootCommand.empSCs != -1) { + LootCommand.empSCs++; } - if (lc.empSCsSession != -1) { - lc.empSCsSession++; + if (LootCommand.empSCsSession != -1) { + LootCommand.empSCsSession++; } // Only increment Yetis when in Jerry's Workshop List scoreboard = ScoreboardHandler.getSidebarLines(); for (String s : scoreboard) { String sCleaned = ScoreboardHandler.cleanSB(s); if (sCleaned.contains("Jerry's Workshop") || sCleaned.contains("Jerry Pond")) { - if (lc.yetiSCs != -1) { - lc.yetiSCs++; + if (LootCommand.yetiSCs != -1) { + LootCommand.yetiSCs++; } - if (lc.yetiSCsSession != -1) { - lc.yetiSCsSession++; + if (LootCommand.yetiSCsSession != -1) { + LootCommand.yetiSCsSession++; } } } - lc.seaCreatures++; - lc.fishingMilestone++; - lc.seaCreaturesSession++; - lc.fishingMilestoneSession++; - cf.writeIntConfig("fishing", "seaCreature", lc.seaCreatures); - cf.writeIntConfig("fishing", "milestone", lc.fishingMilestone); - cf.writeIntConfig("fishing", "empSC", lc.empSCs); - cf.writeIntConfig("fishing", "yetiSC", lc.yetiSCs); + LootCommand.seaCreatures++; + LootCommand.fishingMilestone++; + LootCommand.seaCreaturesSession++; + LootCommand.fishingMilestoneSession++; + ConfigHandler.writeIntConfig("fishing", "seaCreature", LootCommand.seaCreatures); + ConfigHandler.writeIntConfig("fishing", "milestone", LootCommand.fishingMilestone); + ConfigHandler.writeIntConfig("fishing", "empSC", LootCommand.empSCs); + ConfigHandler.writeIntConfig("fishing", "yetiSC", LootCommand.yetiSCs); } diff --git a/src/main/java/me/Danker/commands/ArmourCommand.java b/src/main/java/me/Danker/commands/ArmourCommand.java index 44255e8..a10d75f 100644 --- a/src/main/java/me/Danker/commands/ArmourCommand.java +++ b/src/main/java/me/Danker/commands/ArmourCommand.java @@ -32,8 +32,7 @@ public class ArmourCommand extends CommandBase { } @Override - public List getCommandAliases() - { + public List getCommandAliases() { return Collections.singletonList("armour"); } @@ -59,12 +58,10 @@ public class ArmourCommand extends CommandBase { public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { // MULTI THREAD DRIFTING new Thread(() -> { - APIHandler ah = new APIHandler(); - ConfigHandler cf = new ConfigHandler(); EntityPlayer player = (EntityPlayer) arg0; // Check key - String key = cf.getString("api", "APIKey"); + String key = ConfigHandler.getString("api", "APIKey"); if (key.equals("")) { player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "API key not set. Use /setkey.")); } @@ -79,16 +76,16 @@ public class ArmourCommand extends CommandBase { } else { username = arg1[0]; player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Checking armour of " + TheMod.SECONDARY_COLOUR + username)); - uuid = ah.getUUID(username); + uuid = APIHandler.getUUID(username); } // Find stats of latest profile - String latestProfile = ah.getLatestProfileID(uuid, key); + String latestProfile = APIHandler.getLatestProfileID(uuid, key); if (latestProfile == null) return; String profileURL = "https://api.hypixel.net/skyblock/profile?profile=" + latestProfile + "&key=" + key; System.out.println("Fetching profile..."); - JsonObject profileResponse = ah.getResponse(profileURL); + JsonObject profileResponse = APIHandler.getResponse(profileURL); if (!profileResponse.get("success").getAsBoolean()) { String reason = profileResponse.get("cause").getAsString(); player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Failed with reason: " + reason)); diff --git a/src/main/java/me/Danker/commands/BankCommand.java b/src/main/java/me/Danker/commands/BankCommand.java index f832a2d..6e2ddaa 100644 --- a/src/main/java/me/Danker/commands/BankCommand.java +++ b/src/main/java/me/Danker/commands/BankCommand.java @@ -53,12 +53,10 @@ public class BankCommand extends CommandBase { public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { // MULTI THREAD DRIFTING new Thread(() -> { - APIHandler ah = new APIHandler(); - ConfigHandler cf = new ConfigHandler(); EntityPlayer player = (EntityPlayer) arg0; // Check key - String key = cf.getString("api", "APIKey"); + String key = ConfigHandler.getString("api", "APIKey"); if (key.equals("")) { player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "API key not set. Use /setkey.")); } @@ -73,16 +71,16 @@ public class BankCommand extends CommandBase { } else { username = arg1[0]; player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Checking coins of " + TheMod.SECONDARY_COLOUR + username)); - uuid = ah.getUUID(username); + uuid = APIHandler.getUUID(username); } // Find stats of latest profile - String latestProfile = ah.getLatestProfileID(uuid, key); + String latestProfile = APIHandler.getLatestProfileID(uuid, key); if (latestProfile == null) return; String profileURL = "https://api.hypixel.net/skyblock/profile?profile=" + latestProfile + "&key=" + key; System.out.println("Fetching profile..."); - JsonObject profileResponse = ah.getResponse(profileURL); + JsonObject profileResponse = APIHandler.getResponse(profileURL); if (!profileResponse.get("success").getAsBoolean()) { String reason = profileResponse.get("cause").getAsString(); player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "Failed with reason: " + reason)); diff --git a/src/main/java/me/Danker/commands/BlockSlayerCommand.java b/src/main/java/me/Danker/commands/BlockSlayerCommand.java index bc6a32b..96ea530 100644 --- a/src/main/java/me/Danker/commands/BlockSlayerCommand.java +++ b/src/main/java/me/Danker/commands/BlockSlayerCommand.java @@ -10,7 +10,6 @@ import net.minecraft.command.ICommandSender; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.BlockPos; import net.minecraft.util.ChatComponentText; -import net.minecraft.util.EnumChatFormatting; public class BlockSlayerCommand extends CommandBase { @@ -45,7 +44,6 @@ public class BlockSlayerCommand extends CommandBase { @Override public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { final EntityPlayer player = (EntityPlayer)arg0; - final ConfigHandler cf = new ConfigHandler(); if (arg1.length == 0 || (arg1.length == 1 && !arg1[0].equalsIgnoreCase("off"))) { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); @@ -61,7 +59,7 @@ public class BlockSlayerCommand extends CommandBase { } else if (arg1[0].equalsIgnoreCase("off")) { onlySlayerName = ""; onlySlayerNumber = ""; - cf.writeStringConfig("toggles", "BlockSlayer", ""); + ConfigHandler.writeStringConfig("toggles", "BlockSlayer", ""); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Slayer blocking turned off.")); return; } else { @@ -91,7 +89,7 @@ public class BlockSlayerCommand extends CommandBase { return; } - cf.writeStringConfig("toggles", "BlockSlayer", onlySlayerName + " " + onlySlayerNumber); + ConfigHandler.writeStringConfig("toggles", "BlockSlayer", onlySlayerName + " " + onlySlayerNumber); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Slayer blocking set to " + TheMod.SECONDARY_COLOUR + onlySlayerName + " " + onlySlayerNumber)); } diff --git a/src/main/java/me/Danker/commands/DankerGuiCommand.java b/src/main/java/me/Danker/commands/DankerGuiCommand.java index ef39d24..3616849 100644 --- a/src/main/java/me/Danker/commands/DankerGuiCommand.java +++ b/src/main/java/me/Danker/commands/DankerGuiCommand.java @@ -1,8 +1,6 @@ package me.Danker.commands; import me.Danker.TheMod; -import me.Danker.gui.DankerGui; -import net.minecraft.client.Minecraft; import net.minecraft.command.CommandBase; import net.minecraft.command.CommandException; import net.minecraft.command.ICommandSender; diff --git a/src/main/java/me/Danker/commands/DisplayCommand.java b/src/main/java/me/Danker/commands/DisplayCommand.java index 6e00fba..2af402e 100644 --- a/src/main/java/me/Danker/commands/DisplayCommand.java +++ b/src/main/java/me/Danker/commands/DisplayCommand.java @@ -10,7 +10,6 @@ import net.minecraft.command.ICommandSender; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.BlockPos; import net.minecraft.util.ChatComponentText; -import net.minecraft.util.EnumChatFormatting; public class DisplayCommand extends CommandBase { public static String display; @@ -54,7 +53,6 @@ public class DisplayCommand extends CommandBase { return; } - final ConfigHandler cf = new ConfigHandler(); boolean showSession = false; if (arg1[arg1.length - 1].equalsIgnoreCase("session")) showSession = true; @@ -151,7 +149,7 @@ public class DisplayCommand extends CommandBase { } else if (arg1[0].equalsIgnoreCase("auto")) { auto = true; player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Display set to " + TheMod.SECONDARY_COLOUR + "auto" + TheMod.MAIN_COLOUR + ".")); - cf.writeBooleanConfig("misc", "autoDisplay", true); + ConfigHandler.writeBooleanConfig("misc", "autoDisplay", true); return; } else if (arg1[0].equalsIgnoreCase("off")) { display = "off"; @@ -161,8 +159,8 @@ public class DisplayCommand extends CommandBase { } auto = false; player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Display set to " + TheMod.SECONDARY_COLOUR + display + TheMod.MAIN_COLOUR + ".")); - cf.writeBooleanConfig("misc", "autoDisplay", false); - cf.writeStringConfig("misc", "display", display); + ConfigHandler.writeBooleanConfig("misc", "autoDisplay", false); + ConfigHandler.writeStringConfig("misc", "display", display); } } diff --git a/src/main/java/me/Danker/commands/DungeonsCommand.java b/src/main/java/me/Danker/commands/DungeonsCommand.java index 7a57400..4b8c126 100644 --- a/src/main/java/me/Danker/commands/DungeonsCommand.java +++ b/src/main/java/me/Danker/commands/DungeonsCommand.java @@ -45,12 +45,10 @@ public class DungeonsCommand extends CommandBase { public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { // MULTI THREAD DRIFTING new Thread(() -> { - APIHandler ah = new APIHandler(); - ConfigHandler cf = new ConfigHandler(); EntityPlayer player = (EntityPlayer) arg0; // Check key - String key = cf.getString("api", "APIKey"); + String key = ConfigHandler.getString("api", "APIKey"); if (key.equals("")) { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "API key not set. Use /setkey.")); } @@ -65,16 +63,16 @@ public class DungeonsCommand extends CommandBase { } else { username = arg1[0]; player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Checking dungeon stats of " + TheMod.SECONDARY_COLOUR + username)); - uuid = ah.getUUID(username); + uuid = APIHandler.getUUID(username); } // Find stats of latest profile - String latestProfile = ah.getLatestProfileID(uuid, key); + String latestProfile = APIHandler.getLatestProfileID(uuid, key); if (latestProfile == null) return; String profileURL = "https://api.hypixel.net/skyblock/profile?profile=" + latestProfile + "&key=" + key; System.out.println("Fetching profile..."); - JsonObject profileResponse = ah.getResponse(profileURL); + JsonObject profileResponse = APIHandler.getResponse(profileURL); if (!profileResponse.get("success").getAsBoolean()) { String reason = profileResponse.get("cause").getAsString(); player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Failed with reason: " + reason)); diff --git a/src/main/java/me/Danker/commands/GetkeyCommand.java b/src/main/java/me/Danker/commands/GetkeyCommand.java index 32fa6df..e7dd051 100644 --- a/src/main/java/me/Danker/commands/GetkeyCommand.java +++ b/src/main/java/me/Danker/commands/GetkeyCommand.java @@ -12,7 +12,6 @@ import net.minecraft.command.ICommand; import net.minecraft.command.ICommandSender; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.ChatComponentText; -import net.minecraft.util.EnumChatFormatting; public class GetkeyCommand extends CommandBase implements ICommand { @@ -34,16 +33,15 @@ public class GetkeyCommand extends CommandBase implements ICommand { @Override public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { EntityPlayer player = (EntityPlayer)arg0; - ConfigHandler cf = new ConfigHandler(); Clipboard clipboard = Toolkit.getDefaultToolkit().getSystemClipboard(); - StringSelection stringSelection = new StringSelection(cf.getString("api", "APIKey")); + StringSelection stringSelection = new StringSelection(ConfigHandler.getString("api", "APIKey")); - if (cf.getString("api", "APIKey").equals("")) { + if (ConfigHandler.getString("api", "APIKey").equals("")) { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "API key not set. Set your API key using /setkey.")); } clipboard.setContents(stringSelection, null); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Your set API key is " + TheMod.SECONDARY_COLOUR + cf.getString("api", "APIKey") + "\n" + + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Your set API key is " + TheMod.SECONDARY_COLOUR + ConfigHandler.getString("api", "APIKey") + "\n" + TheMod.MAIN_COLOUR + " Your set API key has been copied to the clipboard.")); } diff --git a/src/main/java/me/Danker/commands/GuildOfCommand.java b/src/main/java/me/Danker/commands/GuildOfCommand.java index 44fb783..881a9c4 100644 --- a/src/main/java/me/Danker/commands/GuildOfCommand.java +++ b/src/main/java/me/Danker/commands/GuildOfCommand.java @@ -47,12 +47,10 @@ public class GuildOfCommand extends CommandBase { public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { // MULTI THREAD DRIFTING new Thread(() -> { - APIHandler ah = new APIHandler(); - ConfigHandler cf = new ConfigHandler(); EntityPlayer player = (EntityPlayer) arg0; // Check key - String key = cf.getString("api", "APIKey"); + String key = ConfigHandler.getString("api", "APIKey"); if (key.equals("")) { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "API key not set. Use /setkey.")); } @@ -67,13 +65,13 @@ public class GuildOfCommand extends CommandBase { } else { username = arg1[0]; player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Checking guild of " + TheMod.SECONDARY_COLOUR + username)); - uuid = ah.getUUID(username); + uuid = APIHandler.getUUID(username); } // Find guild ID System.out.println("Fetching guild..."); String guildURL = "https://api.hypixel.net/guild?player=" + uuid + "&key=" + key; - JsonObject guildResponse = ah.getResponse(guildURL); + JsonObject guildResponse = APIHandler.getResponse(guildURL); if (!guildResponse.get("success").getAsBoolean()) { String reason = guildResponse.get("cause").getAsString(); player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Failed with reason: " + reason)); @@ -100,7 +98,7 @@ public class GuildOfCommand extends CommandBase { // Get username from UUID String gmUUID = memberObject.get("uuid").getAsString(); String gmNameURL = "https://api.mojang.com/user/profiles/" + gmUUID + "/names"; - JsonArray gmNameResponse = ah.getArrayResponse(gmNameURL); + JsonArray gmNameResponse = APIHandler.getArrayResponse(gmNameURL); guildMaster = gmNameResponse.get(gmNameResponse.size() - 1).getAsJsonObject().get("name").getAsString(); break; diff --git a/src/main/java/me/Danker/commands/ImportFishingCommand.java b/src/main/java/me/Danker/commands/ImportFishingCommand.java index 67e4c61..734a561 100644 --- a/src/main/java/me/Danker/commands/ImportFishingCommand.java +++ b/src/main/java/me/Danker/commands/ImportFishingCommand.java @@ -10,7 +10,6 @@ import net.minecraft.command.CommandException; import net.minecraft.command.ICommandSender; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.ChatComponentText; -import net.minecraft.util.EnumChatFormatting; public class ImportFishingCommand extends CommandBase { @@ -33,13 +32,10 @@ public class ImportFishingCommand extends CommandBase { public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { // MULTI THREAD DRIFTING new Thread(() -> { - APIHandler ah = new APIHandler(); - LootCommand lc = new LootCommand(); - ConfigHandler cf = new ConfigHandler(); EntityPlayer player = (EntityPlayer) arg0; // Check key - String key = cf.getString("api", "APIKey"); + String key = ConfigHandler.getString("api", "APIKey"); if (key.equals("")) { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "API key not set. Use /setkey.")); } @@ -50,12 +46,12 @@ public class ImportFishingCommand extends CommandBase { String username = player.getName(); String uuid = player.getUniqueID().toString().replaceAll("[\\-]", ""); - String latestProfile = ah.getLatestProfileID(uuid, key); + String latestProfile = APIHandler.getLatestProfileID(uuid, key); if (latestProfile == null) return; String profileURL = "https://api.hypixel.net/skyblock/profile?profile=" + latestProfile + "&key=" + key; System.out.println("Fetching profile..."); - JsonObject profileResponse = ah.getResponse(profileURL); + JsonObject profileResponse = APIHandler.getResponse(profileURL); if (!profileResponse.get("success").getAsBoolean()) { String reason = profileResponse.get("cause").getAsString(); player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Failed with reason: " + reason)); @@ -65,230 +61,230 @@ public class ImportFishingCommand extends CommandBase { System.out.println("Fetching fishing stats..."); JsonObject statsObject = profileResponse.get("profile").getAsJsonObject().get("members").getAsJsonObject().get(uuid).getAsJsonObject().get("stats").getAsJsonObject(); - lc.greatCatches = 0; - lc.goodCatches = 0; + LootCommand.greatCatches = 0; + LootCommand.goodCatches = 0; if (statsObject.has("items_fished_treasure")) { if (statsObject.has("items_fished_large_treasure")) { - lc.greatCatches = statsObject.get("items_fished_large_treasure").getAsInt(); - lc.goodCatches = statsObject.get("items_fished_treasure").getAsInt() - lc.greatCatches; + LootCommand.greatCatches = statsObject.get("items_fished_large_treasure").getAsInt(); + LootCommand.goodCatches = statsObject.get("items_fished_treasure").getAsInt() - LootCommand.greatCatches; } else { - lc.goodCatches = statsObject.get("items_fished_treasure").getAsInt(); + LootCommand.goodCatches = statsObject.get("items_fished_treasure").getAsInt(); } } - lc.seaCreatures = 0; - lc.squids = 0; + LootCommand.seaCreatures = 0; + LootCommand.squids = 0; if (statsObject.has("kills_pond_squid")) { - lc.squids = statsObject.get("kills_pond_squid").getAsInt(); + LootCommand.squids = statsObject.get("kills_pond_squid").getAsInt(); } - lc.seaCreatures += lc.squids; + LootCommand.seaCreatures += LootCommand.squids; - lc.seaWalkers = 0; + LootCommand.seaWalkers = 0; if (statsObject.has("kills_sea_walker")) { - lc.seaWalkers = statsObject.get("kills_sea_walker").getAsInt(); + LootCommand.seaWalkers = statsObject.get("kills_sea_walker").getAsInt(); } - lc.seaCreatures += lc.seaWalkers; + LootCommand.seaCreatures += LootCommand.seaWalkers; - lc.nightSquids = 0; + LootCommand.nightSquids = 0; if (statsObject.has("kills_night_squid")) { - lc.nightSquids = statsObject.get("kills_night_squid").getAsInt(); + LootCommand.nightSquids = statsObject.get("kills_night_squid").getAsInt(); } - lc.seaCreatures += lc.nightSquids; + LootCommand.seaCreatures += LootCommand.nightSquids; - lc.seaGuardians = 0; + LootCommand.seaGuardians = 0; if (statsObject.has("kills_sea_guardian")) { - lc.seaGuardians = statsObject.get("kills_sea_guardian").getAsInt(); + LootCommand.seaGuardians = statsObject.get("kills_sea_guardian").getAsInt(); } - lc.seaCreatures += lc.seaGuardians; + LootCommand.seaCreatures += LootCommand.seaGuardians; - lc.seaWitches = 0; + LootCommand.seaWitches = 0; if (statsObject.has("kills_sea_witch")) { - lc.seaWitches = statsObject.get("kills_sea_witch").getAsInt(); + LootCommand.seaWitches = statsObject.get("kills_sea_witch").getAsInt(); } - lc.seaCreatures += lc.seaWitches; + LootCommand.seaCreatures += LootCommand.seaWitches; - lc.seaArchers = 0; + LootCommand.seaArchers = 0; if (statsObject.has("kills_sea_archer")) { - lc.seaArchers = statsObject.get("kills_sea_archer").getAsInt(); + LootCommand.seaArchers = statsObject.get("kills_sea_archer").getAsInt(); } - lc.seaCreatures += lc.seaArchers; + LootCommand.seaCreatures += LootCommand.seaArchers; - lc.monsterOfTheDeeps = 0; + LootCommand.monsterOfTheDeeps = 0; if (statsObject.has("kills_zombie_deep")) { if (statsObject.has("kills_chicken_deep")) { - lc.monsterOfTheDeeps = statsObject.get("kills_zombie_deep").getAsInt() + statsObject.get("kills_chicken_deep").getAsInt(); + LootCommand.monsterOfTheDeeps = statsObject.get("kills_zombie_deep").getAsInt() + statsObject.get("kills_chicken_deep").getAsInt(); } else { - lc.monsterOfTheDeeps = statsObject.get("kills_zombie_deep").getAsInt(); + LootCommand.monsterOfTheDeeps = statsObject.get("kills_zombie_deep").getAsInt(); } } else if (statsObject.has("kills_chicken_deep")) { - lc.monsterOfTheDeeps = statsObject.get("kills_chicken_deep").getAsInt(); + LootCommand.monsterOfTheDeeps = statsObject.get("kills_chicken_deep").getAsInt(); } - lc.seaCreatures += lc.monsterOfTheDeeps; + LootCommand.seaCreatures += LootCommand.monsterOfTheDeeps; - lc.catfishes = 0; + LootCommand.catfishes = 0; if (statsObject.has("kills_catfish")) { - lc.catfishes = statsObject.get("kills_catfish").getAsInt(); + LootCommand.catfishes = statsObject.get("kills_catfish").getAsInt(); } - lc.seaCreatures += lc.catfishes; + LootCommand.seaCreatures += LootCommand.catfishes; - lc.carrotKings = 0; + LootCommand.carrotKings = 0; if (statsObject.has("kills_carrot_king")) { - lc.carrotKings = statsObject.get("kills_carrot_king").getAsInt(); + LootCommand.carrotKings = statsObject.get("kills_carrot_king").getAsInt(); } - lc.seaCreatures += lc.carrotKings; + LootCommand.seaCreatures += LootCommand.carrotKings; - lc.seaLeeches = 0; + LootCommand.seaLeeches = 0; if (statsObject.has("kills_sea_leech")) { - lc.seaLeeches = statsObject.get("kills_sea_leech").getAsInt(); + LootCommand.seaLeeches = statsObject.get("kills_sea_leech").getAsInt(); } - lc.seaCreatures += lc.seaLeeches; + LootCommand.seaCreatures += LootCommand.seaLeeches; - lc.guardianDefenders = 0; + LootCommand.guardianDefenders = 0; if (statsObject.has("kills_guardian_defender")) { - lc.guardianDefenders = statsObject.get("kills_guardian_defender").getAsInt(); + LootCommand.guardianDefenders = statsObject.get("kills_guardian_defender").getAsInt(); } - lc.seaCreatures += lc.guardianDefenders; + LootCommand.seaCreatures += LootCommand.guardianDefenders; - lc.deepSeaProtectors = 0; + LootCommand.deepSeaProtectors = 0; if (statsObject.has("kills_deep_sea_protector")) { - lc.deepSeaProtectors = statsObject.get("kills_deep_sea_protector").getAsInt(); + LootCommand.deepSeaProtectors = statsObject.get("kills_deep_sea_protector").getAsInt(); } - lc.seaCreatures += lc.deepSeaProtectors; + LootCommand.seaCreatures += LootCommand.deepSeaProtectors; - lc.hydras = 0; + LootCommand.hydras = 0; if (statsObject.has("kills_water_hydra")) { // Hydra splits - lc.hydras = statsObject.get("kills_water_hydra").getAsInt() / 2; + LootCommand.hydras = statsObject.get("kills_water_hydra").getAsInt() / 2; } - lc.seaCreatures += lc.hydras; + LootCommand.seaCreatures += LootCommand.hydras; - lc.seaEmperors = 0; + LootCommand.seaEmperors = 0; if (statsObject.has("kills_skeleton_emperor")) { if (statsObject.has("kills_guardian_emperor")) { - lc.seaEmperors = statsObject.get("kills_skeleton_emperor").getAsInt() + statsObject.get("kills_guardian_emperor").getAsInt(); + LootCommand.seaEmperors = statsObject.get("kills_skeleton_emperor").getAsInt() + statsObject.get("kills_guardian_emperor").getAsInt(); } else { - lc.seaEmperors = statsObject.get("kills_skeleton_emperor").getAsInt(); + LootCommand.seaEmperors = statsObject.get("kills_skeleton_emperor").getAsInt(); } } else if (statsObject.has("kills_guardian_emperor")) { - lc.seaEmperors = statsObject.get("kills_guardian_emperor").getAsInt(); + LootCommand.seaEmperors = statsObject.get("kills_guardian_emperor").getAsInt(); } - lc.seaCreatures += lc.seaEmperors; + LootCommand.seaCreatures += LootCommand.seaEmperors; - lc.fishingMilestone = 0; + LootCommand.fishingMilestone = 0; if (statsObject.has("pet_milestone_sea_creatures_killed")) { - lc.fishingMilestone = statsObject.get("pet_milestone_sea_creatures_killed").getAsInt(); + LootCommand.fishingMilestone = statsObject.get("pet_milestone_sea_creatures_killed").getAsInt(); } - lc.frozenSteves = 0; + LootCommand.frozenSteves = 0; if (statsObject.has("kills_frozen_steve")) { - lc.frozenSteves = statsObject.get("kills_frozen_steve").getAsInt(); + LootCommand.frozenSteves = statsObject.get("kills_frozen_steve").getAsInt(); } - lc.seaCreatures += lc.frozenSteves; + LootCommand.seaCreatures += LootCommand.frozenSteves; - lc.frostyTheSnowmans = 0; + LootCommand.frostyTheSnowmans = 0; if (statsObject.has("kills_frosty_the_snowman")) { - lc.frostyTheSnowmans = statsObject.get("kills_frosty_the_snowman").getAsInt(); + LootCommand.frostyTheSnowmans = statsObject.get("kills_frosty_the_snowman").getAsInt(); } - lc.seaCreatures += lc.frostyTheSnowmans; + LootCommand.seaCreatures += LootCommand.frostyTheSnowmans; - lc.grinches = 0; + LootCommand.grinches = 0; if (statsObject.has("kills_grinch")) { - lc.grinches = statsObject.get("kills_grinch").getAsInt(); + LootCommand.grinches = statsObject.get("kills_grinch").getAsInt(); } - lc.seaCreatures += lc.grinches; + LootCommand.seaCreatures += LootCommand.grinches; - lc.yetis = 0; + LootCommand.yetis = 0; if (statsObject.has("kills_yeti")) { - lc.yetis = statsObject.get("kills_yeti").getAsInt(); + LootCommand.yetis = statsObject.get("kills_yeti").getAsInt(); } - lc.seaCreatures += lc.yetis; + LootCommand.seaCreatures += LootCommand.yetis; - lc.nurseSharks = 0; + LootCommand.nurseSharks = 0; if (statsObject.has("kills_nurse_shark")) { - lc.nurseSharks = statsObject.get("kills_nurse_shark").getAsInt(); + LootCommand.nurseSharks = statsObject.get("kills_nurse_shark").getAsInt(); } - lc.seaCreatures += lc.nurseSharks; + LootCommand.seaCreatures += LootCommand.nurseSharks; - lc.blueSharks = 0; + LootCommand.blueSharks = 0; if (statsObject.has("kills_nurse_shark")) { - lc.blueSharks = statsObject.get("kills_blue_shark").getAsInt(); + LootCommand.blueSharks = statsObject.get("kills_blue_shark").getAsInt(); } - lc.seaCreatures += lc.blueSharks; + LootCommand.seaCreatures += LootCommand.blueSharks; - lc.tigerSharks = 0; + LootCommand.tigerSharks = 0; if (statsObject.has("kills_nurse_shark")) { - lc.tigerSharks = statsObject.get("kills_tiger_shark").getAsInt(); + LootCommand.tigerSharks = statsObject.get("kills_tiger_shark").getAsInt(); } - lc.seaCreatures += lc.tigerSharks; + LootCommand.seaCreatures += LootCommand.tigerSharks; - lc.greatWhiteSharks = 0; + LootCommand.greatWhiteSharks = 0; if (statsObject.has("kills_nurse_shark")) { - lc.greatWhiteSharks = statsObject.get("kills_great_white_shark").getAsInt(); + LootCommand.greatWhiteSharks = statsObject.get("kills_great_white_shark").getAsInt(); } - lc.seaCreatures += lc.greatWhiteSharks; + LootCommand.seaCreatures += LootCommand.greatWhiteSharks; - lc.scarecrows = 0; + LootCommand.scarecrows = 0; if (statsObject.has("kills_scarecrow")) { - lc.scarecrows = statsObject.get("kills_scarecrow").getAsInt(); + LootCommand.scarecrows = statsObject.get("kills_scarecrow").getAsInt(); } - lc.seaCreatures += lc.scarecrows; + LootCommand.seaCreatures += LootCommand.scarecrows; - lc.nightmares = 0; + LootCommand.nightmares = 0; if (statsObject.has("kills_nightmare")) { - lc.nightmares = statsObject.get("kills_nightmare").getAsInt(); + LootCommand.nightmares = statsObject.get("kills_nightmare").getAsInt(); } - lc.seaCreatures += lc.nightmares; + LootCommand.seaCreatures += LootCommand.nightmares; - lc.werewolfs = 0; + LootCommand.werewolfs = 0; if (statsObject.has("kills_werewolf")) { - lc.werewolfs = statsObject.get("kills_werewolf").getAsInt(); + LootCommand.werewolfs = statsObject.get("kills_werewolf").getAsInt(); } - lc.seaCreatures += lc.werewolfs; + LootCommand.seaCreatures += LootCommand.werewolfs; - lc.phantomFishers = 0; + LootCommand.phantomFishers = 0; if (statsObject.has("kills_phantom_fisherman")) { - lc.phantomFishers = statsObject.get("kills_phantom_fisherman").getAsInt(); + LootCommand.phantomFishers = statsObject.get("kills_phantom_fisherman").getAsInt(); } - lc.seaCreatures += lc.phantomFishers; + LootCommand.seaCreatures += LootCommand.phantomFishers; - lc.grimReapers = 0; + LootCommand.grimReapers = 0; if (statsObject.has("kills_grim_reaper")) { - lc.grimReapers = statsObject.get("kills_grim_reaper").getAsInt(); + LootCommand.grimReapers = statsObject.get("kills_grim_reaper").getAsInt(); } - lc.seaCreatures += lc.grimReapers; + LootCommand.seaCreatures += LootCommand.grimReapers; System.out.println("Writing to config..."); - cf.writeIntConfig("fishing", "goodCatch", lc.goodCatches); - cf.writeIntConfig("fishing", "greatCatch", lc.greatCatches); - cf.writeIntConfig("fishing", "seaCreature", lc.seaCreatures); - cf.writeIntConfig("fishing", "squid", lc.squids); - cf.writeIntConfig("fishing", "seaWalker", lc.seaWalkers); - cf.writeIntConfig("fishing", "nightSquid", lc.nightSquids); - cf.writeIntConfig("fishing", "seaGuardian", lc.seaGuardians); - cf.writeIntConfig("fishing", "seaWitch", lc.seaWitches); - cf.writeIntConfig("fishing", "seaArcher", lc.seaArchers); - cf.writeIntConfig("fishing", "monsterOfDeep", lc.monsterOfTheDeeps); - cf.writeIntConfig("fishing", "catfish", lc.catfishes); - cf.writeIntConfig("fishing", "carrotKing", lc.carrotKings); - cf.writeIntConfig("fishing", "seaLeech", lc.seaLeeches); - cf.writeIntConfig("fishing", "guardianDefender", lc.guardianDefenders); - cf.writeIntConfig("fishing", "deepSeaProtector", lc.deepSeaProtectors); - cf.writeIntConfig("fishing", "hydra", lc.hydras); - cf.writeIntConfig("fishing", "seaEmperor", lc.seaEmperors); - cf.writeIntConfig("fishing", "milestone", lc.fishingMilestone); - cf.writeIntConfig("fishing", "frozenSteve", lc.frozenSteves); - cf.writeIntConfig("fishing", "snowman", lc.frostyTheSnowmans); - cf.writeIntConfig("fishing", "grinch", lc.grinches); - cf.writeIntConfig("fishing", "yeti", lc.yetis); - cf.writeIntConfig("fishing", "nurseShark", lc.nurseSharks); - cf.writeIntConfig("fishing", "blueShark", lc.blueSharks); - cf.writeIntConfig("fishing", "tigerShark", lc.tigerSharks); - cf.writeIntConfig("fishing", "greatWhiteShark", lc.greatWhiteSharks); - cf.writeIntConfig("fishing", "scarecrow", lc.scarecrows); - cf.writeIntConfig("fishing", "nightmare", lc.nightmares); - cf.writeIntConfig("fishing", "werewolf", lc.werewolfs); - cf.writeIntConfig("fishing", "phantomFisher", lc.phantomFishers); - cf.writeIntConfig("fishing", "grimReaper", lc.grimReapers); + ConfigHandler.writeIntConfig("fishing", "goodCatch", LootCommand.goodCatches); + ConfigHandler.writeIntConfig("fishing", "greatCatch", LootCommand.greatCatches); + ConfigHandler.writeIntConfig("fishing", "seaCreature", LootCommand.seaCreatures); + ConfigHandler.writeIntConfig("fishing", "squid", LootCommand.squids); + ConfigHandler.writeIntConfig("fishing", "seaWalker", LootCommand.seaWalkers); + ConfigHandler.writeIntConfig("fishing", "nightSquid", LootCommand.nightSquids); + ConfigHandler.writeIntConfig("fishing", "seaGuardian", LootCommand.seaGuardians); + ConfigHandler.writeIntConfig("fishing", "seaWitch", LootCommand.seaWitches); + ConfigHandler.writeIntConfig("fishing", "seaArcher", LootCommand.seaArchers); + ConfigHandler.writeIntConfig("fishing", "monsterOfDeep", LootCommand.monsterOfTheDeeps); + ConfigHandler.writeIntConfig("fishing", "catfish", LootCommand.catfishes); + ConfigHandler.writeIntConfig("fishing", "carrotKing", LootCommand.carrotKings); + ConfigHandler.writeIntConfig("fishing", "seaLeech", LootCommand.seaLeeches); + ConfigHandler.writeIntConfig("fishing", "guardianDefender", LootCommand.guardianDefenders); + ConfigHandler.writeIntConfig("fishing", "deepSeaProtector", LootCommand.deepSeaProtectors); + ConfigHandler.writeIntConfig("fishing", "hydra", LootCommand.hydras); + ConfigHandler.writeIntConfig("fishing", "seaEmperor", LootCommand.seaEmperors); + ConfigHandler.writeIntConfig("fishing", "milestone", LootCommand.fishingMilestone); + ConfigHandler.writeIntConfig("fishing", "frozenSteve", LootCommand.frozenSteves); + ConfigHandler.writeIntConfig("fishing", "snowman", LootCommand.frostyTheSnowmans); + ConfigHandler.writeIntConfig("fishing", "grinch", LootCommand.grinches); + ConfigHandler.writeIntConfig("fishing", "yeti", LootCommand.yetis); + ConfigHandler.writeIntConfig("fishing", "nurseShark", LootCommand.nurseSharks); + ConfigHandler.writeIntConfig("fishing", "blueShark", LootCommand.blueSharks); + ConfigHandler.writeIntConfig("fishing", "tigerShark", LootCommand.tigerSharks); + ConfigHandler.writeIntConfig("fishing", "greatWhiteShark", LootCommand.greatWhiteSharks); + ConfigHandler.writeIntConfig("fishing", "scarecrow", LootCommand.scarecrows); + ConfigHandler.writeIntConfig("fishing", "nightmare", LootCommand.nightmares); + ConfigHandler.writeIntConfig("fishing", "werewolf", LootCommand.werewolfs); + ConfigHandler.writeIntConfig("fishing", "phantomFisher", LootCommand.phantomFishers); + ConfigHandler.writeIntConfig("fishing", "grimReaper", LootCommand.grimReapers); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Fishing stats imported.")); }).start(); diff --git a/src/main/java/me/Danker/commands/LobbySkillsCommand.java b/src/main/java/me/Danker/commands/LobbySkillsCommand.java index 696a855..679898d 100644 --- a/src/main/java/me/Danker/commands/LobbySkillsCommand.java +++ b/src/main/java/me/Danker/commands/LobbySkillsCommand.java @@ -46,13 +46,10 @@ public class LobbySkillsCommand extends CommandBase { @Override public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { EntityPlayer playerSP = (EntityPlayer) arg0; - ConfigHandler cf = new ConfigHandler(); - APIHandler ah = new APIHandler(); - boolean someErrored = false; Map unsortedSAList = new HashMap(); ArrayList lobbySkills = new ArrayList(); // Check key - String key = cf.getString("api", "APIKey"); + String key = ConfigHandler.getString("api", "APIKey"); if (key.equals("")) { playerSP.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "API key not set. Use /setkey.")); return; @@ -72,7 +69,7 @@ public class LobbySkillsCommand extends CommandBase { long biggestLastSave = 0; int profileIndex = -1; Thread.sleep(600); - JsonObject profileResponse = ah.getResponse("https://api.hypixel.net/skyblock/profiles?uuid=" + UUID + "&key=" + key); + JsonObject profileResponse = APIHandler.getResponse("https://api.hypixel.net/skyblock/profiles?uuid=" + UUID + "&key=" + key); if (!profileResponse.get("success").getAsBoolean()) { String reason = profileResponse.get("cause").getAsString(); System.out.println("User " + player.getGameProfile().getName() + " failed with reason: " + reason); @@ -138,7 +135,7 @@ public class LobbySkillsCommand extends CommandBase { } else { Thread.sleep(600); // Sleep for another request System.out.println("Fetching skills from achievement API"); - JsonObject playerObject = ah.getResponse("https://api.hypixel.net/player?uuid=" + UUID + "&key=" + key); + JsonObject playerObject = APIHandler.getResponse("https://api.hypixel.net/player?uuid=" + UUID + "&key=" + key); if (!playerObject.get("success").getAsBoolean()) { String reason = profileResponse.get("cause").getAsString(); diff --git a/src/main/java/me/Danker/commands/MoveCommand.java b/src/main/java/me/Danker/commands/MoveCommand.java index a3f5e3b..0581d8c 100644 --- a/src/main/java/me/Danker/commands/MoveCommand.java +++ b/src/main/java/me/Danker/commands/MoveCommand.java @@ -10,7 +10,6 @@ import net.minecraft.command.ICommandSender; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.BlockPos; import net.minecraft.util.ChatComponentText; -import net.minecraft.util.EnumChatFormatting; public class MoveCommand extends CommandBase { @@ -47,7 +46,6 @@ public class MoveCommand extends CommandBase { @Override public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { final EntityPlayer player = (EntityPlayer)arg0; - final ConfigHandler cf = new ConfigHandler(); if (arg1.length < 2) { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); @@ -57,38 +55,38 @@ public class MoveCommand extends CommandBase { if (arg1[0].equalsIgnoreCase("coords")) { coordsXY[0] = Integer.parseInt(arg1[1]); coordsXY[1] = Integer.parseInt(arg1[2]); - cf.writeIntConfig("locations", "coordsX", coordsXY[0]); - cf.writeIntConfig("locations", "coordsY", coordsXY[1]); + ConfigHandler.writeIntConfig("locations", "coordsX", coordsXY[0]); + ConfigHandler.writeIntConfig("locations", "coordsY", coordsXY[1]); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Coords have been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); } else if (arg1[0].equalsIgnoreCase("display")) { displayXY[0] = Integer.parseInt(arg1[1]); displayXY[1] = Integer.parseInt(arg1[2]); - cf.writeIntConfig("locations", "displayX", displayXY[0]); - cf.writeIntConfig("locations", "displayY", displayXY[1]); + ConfigHandler.writeIntConfig("locations", "displayX", displayXY[0]); + ConfigHandler.writeIntConfig("locations", "displayY", displayXY[1]); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Tracker display has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); } else if (arg1[0].equalsIgnoreCase("dungeontimer")) { dungeonTimerXY[0] = Integer.parseInt(arg1[1]); dungeonTimerXY[1] = Integer.parseInt(arg1[2]); - cf.writeIntConfig("locations", "dungeonTimerX", dungeonTimerXY[0]); - cf.writeIntConfig("locations", "dungeonTimerY", dungeonTimerXY[1]); + ConfigHandler.writeIntConfig("locations", "dungeonTimerX", dungeonTimerXY[0]); + ConfigHandler.writeIntConfig("locations", "dungeonTimerY", dungeonTimerXY[1]); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Dungeon timer has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); } else if (arg1[0].equalsIgnoreCase("skill50")) { skill50XY[0] = Integer.parseInt(arg1[1]); skill50XY[1] = Integer.parseInt(arg1[2]); - cf.writeIntConfig("locations", "skill50X", skill50XY[0]); - cf.writeIntConfig("locations", "skill50Y", skill50XY[1]); + ConfigHandler.writeIntConfig("locations", "skill50X", skill50XY[0]); + ConfigHandler.writeIntConfig("locations", "skill50Y", skill50XY[1]); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill 50 display has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); } else if (arg1[0].equalsIgnoreCase("lividhp")) { lividHpXY[0] = Integer.parseInt(arg1[1]); lividHpXY[1] = Integer.parseInt(arg1[2]); - cf.writeIntConfig("locations", "lividHpX", lividHpXY[0]); - cf.writeIntConfig("locations", "lividHpY", lividHpXY[1]); + ConfigHandler.writeIntConfig("locations", "lividHpX", lividHpXY[0]); + ConfigHandler.writeIntConfig("locations", "lividHpY", lividHpXY[1]); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Livid HP has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); } else if (arg1[0].equalsIgnoreCase("caketimer")) { cakeTimerXY[0] = Integer.parseInt(arg1[1]); cakeTimerXY[1] = Integer.parseInt(arg1[2]); - cf.writeIntConfig("locations", "cakeTimerX", cakeTimerXY[0]); - cf.writeIntConfig("locations", "cakeTimerY", cakeTimerXY[1]); + ConfigHandler.writeIntConfig("locations", "cakeTimerX", cakeTimerXY[0]); + ConfigHandler.writeIntConfig("locations", "cakeTimerY", cakeTimerXY[1]); } else { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); } diff --git a/src/main/java/me/Danker/commands/PetsCommand.java b/src/main/java/me/Danker/commands/PetsCommand.java index 031d087..8e41814 100644 --- a/src/main/java/me/Danker/commands/PetsCommand.java +++ b/src/main/java/me/Danker/commands/PetsCommand.java @@ -79,12 +79,10 @@ public class PetsCommand extends CommandBase { public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { // MULTI THREAD DRIFTING new Thread(() -> { - APIHandler ah = new APIHandler(); - ConfigHandler cf = new ConfigHandler(); EntityPlayer player = (EntityPlayer) arg0; // Check key - String key = cf.getString("api", "APIKey"); + String key = ConfigHandler.getString("api", "APIKey"); if (key.equals("")) { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "API key not set. Use /setkey.")); } @@ -99,16 +97,16 @@ public class PetsCommand extends CommandBase { } else { username = arg1[0]; player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Checking pets of " + TheMod.SECONDARY_COLOUR + username)); - uuid = ah.getUUID(username); + uuid = APIHandler.getUUID(username); } // Find stats of latest profile - String latestProfile = ah.getLatestProfileID(uuid, key); + String latestProfile = APIHandler.getLatestProfileID(uuid, key); if (latestProfile == null) return; String profileURL = "https://api.hypixel.net/skyblock/profile?profile=" + latestProfile + "&key=" + key; System.out.println("Fetching profile..."); - JsonObject profileResponse = ah.getResponse(profileURL); + JsonObject profileResponse = APIHandler.getResponse(profileURL); if (!profileResponse.get("success").getAsBoolean()) { String reason = profileResponse.get("cause").getAsString(); player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Failed with reason: " + reason)); diff --git a/src/main/java/me/Danker/commands/ReloadConfigCommand.java b/src/main/java/me/Danker/commands/ReloadConfigCommand.java index 113bbc4..c4ad036 100644 --- a/src/main/java/me/Danker/commands/ReloadConfigCommand.java +++ b/src/main/java/me/Danker/commands/ReloadConfigCommand.java @@ -7,7 +7,6 @@ import net.minecraft.command.CommandException; import net.minecraft.command.ICommandSender; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.ChatComponentText; -import net.minecraft.util.EnumChatFormatting; public class ReloadConfigCommand extends CommandBase { @@ -29,8 +28,7 @@ public class ReloadConfigCommand extends CommandBase { @Override public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { final EntityPlayer player = (EntityPlayer)arg0; - final ConfigHandler cf = new ConfigHandler(); - cf.reloadConfig(); + ConfigHandler.reloadConfig(); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Reloaded config.")); } diff --git a/src/main/java/me/Danker/commands/ResetLootCommand.java b/src/main/java/me/Danker/commands/ResetLootCommand.java index 0c33866..f99b5ae 100644 --- a/src/main/java/me/Danker/commands/ResetLootCommand.java +++ b/src/main/java/me/Danker/commands/ResetLootCommand.java @@ -90,154 +90,142 @@ public class ResetLootCommand extends CommandBase { } } - static void resetZombie() { - LootCommand lc = new LootCommand(); - ConfigHandler cf = new ConfigHandler(); - - lc.zombieRevsSession = 0; - lc.zombieRevFleshSession = 0; - lc.zombieFoulFleshSession = 0; - lc.zombieFoulFleshDropsSession = 0; - lc.zombiePestilencesSession = 0; - lc.zombieUndeadCatasSession = 0; - lc.zombieBooksSession = 0; - lc.zombieBeheadedsSession = 0; - lc.zombieRevCatasSession = 0; - lc.zombieSnakesSession = 0; - lc.zombieScythesSession = 0; - lc.zombieTimeSession = -1; - lc.zombieBossesSession = -1; - cf.deleteCategory("zombie"); - cf.reloadConfig(); + static void resetZombie() { + LootCommand.zombieRevsSession = 0; + LootCommand.zombieRevFleshSession = 0; + LootCommand.zombieFoulFleshSession = 0; + LootCommand.zombieFoulFleshDropsSession = 0; + LootCommand.zombiePestilencesSession = 0; + LootCommand.zombieUndeadCatasSession = 0; + LootCommand.zombieBooksSession = 0; + LootCommand.zombieBeheadedsSession = 0; + LootCommand.zombieRevCatasSession = 0; + LootCommand.zombieSnakesSession = 0; + LootCommand.zombieScythesSession = 0; + LootCommand.zombieTimeSession = -1; + LootCommand.zombieBossesSession = -1; + ConfigHandler.deleteCategory("zombie"); + ConfigHandler.reloadConfig(); } static void resetSpider() { - LootCommand lc = new LootCommand(); - ConfigHandler cf = new ConfigHandler(); - - lc.spiderTarantulasSession = 0; - lc.spiderWebsSession = 0; - lc.spiderTAPSession = 0; - lc.spiderTAPDropsSession = 0; - lc.spiderBitesSession = 0; - lc.spiderCatalystsSession = 0; - lc.spiderBooksSession = 0; - lc.spiderSwattersSession = 0; - lc.spiderTalismansSession = 0; - lc.spiderMosquitosSession = 0; - lc.spiderTimeSession = -1; - lc.spiderBossesSession = -1; - cf.deleteCategory("spider"); - cf.reloadConfig(); + LootCommand.spiderTarantulasSession = 0; + LootCommand.spiderWebsSession = 0; + LootCommand.spiderTAPSession = 0; + LootCommand.spiderTAPDropsSession = 0; + LootCommand.spiderBitesSession = 0; + LootCommand.spiderCatalystsSession = 0; + LootCommand.spiderBooksSession = 0; + LootCommand.spiderSwattersSession = 0; + LootCommand.spiderTalismansSession = 0; + LootCommand.spiderMosquitosSession = 0; + LootCommand.spiderTimeSession = -1; + LootCommand.spiderBossesSession = -1; + ConfigHandler.deleteCategory("spider"); + ConfigHandler.reloadConfig(); } static void resetWolf() { - LootCommand lc = new LootCommand(); - ConfigHandler cf = new ConfigHandler(); - lc.wolfSvensSession = 0; - lc.wolfTeethSession = 0; - lc.wolfWheelsSession = 0; - lc.wolfWheelsDropsSession = 0; - lc.wolfSpiritsSession = 0; - lc.wolfBooksSession = 0; - lc.wolfEggsSession = 0; - lc.wolfCouturesSession = 0; - lc.wolfBaitsSession = 0; - lc.wolfFluxesSession = 0; - lc.wolfTimeSession = -1; - lc.wolfBossesSession = -1; - cf.deleteCategory("wolf"); - cf.reloadConfig(); + LootCommand.wolfSvensSession = 0; + LootCommand.wolfTeethSession = 0; + LootCommand.wolfWheelsSession = 0; + LootCommand.wolfWheelsDropsSession = 0; + LootCommand.wolfSpiritsSession = 0; + LootCommand.wolfBooksSession = 0; + LootCommand.wolfEggsSession = 0; + LootCommand.wolfCouturesSession = 0; + LootCommand.wolfBaitsSession = 0; + LootCommand.wolfFluxesSession = 0; + LootCommand.wolfTimeSession = -1; + LootCommand.wolfBossesSession = -1; + ConfigHandler.deleteCategory("wolf"); + ConfigHandler.reloadConfig(); } static void resetFishing() { - LootCommand lc = new LootCommand(); - ConfigHandler cf = new ConfigHandler(); - lc.seaCreaturesSession = 0; - lc.goodCatchesSession = 0; - lc.greatCatchesSession = 0; - lc.squidsSession = 0; - lc.seaWalkersSession = 0; - lc.nightSquidsSession = 0; - lc.seaGuardiansSession = 0; - lc.seaWitchesSession = 0; - lc.seaArchersSession = 0; - lc.monsterOfTheDeepsSession = 0; - lc.catfishesSession = 0; - lc.carrotKingsSession = 0; - lc.seaLeechesSession = 0; - lc.guardianDefendersSession = 0; - lc.deepSeaProtectorsSession = 0; - lc.hydrasSession = 0; - lc.seaEmperorsSession = 0; - lc.empTimeSession = -1; - lc.empSCsSession = -1; - lc.fishingMilestoneSession = 0; - lc.frozenStevesSession = 0; - lc.frostyTheSnowmansSession = 0; - lc.grinchesSession = 0; - lc.yetisSession = 0; - lc.yetiTimeSession = -1; - lc.yetiSCsSession = -1; - lc.nurseSharksSession = 0; - lc.blueSharksSession = 0; - lc.tigerSharksSession = 0; - lc.greatWhiteSharksSession = 0; - lc.scarecrowsSession = 0; - lc.nightmaresSession = 0; - lc.werewolfsSession = 0; - lc.phantomFishersSession = 0; - lc.grimReapersSession = 0; - cf.deleteCategory("fishing"); - cf.reloadConfig(); + LootCommand.seaCreaturesSession = 0; + LootCommand.goodCatchesSession = 0; + LootCommand.greatCatchesSession = 0; + LootCommand.squidsSession = 0; + LootCommand.seaWalkersSession = 0; + LootCommand.nightSquidsSession = 0; + LootCommand.seaGuardiansSession = 0; + LootCommand.seaWitchesSession = 0; + LootCommand.seaArchersSession = 0; + LootCommand.monsterOfTheDeepsSession = 0; + LootCommand.catfishesSession = 0; + LootCommand.carrotKingsSession = 0; + LootCommand.seaLeechesSession = 0; + LootCommand.guardianDefendersSession = 0; + LootCommand.deepSeaProtectorsSession = 0; + LootCommand.hydrasSession = 0; + LootCommand.seaEmperorsSession = 0; + LootCommand.empTimeSession = -1; + LootCommand.empSCsSession = -1; + LootCommand.fishingMilestoneSession = 0; + LootCommand.frozenStevesSession = 0; + LootCommand.frostyTheSnowmansSession = 0; + LootCommand.grinchesSession = 0; + LootCommand.yetisSession = 0; + LootCommand.yetiTimeSession = -1; + LootCommand.yetiSCsSession = -1; + LootCommand.nurseSharksSession = 0; + LootCommand.blueSharksSession = 0; + LootCommand.tigerSharksSession = 0; + LootCommand.greatWhiteSharksSession = 0; + LootCommand.scarecrowsSession = 0; + LootCommand.nightmaresSession = 0; + LootCommand.werewolfsSession = 0; + LootCommand.phantomFishersSession = 0; + LootCommand.grimReapersSession = 0; + ConfigHandler.deleteCategory("fishing"); + ConfigHandler.reloadConfig(); } static void resetCatacombs() { - LootCommand lc = new LootCommand(); - ConfigHandler cf = new ConfigHandler(); - lc.recombobulatorsSession = 0; - lc.fumingPotatoBooksSession = 0; - lc.bonzoStaffsSession = 0; - lc.f1CoinsSpentSession = 0; - lc.f1TimeSpentSession = 0; - lc.scarfStudiesSession = 0; - lc.f2CoinsSpentSession = 0; - lc.f2TimeSpentSession = 0; - lc.adaptiveHelmsSession = 0; - lc.adaptiveChestsSession = 0; - lc.adaptiveLegsSession = 0; - lc.adaptiveBootsSession = 0; - lc.adaptiveSwordsSession = 0; - lc.f3CoinsSpentSession = 0; - lc.f3TimeSpentSession = 0; - lc.spiritWingsSession = 0; - lc.spiritBonesSession = 0; - lc.spiritBootsSession = 0; - lc.spiritSwordsSession = 0; - lc.epicSpiritPetsSession = 0; - lc.f4CoinsSpentSession = 0; - lc.f4TimeSpentSession = 0; - lc.warpedStonesSession = 0; - lc.shadowAssHelmsSession = 0; - lc.shadowAssChestsSession = 0; - lc.shadowAssLegsSession = 0; - lc.shadowAssBootsSession = 0; - lc.lividDaggersSession = 0; - lc.shadowFurysSession = 0; - lc.f5CoinsSpentSession = 0; - lc.f5TimeSpentSession = 0; - lc.ancientRosesSession = 0; - lc.precursorEyesSession = 0; - lc.giantsSwordsSession = 0; - lc.necroLordHelmsSession = 0; - lc.necroLordChestsSession = 0; - lc.necroLordLegsSession = 0; - lc.necroLordBootsSession = 0; - lc.necroSwordsSession = 0; - lc.f6CoinsSpentSession = 0; - lc.f6TimeSpentSession = 0; - cf.deleteCategory("catacombs"); - cf.reloadConfig(); + LootCommand.recombobulatorsSession = 0; + LootCommand.fumingPotatoBooksSession = 0; + LootCommand.bonzoStaffsSession = 0; + LootCommand.f1CoinsSpentSession = 0; + LootCommand.f1TimeSpentSession = 0; + LootCommand.scarfStudiesSession = 0; + LootCommand.f2CoinsSpentSession = 0; + LootCommand.f2TimeSpentSession = 0; + LootCommand.adaptiveHelmsSession = 0; + LootCommand.adaptiveChestsSession = 0; + LootCommand.adaptiveLegsSession = 0; + LootCommand.adaptiveBootsSession = 0; + LootCommand.adaptiveSwordsSession = 0; + LootCommand.f3CoinsSpentSession = 0; + LootCommand.f3TimeSpentSession = 0; + LootCommand.spiritWingsSession = 0; + LootCommand.spiritBonesSession = 0; + LootCommand.spiritBootsSession = 0; + LootCommand.spiritSwordsSession = 0; + LootCommand.epicSpiritPetsSession = 0; + LootCommand.f4CoinsSpentSession = 0; + LootCommand.f4TimeSpentSession = 0; + LootCommand.warpedStonesSession = 0; + LootCommand.shadowAssHelmsSession = 0; + LootCommand.shadowAssChestsSession = 0; + LootCommand.shadowAssLegsSession = 0; + LootCommand.shadowAssBootsSession = 0; + LootCommand.lividDaggersSession = 0; + LootCommand.shadowFurysSession = 0; + LootCommand.f5CoinsSpentSession = 0; + LootCommand.f5TimeSpentSession = 0; + LootCommand.ancientRosesSession = 0; + LootCommand.precursorEyesSession = 0; + LootCommand.giantsSwordsSession = 0; + LootCommand.necroLordHelmsSession = 0; + LootCommand.necroLordChestsSession = 0; + LootCommand.necroLordLegsSession = 0; + LootCommand.necroLordBootsSession = 0; + LootCommand.necroSwordsSession = 0; + LootCommand.f6CoinsSpentSession = 0; + LootCommand.f6TimeSpentSession = 0; + ConfigHandler.deleteCategory("catacombs"); + ConfigHandler.reloadConfig(); } } diff --git a/src/main/java/me/Danker/commands/ScaleCommand.java b/src/main/java/me/Danker/commands/ScaleCommand.java index fa4c51d..1527e40 100644 --- a/src/main/java/me/Danker/commands/ScaleCommand.java +++ b/src/main/java/me/Danker/commands/ScaleCommand.java @@ -10,7 +10,6 @@ import net.minecraft.command.ICommandSender; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.BlockPos; import net.minecraft.util.ChatComponentText; -import net.minecraft.util.EnumChatFormatting; public class ScaleCommand extends CommandBase { diff --git a/src/main/java/me/Danker/commands/SetkeyCommand.java b/src/main/java/me/Danker/commands/SetkeyCommand.java index 9ad1abe..f2e58e5 100644 --- a/src/main/java/me/Danker/commands/SetkeyCommand.java +++ b/src/main/java/me/Danker/commands/SetkeyCommand.java @@ -8,7 +8,6 @@ import net.minecraft.command.ICommand; import net.minecraft.command.ICommandSender; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.ChatComponentText; -import net.minecraft.util.EnumChatFormatting; public class SetkeyCommand extends CommandBase implements ICommand { @@ -36,8 +35,7 @@ public class SetkeyCommand extends CommandBase implements ICommand { return; } - final ConfigHandler cf = new ConfigHandler(); - cf.writeStringConfig("api", "APIKey", arg1[0]); + ConfigHandler.writeStringConfig("api", "APIKey", arg1[0]); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Set API key to " + TheMod.SECONDARY_COLOUR + arg1[0])); } diff --git a/src/main/java/me/Danker/commands/SkillsCommand.java b/src/main/java/me/Danker/commands/SkillsCommand.java index 12bfd93..71905fc 100644 --- a/src/main/java/me/Danker/commands/SkillsCommand.java +++ b/src/main/java/me/Danker/commands/SkillsCommand.java @@ -45,12 +45,10 @@ public class SkillsCommand extends CommandBase { public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { // MULTI THREAD DRIFTING new Thread(() -> { - APIHandler ah = new APIHandler(); - ConfigHandler cf = new ConfigHandler(); EntityPlayer player = (EntityPlayer) arg0; // Check key - String key = cf.getString("api", "APIKey"); + String key = ConfigHandler.getString("api", "APIKey"); if (key.equals("")) { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "API key not set. Use /setkey.")); } @@ -65,16 +63,16 @@ public class SkillsCommand extends CommandBase { } else { username = arg1[0]; player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Checking skills of " + TheMod.SECONDARY_COLOUR + username)); - uuid = ah.getUUID(username); + uuid = APIHandler.getUUID(username); } // Find stats of latest profile - String latestProfile = ah.getLatestProfileID(uuid, key); + String latestProfile = APIHandler.getLatestProfileID(uuid, key); if (latestProfile == null) return; String profileURL = "https://api.hypixel.net/skyblock/profile?profile=" + latestProfile + "&key=" + key; System.out.println("Fetching profile..."); - JsonObject profileResponse = ah.getResponse(profileURL); + JsonObject profileResponse = APIHandler.getResponse(profileURL); if (!profileResponse.get("success").getAsBoolean()) { String reason = profileResponse.get("cause").getAsString(); player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Failed with reason: " + reason)); @@ -131,7 +129,7 @@ public class SkillsCommand extends CommandBase { String playerURL = "https://api.hypixel.net/player?uuid=" + uuid + "&key=" + key; System.out.println("Fetching skills from achievement API"); - JsonObject playerObject = ah.getResponse(playerURL); + JsonObject playerObject = APIHandler.getResponse(playerURL); if (!playerObject.get("success").getAsBoolean()) { String reason = profileResponse.get("cause").getAsString(); diff --git a/src/main/java/me/Danker/commands/SkyblockPlayersCommand.java b/src/main/java/me/Danker/commands/SkyblockPlayersCommand.java index 24c3152..aca61ee 100644 --- a/src/main/java/me/Danker/commands/SkyblockPlayersCommand.java +++ b/src/main/java/me/Danker/commands/SkyblockPlayersCommand.java @@ -44,19 +44,17 @@ public class SkyblockPlayersCommand extends CommandBase { public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { // MULTI THREAD DRIFTING new Thread(() -> { - APIHandler ah = new APIHandler(); - ConfigHandler cf = new ConfigHandler(); EntityPlayer player = (EntityPlayer) arg0; // Check key - String key = cf.getString("api", "APIKey"); + String key = ConfigHandler.getString("api", "APIKey"); if (key.equals("")) { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "API key not set. Use /setkey.")); } String playersURL = "https://api.hypixel.net/gameCounts?key=" + key; System.out.println("Fetching player count..."); - JsonObject playersResponse = ah.getResponse(playersURL); + JsonObject playersResponse = APIHandler.getResponse(playersURL); if (!playersResponse.get("success").getAsBoolean()) { String reason = playersResponse.get("cause").getAsString(); player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Failed with reason: " + reason)); diff --git a/src/main/java/me/Danker/commands/SlayerCommand.java b/src/main/java/me/Danker/commands/SlayerCommand.java index 3ac6a46..07119bb 100644 --- a/src/main/java/me/Danker/commands/SlayerCommand.java +++ b/src/main/java/me/Danker/commands/SlayerCommand.java @@ -47,12 +47,10 @@ public class SlayerCommand extends CommandBase { public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { // MULTI THREAD DRIFTING new Thread(() -> { - APIHandler ah = new APIHandler(); - ConfigHandler cf = new ConfigHandler(); EntityPlayer player = (EntityPlayer) arg0; // Check key - String key = cf.getString("api", "APIKey"); + String key = ConfigHandler.getString("api", "APIKey"); if (key.equals("")) { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "API key not set. Use /setkey.")); } @@ -67,16 +65,16 @@ public class SlayerCommand extends CommandBase { } else { username = arg1[0]; player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Checking slayer of " + TheMod.SECONDARY_COLOUR + username)); - uuid = ah.getUUID(username); + uuid = APIHandler.getUUID(username); } // Find stats of latest profile - String latestProfile = ah.getLatestProfileID(uuid, key); + String latestProfile = APIHandler.getLatestProfileID(uuid, key); if (latestProfile == null) return; String profileURL = "https://api.hypixel.net/skyblock/profile?profile=" + latestProfile + "&key=" + key; System.out.println("Fetching profile..."); - JsonObject profileResponse = ah.getResponse(profileURL); + JsonObject profileResponse = APIHandler.getResponse(profileURL); if (!profileResponse.get("success").getAsBoolean()) { String reason = profileResponse.get("cause").getAsString(); player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Failed with reason: " + reason)); diff --git a/src/main/java/me/Danker/commands/ToggleCommand.java b/src/main/java/me/Danker/commands/ToggleCommand.java index 563c403..93cce26 100644 --- a/src/main/java/me/Danker/commands/ToggleCommand.java +++ b/src/main/java/me/Danker/commands/ToggleCommand.java @@ -11,7 +11,6 @@ import net.minecraft.command.ICommandSender; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.BlockPos; import net.minecraft.util.ChatComponentText; -import net.minecraft.util.EnumChatFormatting; public class ToggleCommand extends CommandBase implements ICommand { public static boolean gpartyToggled; @@ -76,7 +75,6 @@ public class ToggleCommand extends CommandBase implements ICommand { @Override public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { final EntityPlayer player = (EntityPlayer)arg0; - final ConfigHandler cf = new ConfigHandler(); if (arg1.length == 0) { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); @@ -85,107 +83,107 @@ public class ToggleCommand extends CommandBase implements ICommand { if (arg1[0].equalsIgnoreCase("gparty")) { gpartyToggled = !gpartyToggled; - cf.writeBooleanConfig("toggles", "GParty", gpartyToggled); + ConfigHandler.writeBooleanConfig("toggles", "GParty", gpartyToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Guild party notifications has been set to " + TheMod.SECONDARY_COLOUR + gpartyToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("coords")) { coordsToggled = !coordsToggled; - cf.writeBooleanConfig("toggles", "Coords", coordsToggled); + ConfigHandler.writeBooleanConfig("toggles", "Coords", coordsToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Coord/Angle display has been set to " + TheMod.SECONDARY_COLOUR + coordsToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("golden")) { goldenToggled = !goldenToggled; - cf.writeBooleanConfig("toggles", "Golden", goldenToggled); + ConfigHandler.writeBooleanConfig("toggles", "Golden", goldenToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Golden T6 enchants has been set to " + TheMod.SECONDARY_COLOUR + goldenToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("slayercount")) { slayerCountTotal = !slayerCountTotal; - cf.writeBooleanConfig("toggles", "SlayerCount", slayerCountTotal); + ConfigHandler.writeBooleanConfig("toggles", "SlayerCount", slayerCountTotal); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Counting total 20% slayer drops has been set to " + TheMod.SECONDARY_COLOUR + slayerCountTotal + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("rngesusalerts")) { rngesusAlerts = !rngesusAlerts; - cf.writeBooleanConfig("toggles", "RNGesusAlerts", rngesusAlerts); + ConfigHandler.writeBooleanConfig("toggles", "RNGesusAlerts", rngesusAlerts); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Slayer RNGesus alerts has been set to " + TheMod.SECONDARY_COLOUR + rngesusAlerts + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("splitfishing")) { splitFishing = !splitFishing; - cf.writeBooleanConfig("toggles", "SplitFishing", splitFishing); + ConfigHandler.writeBooleanConfig("toggles", "SplitFishing", splitFishing); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Split fishing display has been set to " + TheMod.SECONDARY_COLOUR + splitFishing + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("chatmaddox")) { chatMaddoxToggled = !chatMaddoxToggled; - cf.writeBooleanConfig("toggles", "ChatMaddox", chatMaddoxToggled); + ConfigHandler.writeBooleanConfig("toggles", "ChatMaddox", chatMaddoxToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Click screen to open Maddox menu has been set to " + TheMod.SECONDARY_COLOUR + chatMaddoxToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("spiritbearalerts")) { spiritBearAlerts = !spiritBearAlerts; - cf.writeBooleanConfig("toggles", "SpiritBearAlerts", spiritBearAlerts); + ConfigHandler.writeBooleanConfig("toggles", "SpiritBearAlerts", spiritBearAlerts); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Spirit Bear alerts have been set to " + TheMod.SECONDARY_COLOUR + spiritBearAlerts + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("aotd")) { aotdToggled = !aotdToggled; - cf.writeBooleanConfig("toggles", "AOTD", aotdToggled); + ConfigHandler.writeBooleanConfig("toggles", "AOTD", aotdToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Block AOTD ability been set to " + TheMod.SECONDARY_COLOUR + aotdToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("lividdagger")) { lividDaggerToggled = !lividDaggerToggled; - cf.writeBooleanConfig("toggles", "LividDagger", lividDaggerToggled); + ConfigHandler.writeBooleanConfig("toggles", "LividDagger", lividDaggerToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Block Livid Dagger ability been set to " + TheMod.SECONDARY_COLOUR + lividDaggerToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("sceptremessages")) { sceptreMessages = !sceptreMessages; - cf.writeBooleanConfig("toggles", "SceptreMessages", sceptreMessages); + ConfigHandler.writeBooleanConfig("toggles", "SceptreMessages", sceptreMessages); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Spirit Sceptre messages have been set to " + TheMod.SECONDARY_COLOUR + sceptreMessages + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("petcolors") || arg1[0].equalsIgnoreCase("petcolours")) { petColoursToggled = !petColoursToggled; - cf.writeBooleanConfig("toggles", "PetColors", petColoursToggled); + ConfigHandler.writeBooleanConfig("toggles", "PetColors", petColoursToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Pet colours have been set to " + TheMod.SECONDARY_COLOUR + petColoursToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("dungeontimer")) { dungeonTimerToggled = !dungeonTimerToggled; - cf.writeBooleanConfig("toggles", "DungeonTimer", dungeonTimerToggled); + ConfigHandler.writeBooleanConfig("toggles", "DungeonTimer", dungeonTimerToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Dungeon timer has been set to " + TheMod.SECONDARY_COLOUR + dungeonTimerToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("golemalerts")) { golemAlertToggled = !golemAlertToggled; - cf.writeBooleanConfig("toggles", "GolemAlerts", golemAlertToggled); + ConfigHandler.writeBooleanConfig("toggles", "GolemAlerts", golemAlertToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Golem spawn alerts has been set to " + TheMod.SECONDARY_COLOUR + golemAlertToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("expertiselore")) { expertiseLoreToggled = !expertiseLoreToggled; - cf.writeBooleanConfig("toggles", "ExpertiseLore", expertiseLoreToggled); + ConfigHandler.writeBooleanConfig("toggles", "ExpertiseLore", expertiseLoreToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Expertise in lore has been set to " + TheMod.SECONDARY_COLOUR + expertiseLoreToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("skill50display")) { skill50DisplayToggled = !skill50DisplayToggled; - cf.writeBooleanConfig("toggles", "Skill50Display", skill50DisplayToggled); + ConfigHandler.writeBooleanConfig("toggles", "Skill50Display", skill50DisplayToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill 50 display has been set to " + TheMod.SECONDARY_COLOUR + skill50DisplayToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("outlinetext")) { outlineTextToggled = !outlineTextToggled; - cf.writeBooleanConfig("toggles", "OutlineText", outlineTextToggled); + ConfigHandler.writeBooleanConfig("toggles", "OutlineText", outlineTextToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Outline displayed text has been set to " + TheMod.SECONDARY_COLOUR + outlineTextToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("midasstaffmessages")) { midasStaffMessages = !midasStaffMessages; - cf.writeBooleanConfig("toggles", "MidasStaffMessages", midasStaffMessages); + ConfigHandler.writeBooleanConfig("toggles", "MidasStaffMessages", midasStaffMessages); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Midas Staff messages have been set to " + TheMod.SECONDARY_COLOUR + midasStaffMessages + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("healmessages")) { healMessages = !healMessages; - cf.writeBooleanConfig("toggles", "HealMessages", healMessages); + ConfigHandler.writeBooleanConfig("toggles", "HealMessages", healMessages); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Heal messages have been set to " + TheMod.SECONDARY_COLOUR + healMessages + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("caketimer")) { cakeTimerToggled = !cakeTimerToggled; - cf.writeBooleanConfig("toggles", "CakeTimer", cakeTimerToggled); + ConfigHandler.writeBooleanConfig("toggles", "CakeTimer", cakeTimerToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Cake timer has been set to " + TheMod.SECONDARY_COLOUR + cakeTimerToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("lividsolver")) { lividSolverToggled = !lividSolverToggled; - cf.writeBooleanConfig("toggles", "LividSolver", lividSolverToggled); + ConfigHandler.writeBooleanConfig("toggles", "LividSolver", lividSolverToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Livid solver has been set to " + TheMod.SECONDARY_COLOUR + lividSolverToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("threemanpuzzle")) { threeManToggled = !threeManToggled; - cf.writeBooleanConfig("toggles", "ThreeManPuzzle", threeManToggled); + ConfigHandler.writeBooleanConfig("toggles", "ThreeManPuzzle", threeManToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Three man puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + threeManToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("oruopuzzle")) { oruoToggled = !oruoToggled; - cf.writeBooleanConfig("toggles", "OruoPuzzle", oruoToggled); + ConfigHandler.writeBooleanConfig("toggles", "OruoPuzzle", oruoToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Oruo trivia solver has been set to " + TheMod.SECONDARY_COLOUR + oruoToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("blazepuzzle")) { blazeToggled = !blazeToggled; - cf.writeBooleanConfig("toggles", "BlazePuzzle", blazeToggled); + ConfigHandler.writeBooleanConfig("toggles", "BlazePuzzle", blazeToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Blaze puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + blazeToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("creeperpuzzle")) { creeperToggled = !creeperToggled; - cf.writeBooleanConfig("creeperpuzzle", "CreeperPuzzle", creeperToggled); + ConfigHandler.writeBooleanConfig("creeperpuzzle", "CreeperPuzzle", creeperToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Creeper puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + creeperToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("waterpuzzle")) { waterToggled = !waterToggled; - cf.writeBooleanConfig("waterpuzzle", "WaterPuzzle", waterToggled); + ConfigHandler.writeBooleanConfig("waterpuzzle", "WaterPuzzle", waterToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Water puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + waterToggled + TheMod.MAIN_COLOUR + ".")); } else if (arg1[0].equalsIgnoreCase("list")) { player.addChatMessage(new ChatComponentText(TheMod.TYPE_COLOUR + "Guild party notifications: " + TheMod.VALUE_COLOUR + gpartyToggled + "\n" + diff --git a/src/main/java/me/Danker/gui/DankerGui.java b/src/main/java/me/Danker/gui/DankerGui.java index 8667461..73db9f0 100644 --- a/src/main/java/me/Danker/gui/DankerGui.java +++ b/src/main/java/me/Danker/gui/DankerGui.java @@ -12,7 +12,6 @@ import me.Danker.handlers.TextRenderer; import me.Danker.utils.Utils; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiButton; -import net.minecraft.client.gui.GuiConfirmOpenLink; import net.minecraft.client.gui.GuiScreen; import net.minecraft.client.gui.ScaledResolution; diff --git a/src/main/java/me/Danker/gui/EditLocationsGui.java b/src/main/java/me/Danker/gui/EditLocationsGui.java index d8034e6..7e67c1e 100644 --- a/src/main/java/me/Danker/gui/EditLocationsGui.java +++ b/src/main/java/me/Danker/gui/EditLocationsGui.java @@ -34,9 +34,6 @@ public class EditLocationsGui extends GuiScreen { @Override public void initGui() { super.initGui(); - // Ease of typing - MoveCommand moc = new MoveCommand(); - ScaleCommand sc = new ScaleCommand(); String displayText = EnumChatFormatting.GOLD + "Svens Killed:\n" + EnumChatFormatting.GREEN + "Wolf Teeth:\n" + @@ -74,12 +71,12 @@ public class EditLocationsGui extends GuiScreen { EnumChatFormatting.YELLOW + 2 + "\n" + EnumChatFormatting.YELLOW + 1; - display = new LocationButton(0, moc.displayXY[0], moc.displayXY[1], 145 * sc.displayScale, 102 * sc.displayScale, sc.displayScale, displayText, displayNums, 110); - dungeonTimer = new LocationButton(0, moc.dungeonTimerXY[0], moc.dungeonTimerXY[1], 113 * sc.dungeonTimerScale, 57 * sc.dungeonTimerScale, sc.dungeonTimerScale, dungeonTimerText, dungeonTimerNums, 80); - coords = new LocationButton(0, moc.coordsXY[0], moc.coordsXY[1], 141 * sc.coordsScale, 12 * sc.coordsScale, sc.coordsScale, TheMod.COORDS_COLOUR + "74 / 14 / -26 (141.1 / 6.7)", null, null); - skill50 = new LocationButton(0, moc.skill50XY[0], moc.skill50XY[1], 233 * sc.skill50Scale, 12 * sc.skill50Scale, sc.skill50Scale, TheMod.SKILL_50_COLOUR + "+3.5 Farming (28,882,117.7/55,172,425) 52.34%", null, null); - lividHP = new LocationButton(0, moc.lividHpXY[0], moc.lividHpXY[1], 85 * sc.lividHpScale, 12 * sc.lividHpScale, sc.lividHpScale, EnumChatFormatting.WHITE + "﴾ Livid " + EnumChatFormatting.YELLOW + "6.9M" + EnumChatFormatting.RED + "❤ " + EnumChatFormatting.WHITE + "﴿", null, null); - cakeTimer = new LocationButton(0, moc.cakeTimerXY[0], moc.cakeTimerXY[1] + 5, 85 * sc.cakeTimerScale, 18 * sc.cakeTimerScale, sc.cakeTimerScale, TheMod.CAKE_COLOUR + " 11h16m", null, null); + display = new LocationButton(0, MoveCommand.displayXY[0], MoveCommand.displayXY[1], 145 * ScaleCommand.displayScale, 102 * ScaleCommand.displayScale, ScaleCommand.displayScale, displayText, displayNums, 110); + dungeonTimer = new LocationButton(0, MoveCommand.dungeonTimerXY[0], MoveCommand.dungeonTimerXY[1], 113 * ScaleCommand.dungeonTimerScale, 57 * ScaleCommand.dungeonTimerScale, ScaleCommand.dungeonTimerScale, dungeonTimerText, dungeonTimerNums, 80); + coords = new LocationButton(0, MoveCommand.coordsXY[0], MoveCommand.coordsXY[1], 141 * ScaleCommand.coordsScale, 12 * ScaleCommand.coordsScale, ScaleCommand.coordsScale, TheMod.COORDS_COLOUR + "74 / 14 / -26 (141.1 / 6.7)", null, null); + skill50 = new LocationButton(0, MoveCommand.skill50XY[0], MoveCommand.skill50XY[1], 233 * ScaleCommand.skill50Scale, 12 * ScaleCommand.skill50Scale, ScaleCommand.skill50Scale, TheMod.SKILL_50_COLOUR + "+3.5 Farming (28,882,117.7/55,172,425) 52.34%", null, null); + lividHP = new LocationButton(0, MoveCommand.lividHpXY[0], MoveCommand.lividHpXY[1], 85 * ScaleCommand.lividHpScale, 12 * ScaleCommand.lividHpScale, ScaleCommand.lividHpScale, EnumChatFormatting.WHITE + "﴾ Livid " + EnumChatFormatting.YELLOW + "6.9M" + EnumChatFormatting.RED + "❤ " + EnumChatFormatting.WHITE + "﴿", null, null); + cakeTimer = new LocationButton(0, MoveCommand.cakeTimerXY[0], MoveCommand.cakeTimerXY[1] + 5, 85 * ScaleCommand.cakeTimerScale, 18 * ScaleCommand.cakeTimerScale, ScaleCommand.cakeTimerScale, TheMod.CAKE_COLOUR + " 11h16m", null, null); this.buttonList.add(coords); this.buttonList.add(dungeonTimer); diff --git a/src/main/java/me/Danker/handlers/APIHandler.java b/src/main/java/me/Danker/handlers/APIHandler.java index 6d1df32..c96aa50 100644 --- a/src/main/java/me/Danker/handlers/APIHandler.java +++ b/src/main/java/me/Danker/handlers/APIHandler.java @@ -18,7 +18,6 @@ import me.Danker.TheMod; import net.minecraft.client.Minecraft; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.ChatComponentText; -import net.minecraft.util.EnumChatFormatting; public class APIHandler { public static JsonObject getResponse(String urlString) { diff --git a/src/main/java/me/Danker/handlers/ConfigHandler.java b/src/main/java/me/Danker/handlers/ConfigHandler.java index 5a59308..08a78c4 100644 --- a/src/main/java/me/Danker/handlers/ConfigHandler.java +++ b/src/main/java/me/Danker/handlers/ConfigHandler.java @@ -374,203 +374,198 @@ public class ConfigHandler { if (!hasKey("colors", "coordsDisplay")) writeStringConfig("colors", "coordsDisplay", "" + EnumChatFormatting.WHITE); if (!hasKey("colors", "cakeDisplay")) writeStringConfig("colors", "cakeDisplay", "" + EnumChatFormatting.GOLD); - final ToggleCommand tf = new ToggleCommand(); - tf.gpartyToggled = getBoolean("toggles", "GParty"); - tf.coordsToggled = getBoolean("toggles", "Coords"); - tf.goldenToggled = getBoolean("toggles", "Golden"); - tf.slayerCountTotal = getBoolean("toggles", "SlayerCount"); - tf.rngesusAlerts = getBoolean("toggles", "RNGesusAlerts"); - tf.splitFishing = getBoolean("toggles", "SplitFishing"); - tf.chatMaddoxToggled = getBoolean("toggles", "ChatMaddox"); - tf.spiritBearAlerts = getBoolean("toggles", "SpiritBearAlerts"); - tf.aotdToggled = getBoolean("toggles", "AOTD"); - tf.lividDaggerToggled = getBoolean("toggles", "LividDagger"); - tf.sceptreMessages = getBoolean("toggles", "SceptreMessages"); - tf.petColoursToggled = getBoolean("toggles", "PetColors"); - tf.dungeonTimerToggled = getBoolean("toggles", "DungeonTimer"); - tf.golemAlertToggled = getBoolean("toggles", "GolemAlerts"); - tf.expertiseLoreToggled = getBoolean("toggles", "ExpertiseLore"); - tf.skill50DisplayToggled = getBoolean("toggles", "Skill50Display"); - tf.outlineTextToggled = getBoolean("toggles", "OutlineText"); - tf.midasStaffMessages = getBoolean("toggles", "MidasStaffMessages"); - tf.healMessages = getBoolean("toggles", "HealMessages"); - tf.cakeTimerToggled = getBoolean("toggles", "CakeTimer"); - tf.lividSolverToggled = getBoolean("toggles", "LividSolver"); + ToggleCommand.gpartyToggled = getBoolean("toggles", "GParty"); + ToggleCommand.coordsToggled = getBoolean("toggles", "Coords"); + ToggleCommand.goldenToggled = getBoolean("toggles", "Golden"); + ToggleCommand.slayerCountTotal = getBoolean("toggles", "SlayerCount"); + ToggleCommand.rngesusAlerts = getBoolean("toggles", "RNGesusAlerts"); + ToggleCommand.splitFishing = getBoolean("toggles", "SplitFishing"); + ToggleCommand.chatMaddoxToggled = getBoolean("toggles", "ChatMaddox"); + ToggleCommand.spiritBearAlerts = getBoolean("toggles", "SpiritBearAlerts"); + ToggleCommand.aotdToggled = getBoolean("toggles", "AOTD"); + ToggleCommand.lividDaggerToggled = getBoolean("toggles", "LividDagger"); + ToggleCommand.sceptreMessages = getBoolean("toggles", "SceptreMessages"); + ToggleCommand.petColoursToggled = getBoolean("toggles", "PetColors"); + ToggleCommand.dungeonTimerToggled = getBoolean("toggles", "DungeonTimer"); + ToggleCommand.golemAlertToggled = getBoolean("toggles", "GolemAlerts"); + ToggleCommand.expertiseLoreToggled = getBoolean("toggles", "ExpertiseLore"); + ToggleCommand.skill50DisplayToggled = getBoolean("toggles", "Skill50Display"); + ToggleCommand.outlineTextToggled = getBoolean("toggles", "OutlineText"); + ToggleCommand.midasStaffMessages = getBoolean("toggles", "MidasStaffMessages"); + ToggleCommand.healMessages = getBoolean("toggles", "HealMessages"); + ToggleCommand.cakeTimerToggled = getBoolean("toggles", "CakeTimer"); + ToggleCommand.lividSolverToggled = getBoolean("toggles", "LividSolver"); // Puzzle Solvers - tf.threeManToggled = getBoolean("toggles", "ThreeManPuzzle"); - tf.oruoToggled = getBoolean("toggles", "OruoPuzzle"); - tf.blazeToggled = getBoolean("toggles", "BlazePuzzle"); - tf.creeperToggled = getBoolean("toggles", "CreeperPuzzle"); - tf.waterToggled = getBoolean("toggles", "WaterPuzzle"); + ToggleCommand.threeManToggled = getBoolean("toggles", "ThreeManPuzzle"); + ToggleCommand.oruoToggled = getBoolean("toggles", "OruoPuzzle"); + ToggleCommand.blazeToggled = getBoolean("toggles", "BlazePuzzle"); + ToggleCommand.creeperToggled = getBoolean("toggles", "CreeperPuzzle"); + ToggleCommand.waterToggled = getBoolean("toggles", "WaterPuzzle"); - final BlockSlayerCommand bs = new BlockSlayerCommand(); String onlySlayer = getString("toggles", "BlockSlayer"); if (!onlySlayer.equals("")) { - bs.onlySlayerName = onlySlayer.substring(0, onlySlayer.lastIndexOf(" ")); - bs.onlySlayerNumber = onlySlayer.substring(onlySlayer.lastIndexOf(" ") + 1, onlySlayer.length()); + BlockSlayerCommand.onlySlayerName = onlySlayer.substring(0, onlySlayer.lastIndexOf(" ")); + BlockSlayerCommand.onlySlayerNumber = onlySlayer.substring(onlySlayer.lastIndexOf(" ") + 1, onlySlayer.length()); } - final LootCommand lc = new LootCommand(); // Wolf - lc.wolfSvens = getInt("wolf", "svens"); - lc.wolfTeeth = getInt("wolf", "teeth"); - lc.wolfWheels = getInt("wolf", "wheel"); - lc.wolfWheelsDrops = getInt("wolf", "wheelDrops"); - lc.wolfSpirits = getInt("wolf", "spirit"); - lc.wolfBooks = getInt("wolf", "book"); - lc.wolfEggs = getInt("wolf", "egg"); - lc.wolfCoutures = getInt("wolf", "couture"); - lc.wolfBaits = getInt("wolf", "bait"); - lc.wolfFluxes = getInt("wolf", "flux"); - lc.wolfTime = getDouble("wolf", "timeRNG"); - lc.wolfBosses = getInt("wolf", "bossRNG"); + LootCommand.wolfSvens = getInt("wolf", "svens"); + LootCommand.wolfTeeth = getInt("wolf", "teeth"); + LootCommand.wolfWheels = getInt("wolf", "wheel"); + LootCommand.wolfWheelsDrops = getInt("wolf", "wheelDrops"); + LootCommand.wolfSpirits = getInt("wolf", "spirit"); + LootCommand.wolfBooks = getInt("wolf", "book"); + LootCommand.wolfEggs = getInt("wolf", "egg"); + LootCommand.wolfCoutures = getInt("wolf", "couture"); + LootCommand.wolfBaits = getInt("wolf", "bait"); + LootCommand.wolfFluxes = getInt("wolf", "flux"); + LootCommand.wolfTime = getDouble("wolf", "timeRNG"); + LootCommand.wolfBosses = getInt("wolf", "bossRNG"); // Spider - lc.spiderTarantulas = getInt("spider", "tarantulas"); - lc.spiderWebs = getInt("spider", "web"); - lc.spiderTAP = getInt("spider", "tap"); - lc.spiderTAPDrops = getInt("spider", "tapDrops"); - lc.spiderBites = getInt("spider", "bite"); - lc.spiderCatalysts = getInt("spider", "catalyst"); - lc.spiderBooks = getInt("spider", "book"); - lc.spiderSwatters = getInt("spider", "swatter"); - lc.spiderTalismans = getInt("spider", "talisman"); - lc.spiderMosquitos = getInt("spider", "mosquito"); - lc.spiderTime = getDouble("spider", "timeRNG"); - lc.spiderBosses = getInt("spider", "bossRNG"); + LootCommand.spiderTarantulas = getInt("spider", "tarantulas"); + LootCommand.spiderWebs = getInt("spider", "web"); + LootCommand.spiderTAP = getInt("spider", "tap"); + LootCommand.spiderTAPDrops = getInt("spider", "tapDrops"); + LootCommand.spiderBites = getInt("spider", "bite"); + LootCommand.spiderCatalysts = getInt("spider", "catalyst"); + LootCommand.spiderBooks = getInt("spider", "book"); + LootCommand.spiderSwatters = getInt("spider", "swatter"); + LootCommand.spiderTalismans = getInt("spider", "talisman"); + LootCommand.spiderMosquitos = getInt("spider", "mosquito"); + LootCommand.spiderTime = getDouble("spider", "timeRNG"); + LootCommand.spiderBosses = getInt("spider", "bossRNG"); // Zombie - lc.zombieRevs = getInt("zombie", "revs"); - lc.zombieRevFlesh = getInt("zombie", "revFlesh"); - lc.zombieFoulFlesh = getInt("zombie", "foulFlesh"); - lc.zombieFoulFleshDrops = getInt("zombie", "foulFleshDrops"); - lc.zombiePestilences = getInt("zombie", "pestilence"); - lc.zombieUndeadCatas = getInt("zombie", "undeadCatalyst"); - lc.zombieBooks = getInt("zombie", "book"); - lc.zombieBeheadeds = getInt("zombie", "beheaded"); - lc.zombieRevCatas = getInt("zombie", "revCatalyst"); - lc.zombieSnakes = getInt("zombie", "snake"); - lc.zombieScythes = getInt("zombie", "scythe"); - lc.zombieTime = getDouble("zombie", "timeRNG"); - lc.zombieBosses = getInt("zombie", "bossRNG"); + LootCommand.zombieRevs = getInt("zombie", "revs"); + LootCommand.zombieRevFlesh = getInt("zombie", "revFlesh"); + LootCommand.zombieFoulFlesh = getInt("zombie", "foulFlesh"); + LootCommand.zombieFoulFleshDrops = getInt("zombie", "foulFleshDrops"); + LootCommand.zombiePestilences = getInt("zombie", "pestilence"); + LootCommand.zombieUndeadCatas = getInt("zombie", "undeadCatalyst"); + LootCommand.zombieBooks = getInt("zombie", "book"); + LootCommand.zombieBeheadeds = getInt("zombie", "beheaded"); + LootCommand.zombieRevCatas = getInt("zombie", "revCatalyst"); + LootCommand.zombieSnakes = getInt("zombie", "snake"); + LootCommand.zombieScythes = getInt("zombie", "scythe"); + LootCommand.zombieTime = getDouble("zombie", "timeRNG"); + LootCommand.zombieBosses = getInt("zombie", "bossRNG"); // Fishing - lc.seaCreatures = getInt("fishing", "seaCreature"); - lc.goodCatches = getInt("fishing", "goodCatch"); - lc.greatCatches = getInt("fishing", "greatCatch"); - lc.squids = getInt("fishing", "squid"); - lc.seaWalkers = getInt("fishing", "seaWalker"); - lc.nightSquids = getInt("fishing", "nightSquid"); - lc.seaGuardians = getInt("fishing", "seaGuardian"); - lc.seaWitches = getInt("fishing", "seaWitch"); - lc.seaArchers = getInt("fishing", "seaArcher"); - lc.monsterOfTheDeeps = getInt("fishing", "monsterOfDeep"); - lc.catfishes = getInt("fishing", "catfish"); - lc.carrotKings = getInt("fishing", "carrotKing"); - lc.seaLeeches = getInt("fishing", "seaLeech"); - lc.guardianDefenders = getInt("fishing", "guardianDefender"); - lc.deepSeaProtectors = getInt("fishing", "deepSeaProtector"); - lc.hydras = getInt("fishing", "hydra"); - lc.seaEmperors = getInt("fishing", "seaEmperor"); - lc.empTime = getDouble("fishing", "empTime"); - lc.empSCs = getInt("fishing", "empSC"); - lc.fishingMilestone = getInt("fishing", "milestone"); + LootCommand.seaCreatures = getInt("fishing", "seaCreature"); + LootCommand.goodCatches = getInt("fishing", "goodCatch"); + LootCommand.greatCatches = getInt("fishing", "greatCatch"); + LootCommand.squids = getInt("fishing", "squid"); + LootCommand.seaWalkers = getInt("fishing", "seaWalker"); + LootCommand.nightSquids = getInt("fishing", "nightSquid"); + LootCommand.seaGuardians = getInt("fishing", "seaGuardian"); + LootCommand.seaWitches = getInt("fishing", "seaWitch"); + LootCommand.seaArchers = getInt("fishing", "seaArcher"); + LootCommand.monsterOfTheDeeps = getInt("fishing", "monsterOfDeep"); + LootCommand.catfishes = getInt("fishing", "catfish"); + LootCommand.carrotKings = getInt("fishing", "carrotKing"); + LootCommand.seaLeeches = getInt("fishing", "seaLeech"); + LootCommand.guardianDefenders = getInt("fishing", "guardianDefender"); + LootCommand.deepSeaProtectors = getInt("fishing", "deepSeaProtector"); + LootCommand.hydras = getInt("fishing", "hydra"); + LootCommand.seaEmperors = getInt("fishing", "seaEmperor"); + LootCommand.empTime = getDouble("fishing", "empTime"); + LootCommand.empSCs = getInt("fishing", "empSC"); + LootCommand.fishingMilestone = getInt("fishing", "milestone"); // Fishing Winter - lc.frozenSteves = getInt("fishing", "frozenSteve"); - lc.frostyTheSnowmans = getInt("fishing", "snowman"); - lc.grinches = getInt("fishing", "grinch"); - lc.yetis = getInt("fishing", "yeti"); - lc.yetiTime = getDouble("fishing", "yetiTime"); - lc.yetiSCs = getInt("fishing", "yetiSC"); + LootCommand.frozenSteves = getInt("fishing", "frozenSteve"); + LootCommand.frostyTheSnowmans = getInt("fishing", "snowman"); + LootCommand.grinches = getInt("fishing", "grinch"); + LootCommand.yetis = getInt("fishing", "yeti"); + LootCommand.yetiTime = getDouble("fishing", "yetiTime"); + LootCommand.yetiSCs = getInt("fishing", "yetiSC"); // Fishing Festival - lc.nurseSharks = getInt("fishing", "nurseShark"); - lc.blueSharks = getInt("fishing", "blueShark"); - lc.tigerSharks = getInt("fishing", "tigerShark"); - lc.greatWhiteSharks = getInt("fishing", "greatWhiteShark"); + LootCommand.nurseSharks = getInt("fishing", "nurseShark"); + LootCommand.blueSharks = getInt("fishing", "blueShark"); + LootCommand.tigerSharks = getInt("fishing", "tigerShark"); + LootCommand.greatWhiteSharks = getInt("fishing", "greatWhiteShark"); // Spooky Fishing - lc.scarecrows = getInt("fishing", "scarecrow"); - lc.nightmares = getInt("fishing", "nightmare"); - lc.werewolfs = getInt("fishing", "nightmare"); - lc.phantomFishers = getInt("fishing", "phantomFisher"); - lc.grimReapers = getInt("fishing", "grimReaper"); + LootCommand.scarecrows = getInt("fishing", "scarecrow"); + LootCommand.nightmares = getInt("fishing", "nightmare"); + LootCommand.werewolfs = getInt("fishing", "nightmare"); + LootCommand.phantomFishers = getInt("fishing", "phantomFisher"); + LootCommand.grimReapers = getInt("fishing", "grimReaper"); // Dungeons - lc.recombobulators = getInt("catacombs", "recombobulator"); - lc.fumingPotatoBooks = getInt("catacombs", "fumingBooks"); + LootCommand.recombobulators = getInt("catacombs", "recombobulator"); + LootCommand.fumingPotatoBooks = getInt("catacombs", "fumingBooks"); // F1 - lc.bonzoStaffs = getInt("catacombs", "bonzoStaff"); - lc.f1CoinsSpent = getDouble("catacombs", "floorOneCoins"); - lc.f1TimeSpent = getDouble("catacombs", "floorOneTime"); + LootCommand.bonzoStaffs = getInt("catacombs", "bonzoStaff"); + LootCommand.f1CoinsSpent = getDouble("catacombs", "floorOneCoins"); + LootCommand.f1TimeSpent = getDouble("catacombs", "floorOneTime"); // F2 - lc.scarfStudies = getInt("catacombs", "scarfStudies"); - lc.f2CoinsSpent = getDouble("catacombs", "floorTwoCoins"); - lc.f2TimeSpent = getDouble("catacombs", "floorTwoTime"); + LootCommand.scarfStudies = getInt("catacombs", "scarfStudies"); + LootCommand.f2CoinsSpent = getDouble("catacombs", "floorTwoCoins"); + LootCommand.f2TimeSpent = getDouble("catacombs", "floorTwoTime"); // F3 - lc.adaptiveHelms = getInt("catacombs", "adaptiveHelm"); - lc.adaptiveChests = getInt("catacombs", "adaptiveChest"); - lc.adaptiveLegs = getInt("catacombs", "adaptiveLegging"); - lc.adaptiveBoots = getInt("catacombs", "adaptiveBoot"); - lc.adaptiveSwords = getInt("catacombs", "adaptiveSword"); - lc.f3CoinsSpent = getDouble("catacombs", "floorThreeCoins"); - lc.f3TimeSpent = getDouble("catacombs", "floorThreeTime"); + LootCommand.adaptiveHelms = getInt("catacombs", "adaptiveHelm"); + LootCommand.adaptiveChests = getInt("catacombs", "adaptiveChest"); + LootCommand.adaptiveLegs = getInt("catacombs", "adaptiveLegging"); + LootCommand.adaptiveBoots = getInt("catacombs", "adaptiveBoot"); + LootCommand.adaptiveSwords = getInt("catacombs", "adaptiveSword"); + LootCommand.f3CoinsSpent = getDouble("catacombs", "floorThreeCoins"); + LootCommand.f3TimeSpent = getDouble("catacombs", "floorThreeTime"); // F4 - lc.spiritWings = getInt("catacombs", "spiritWing"); - lc.spiritBones = getInt("catacombs", "spiritBone"); - lc.spiritBoots = getInt("catacombs", "spiritBoot"); - lc.spiritSwords = getInt("catacombs", "spiritSword"); - lc.spiritBows = getInt("catacombs", "spiritBow"); - lc.epicSpiritPets = getInt("catacombs", "spiritPetEpic"); - lc.legSpiritPets = getInt("catacombs", "spiritPetLeg"); - lc.f4CoinsSpent = getDouble("catacombs", "floorFourCoins"); - lc.f4TimeSpent = getDouble("catacombs", "floorFourTime"); + LootCommand.spiritWings = getInt("catacombs", "spiritWing"); + LootCommand.spiritBones = getInt("catacombs", "spiritBone"); + LootCommand.spiritBoots = getInt("catacombs", "spiritBoot"); + LootCommand.spiritSwords = getInt("catacombs", "spiritSword"); + LootCommand.spiritBows = getInt("catacombs", "spiritBow"); + LootCommand.epicSpiritPets = getInt("catacombs", "spiritPetEpic"); + LootCommand.legSpiritPets = getInt("catacombs", "spiritPetLeg"); + LootCommand.f4CoinsSpent = getDouble("catacombs", "floorFourCoins"); + LootCommand.f4TimeSpent = getDouble("catacombs", "floorFourTime"); // F5 - lc.warpedStones = getInt("catacombs", "warpedStone"); - lc.shadowAssHelms = getInt("catacombs", "shadowAssassinHelm"); - lc.shadowAssChests = getInt("catacombs", "shadowAssassinChest"); - lc.shadowAssLegs = getInt("catacombs", "shadowAssassinLegging"); - lc.shadowAssBoots = getInt("catacombs", "shadowAssassinBoot"); - lc.lastBreaths = getInt("catacombs", "lastBreath"); - lc.lividDaggers = getInt("catacombs", "lividDagger"); - lc.shadowFurys = getInt("catacombs", "shadowFury"); - lc.f5CoinsSpent = getDouble("catacombs", "floorFiveCoins"); - lc.f5TimeSpent = getDouble("catacombs", "floorFiveTime"); + LootCommand.warpedStones = getInt("catacombs", "warpedStone"); + LootCommand.shadowAssHelms = getInt("catacombs", "shadowAssassinHelm"); + LootCommand.shadowAssChests = getInt("catacombs", "shadowAssassinChest"); + LootCommand.shadowAssLegs = getInt("catacombs", "shadowAssassinLegging"); + LootCommand.shadowAssBoots = getInt("catacombs", "shadowAssassinBoot"); + LootCommand.lastBreaths = getInt("catacombs", "lastBreath"); + LootCommand.lividDaggers = getInt("catacombs", "lividDagger"); + LootCommand.shadowFurys = getInt("catacombs", "shadowFury"); + LootCommand.f5CoinsSpent = getDouble("catacombs", "floorFiveCoins"); + LootCommand.f5TimeSpent = getDouble("catacombs", "floorFiveTime"); // F6 - lc.ancientRoses = getInt("catacombs", "ancientRose"); - lc.precursorEyes = getInt("catacombs", "precursorEye"); - lc.giantsSwords = getInt("catacombs", "giantsSword"); - lc.necroLordHelms = getInt("catacombs", "necroLordHelm"); - lc.necroLordChests = getInt("catacombs", "necroLordChest"); - lc.necroLordLegs = getInt("catacombs", "necroLordLegging"); - lc.necroLordBoots = getInt("catacombs", "necroLordBoot"); - lc.necroSwords = getInt("catacombs", "necroSword"); - lc.f6CoinsSpent = getDouble("catacombs", "floorSixCoins"); - lc.f6TimeSpent = getDouble("catacombs", "floorSixTime"); + LootCommand.ancientRoses = getInt("catacombs", "ancientRose"); + LootCommand.precursorEyes = getInt("catacombs", "precursorEye"); + LootCommand.giantsSwords = getInt("catacombs", "giantsSword"); + LootCommand.necroLordHelms = getInt("catacombs", "necroLordHelm"); + LootCommand.necroLordChests = getInt("catacombs", "necroLordChest"); + LootCommand.necroLordLegs = getInt("catacombs", "necroLordLegging"); + LootCommand.necroLordBoots = getInt("catacombs", "necroLordBoot"); + LootCommand.necroSwords = getInt("catacombs", "necroSword"); + LootCommand.f6CoinsSpent = getDouble("catacombs", "floorSixCoins"); + LootCommand.f6TimeSpent = getDouble("catacombs", "floorSixTime"); - final DisplayCommand ds = new DisplayCommand(); - ds.display = getString("misc", "display"); - ds.auto = getBoolean("misc", "autoDisplay"); + // Misc + DisplayCommand.display = getString("misc", "display"); + DisplayCommand.auto = getBoolean("misc", "autoDisplay"); TheMod.SKILL_TIME = getInt("misc", "skill50Time") * 20; TheMod.cakeTime = getDouble("misc", "cakeTime"); - final MoveCommand moc = new MoveCommand(); - moc.coordsXY[0] = getInt("locations", "coordsX"); - moc.coordsXY[1] = getInt("locations", "coordsY"); - moc.displayXY[0] = getInt("locations", "displayX"); - moc.displayXY[1] = getInt("locations", "displayY"); - moc.dungeonTimerXY[0] = getInt("locations", "dungeonTimerX"); - moc.dungeonTimerXY[1] = getInt("locations", "dungeonTimerY"); - moc.skill50XY[0] = getInt("locations", "skill50X"); - moc.skill50XY[1] = getInt("locations", "skill50Y"); - moc.lividHpXY[0] = getInt("locations", "lividHpX"); - moc.lividHpXY[1] = getInt("locations", "lividHpY"); - moc.cakeTimerXY[0] = getInt("locations", "cakeTimerX"); - moc.cakeTimerXY[1] = getInt("locations", "cakeTimerY"); + MoveCommand.coordsXY[0] = getInt("locations", "coordsX"); + MoveCommand.coordsXY[1] = getInt("locations", "coordsY"); + MoveCommand.displayXY[0] = getInt("locations", "displayX"); + MoveCommand.displayXY[1] = getInt("locations", "displayY"); + MoveCommand.dungeonTimerXY[0] = getInt("locations", "dungeonTimerX"); + MoveCommand.dungeonTimerXY[1] = getInt("locations", "dungeonTimerY"); + MoveCommand.skill50XY[0] = getInt("locations", "skill50X"); + MoveCommand.skill50XY[1] = getInt("locations", "skill50Y"); + MoveCommand.lividHpXY[0] = getInt("locations", "lividHpX"); + MoveCommand.lividHpXY[1] = getInt("locations", "lividHpY"); + MoveCommand.cakeTimerXY[0] = getInt("locations", "cakeTimerX"); + MoveCommand.cakeTimerXY[1] = getInt("locations", "cakeTimerY"); - final ScaleCommand sc = new ScaleCommand(); - sc.coordsScale = getDouble("scales", "coordsScale"); - sc.displayScale = getDouble("scales", "displayScale"); - sc.dungeonTimerScale = getDouble("scales", "dungeonTimerScale"); - sc.skill50Scale = getDouble("scales", "skill50Scale"); - sc.lividHpScale = getDouble("scales", "lividHpScale"); - sc.cakeTimerScale = getDouble("scales", "cakeTimerScale"); + ScaleCommand.coordsScale = getDouble("scales", "coordsScale"); + ScaleCommand.displayScale = getDouble("scales", "displayScale"); + ScaleCommand.dungeonTimerScale = getDouble("scales", "dungeonTimerScale"); + ScaleCommand.skill50Scale = getDouble("scales", "skill50Scale"); + ScaleCommand.lividHpScale = getDouble("scales", "lividHpScale"); + ScaleCommand.cakeTimerScale = getDouble("scales", "cakeTimerScale"); TheMod.MAIN_COLOUR = getString("colors", "main"); TheMod.SECONDARY_COLOUR = getString("colors", "secondary"); -- cgit From b89d16855374a3e75c4c1279226d23d923821084 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Sun, 22 Nov 2020 19:19:35 -0500 Subject: Add F7 tracker --- README.md | 4 +- src/main/java/me/Danker/TheMod.java | 98 ++++++++++++++++++++++ src/main/java/me/Danker/commands/DHelpCommand.java | 4 +- .../java/me/Danker/commands/DisplayCommand.java | 10 ++- src/main/java/me/Danker/commands/LootCommand.java | 68 ++++++++++++++- .../java/me/Danker/commands/ResetLootCommand.java | 12 +++ src/main/java/me/Danker/gui/DisplayGui.java | 17 ++-- .../java/me/Danker/handlers/ConfigHandler.java | 26 ++++++ 8 files changed, 225 insertions(+), 14 deletions(-) (limited to 'src/main/java/me/Danker/gui') diff --git a/README.md b/README.md index ab69c1e..7a5369b 100644 --- a/README.md +++ b/README.md @@ -39,8 +39,8 @@ Discord Server: https://discord.gg/QsEkNQS - /toggle - Toggles features. /toggle list returns values of every toggle. - /setkey - Sets API key. - /getkey - Returns key set with /setkey and copies it to your clipboard. -- /loot [winter/spooky/f(1-6)/session] - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead. -- /display [winter/spooky/f(1-6)/session] - Text display for trackers. /display fishing winter displays winter sea creatures instead. /display auto automatically displays the loot for the slayer quest you have active. +- /loot [winter/spooky/f(1-7)/session] - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead. +- /display [winter/spooky/f(1-7)/session] - Text display for trackers. /display fishing winter displays winter sea creatures instead. /display auto automatically displays the loot for the slayer quest you have active. - /resetloot - - Resets loot for trackers. /resetloot confirm confirms the reset. - /move - Moves text display to specified X and Y coordinates. - /scale - Scales text display to a specified multipler between 0.1x and 10x. diff --git a/src/main/java/me/Danker/TheMod.java b/src/main/java/me/Danker/TheMod.java index 8cb1203..9478d6c 100644 --- a/src/main/java/me/Danker/TheMod.java +++ b/src/main/java/me/Danker/TheMod.java @@ -814,6 +814,10 @@ public class TheMod LootCommand.f6TimeSpent = Math.floor(LootCommand.f6TimeSpent + timeToAdd); LootCommand.f6TimeSpentSession = Math.floor(LootCommand.f6TimeSpentSession + timeToAdd); ConfigHandler.writeDoubleConfig("catacombs", "floorSixTime", LootCommand.f6TimeSpent); + } else if (sCleaned.contains("F7")) { + LootCommand.f7TimeSpent = Math.floor(LootCommand.f7TimeSpent + timeToAdd); + LootCommand.f7TimeSpentSession = Math.floor(LootCommand.f7TimeSpentSession + timeToAdd); + ConfigHandler.writeDoubleConfig("catacombs", "floorSevenTime", LootCommand.f7TimeSpent); } } else if (sCleaned.contains("Time Elapsed:")) { // Get floor time @@ -981,6 +985,36 @@ public class TheMod LootCommand.necroSwords++; LootCommand.necroSwordsSession++; ConfigHandler.writeIntConfig("catacombs", "necroSword", LootCommand.necroSwords); + } else if (message.contains("Wither Blood")) { // F7 + LootCommand.witherBloods++; + LootCommand.witherBloodsSession++; + } else if (message.contains("Wither Cloak")) { + LootCommand.witherCloaks++; + LootCommand.witherCloaksSession++; + } else if (message.contains("Implosion")) { + LootCommand.implosions++; + LootCommand.implosionsSession++; + } else if (message.contains("Wither Shield")) { + LootCommand.witherShields++; + LootCommand.witherShieldsSession++; + } else if (message.contains("Shadow Warp")) { + LootCommand.shadowWarps++; + LootCommand.shadowWarpsSession++; + } else if (message.contains("Auto Recombobulator")) { + LootCommand.autoRecombs++; + LootCommand.autoRecombsSession++; + } else if (message.contains("Wither Helmet")) { + LootCommand.witherHelms++; + LootCommand.witherHelmsSession++; + } else if (message.contains("Wither Chestplate")) { + LootCommand.witherChests++; + LootCommand.witherChestsSession++; + } else if (message.contains("Wither Leggings")) { + LootCommand.witherLegs++; + LootCommand.witherLegsSession++; + } else if (message.contains("Wither Boots")) { + LootCommand.witherBoots++; + LootCommand.witherBootsSession++; } } @@ -1808,6 +1842,64 @@ public class TheMod EnumChatFormatting.GOLD + nf.format(LootCommand.necroSwordsSession) + "\n" + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f6CoinsSpentSession) + "\n" + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f6TimeSpentSession); + } else if (DisplayCommand.display.equals("catacombs_floor_seven")) { + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.DARK_PURPLE + "Wither Bloods:\n" + + EnumChatFormatting.DARK_PURPLE + "Wither Cloaks:\n" + + EnumChatFormatting.DARK_PURPLE + "Implosions:\n" + + EnumChatFormatting.DARK_PURPLE + "Wither Shields:\n" + + EnumChatFormatting.DARK_PURPLE + "Shadow Warps:\n" + + EnumChatFormatting.GOLD + "Auto Recombobs:\n" + + EnumChatFormatting.GOLD + "Wither Helmets:\n" + + EnumChatFormatting.GOLD + "Wither Chests:\n" + + EnumChatFormatting.GOLD + "Wither Leggings:\n" + + EnumChatFormatting.GOLD + "Wither Boots:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherBloods) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherCloaks) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.implosions) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherShields) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowWarps) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.autoRecombs) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherHelms) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherChests) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherLegs) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherBoots) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f7CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f7TimeSpent); + } else if (DisplayCommand.display.equals("catacombs_floor_seven_session")) { + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.DARK_PURPLE + "Wither Bloods:\n" + + EnumChatFormatting.DARK_PURPLE + "Wither Cloaks:\n" + + EnumChatFormatting.DARK_PURPLE + "Implosions:\n" + + EnumChatFormatting.DARK_PURPLE + "Wither Shields:\n" + + EnumChatFormatting.DARK_PURPLE + "Shadow Warps:\n" + + EnumChatFormatting.GOLD + "Auto Recombobulators:\n" + + EnumChatFormatting.GOLD + "Wither Helmets:\n" + + EnumChatFormatting.GOLD + "Wither Chests:\n" + + EnumChatFormatting.GOLD + "Wither Leggings:\n" + + EnumChatFormatting.GOLD + "Wither Boots:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherBloodsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherCloaksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.implosionsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherShieldsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowWarpsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.autoRecombsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherHelmsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherChestsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherLegsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherBootsSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f7CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f7TimeSpentSession); } else { System.out.println("Display was an unknown value, turning off."); DisplayCommand.display = "off"; @@ -1948,6 +2040,8 @@ public class TheMod DisplayCommand.display = "catacombs_floor_five"; } else if (sCleaned.contains("F6")) { DisplayCommand.display = "catacombs_floor_six"; + } else if (sCleaned.contains("F7")) { + DisplayCommand.display = "catacombs_floor_seven"; } found = true; } @@ -2295,6 +2389,10 @@ public class TheMod LootCommand.f6CoinsSpent += coinsSpent; LootCommand.f6CoinsSpentSession += coinsSpent; ConfigHandler.writeDoubleConfig("catacombs", "floorSixCoins", LootCommand.f6CoinsSpent); + } else if (sCleaned.contains("F7")) { + LootCommand.f7CoinsSpent += coinsSpent; + LootCommand.f7CoinsSpentSession += coinsSpent; + ConfigHandler.writeDoubleConfig("catacombs", "floorSevenCoins", LootCommand.f7CoinsSpent); } break; } diff --git a/src/main/java/me/Danker/commands/DHelpCommand.java b/src/main/java/me/Danker/commands/DHelpCommand.java index b3bdbbf..4fadb54 100644 --- a/src/main/java/me/Danker/commands/DHelpCommand.java +++ b/src/main/java/me/Danker/commands/DHelpCommand.java @@ -37,8 +37,8 @@ public class DHelpCommand extends CommandBase { EnumChatFormatting.GOLD + " /toggle " + EnumChatFormatting.AQUA + " - Toggles features. /toggle list returns values of every toggle.\n" + EnumChatFormatting.GOLD + " /setkey " + EnumChatFormatting.AQUA + " - Sets API key.\n" + EnumChatFormatting.GOLD + " /getkey" + EnumChatFormatting.AQUA + " - Returns key set with /setkey and copies it to your clipboard.\n" + - EnumChatFormatting.GOLD + " /loot [winter/festival/spooky/f(1-6)/session]" + EnumChatFormatting.AQUA + " - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead.\n" + - EnumChatFormatting.GOLD + " /display [winter/festival/spooky/f(1-6)/session]" + EnumChatFormatting.AQUA + " - Text display for trackers. /display fishing winter displays winter sea creatures instead. /display auto automatically displays the loot for the slayer quest you have active.\n" + + EnumChatFormatting.GOLD + " /loot [winter/festival/spooky/f(1-7)/session]" + EnumChatFormatting.AQUA + " - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead.\n" + + EnumChatFormatting.GOLD + " /display [winter/festival/spooky/f(1-7)/session]" + EnumChatFormatting.AQUA + " - Text display for trackers. /display fishing winter displays winter sea creatures instead. /display auto automatically displays the loot for the slayer quest you have active.\n" + EnumChatFormatting.GOLD + " /resetloot " + EnumChatFormatting.AQUA + " - Resets loot for trackers. /resetloot confirm confirms the reset.\n" + EnumChatFormatting.GOLD + " /move " + EnumChatFormatting.AQUA + " - Moves text display to specified X and Y coordinates.\n" + EnumChatFormatting.GOLD + " /scale " + EnumChatFormatting.AQUA + " - Scales text display to a specified multipler between 0.1x and 10x.\n" + diff --git a/src/main/java/me/Danker/commands/DisplayCommand.java b/src/main/java/me/Danker/commands/DisplayCommand.java index 2af402e..8ee18ec 100644 --- a/src/main/java/me/Danker/commands/DisplayCommand.java +++ b/src/main/java/me/Danker/commands/DisplayCommand.java @@ -22,7 +22,7 @@ public class DisplayCommand extends CommandBase { @Override public String getCommandUsage(ICommandSender arg0) { - return "/" + getCommandName() + " [winter/festival/spooky/session/f(1-6)]"; + return "/" + getCommandName() + " [winter/festival/spooky/session/f(1-7)]"; } @Override @@ -37,7 +37,7 @@ public class DisplayCommand extends CommandBase { } else if (args.length == 2 && args[0].equalsIgnoreCase("fishing")) { return getListOfStringsMatchingLastWord(args, "winter", "festival", "spooky", "session"); } else if (args.length == 2 && args[0].equalsIgnoreCase("catacombs")) { - return getListOfStringsMatchingLastWord(args, "f1", "floor1", "f2", "floor2", "f3", "floor3", "f4", "floor4", "f5", "floor5", "f6", "floor6"); + return getListOfStringsMatchingLastWord(args, "f1", "floor1", "f2", "floor2", "f3", "floor3", "f4", "floor4", "f5", "floor5", "f6", "floor6", "f7", "floor7"); } else if (args.length > 1 || (args.length == 3 && args[0].equalsIgnoreCase("fishing") && args[1].equalsIgnoreCase("winter"))) { return getListOfStringsMatchingLastWord(args, "session"); } @@ -142,6 +142,12 @@ public class DisplayCommand extends CommandBase { } else { display = "catacombs_floor_six"; } + } else if (arg1[1].equalsIgnoreCase("f7") || arg1[1].equalsIgnoreCase("floor7")) { + if (showSession) { + display = "catacombs_floor_seven_session"; + } else { + display = "catacombs_floor_seven"; + } } else { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: /display catacombs ")); return; diff --git a/src/main/java/me/Danker/commands/LootCommand.java b/src/main/java/me/Danker/commands/LootCommand.java index a7c7ced..867139f 100644 --- a/src/main/java/me/Danker/commands/LootCommand.java +++ b/src/main/java/me/Danker/commands/LootCommand.java @@ -147,6 +147,19 @@ public class LootCommand extends CommandBase { public static int necroSwords; public static double f6CoinsSpent; public static double f6TimeSpent; + // F7 + public static int witherBloods; + public static int witherCloaks; + public static int implosions; + public static int witherShields; + public static int shadowWarps; + public static int autoRecombs; + public static int witherHelms; + public static int witherChests; + public static int witherLegs; + public static int witherBoots; + public static double f7CoinsSpent; + public static double f7TimeSpent; // Single sessions (No config saves) // Wolf @@ -281,6 +294,19 @@ public class LootCommand extends CommandBase { public static int necroSwordsSession = 0; public static double f6CoinsSpentSession = 0; public static double f6TimeSpentSession = 0; + // F7 + public static int witherBloodsSession = 0; + public static int witherCloaksSession = 0; + public static int implosionsSession = 0; + public static int witherShieldsSession = 0; + public static int shadowWarpsSession = 0; + public static int autoRecombsSession = 0; + public static int witherHelmsSession = 0; + public static int witherChestsSession = 0; + public static int witherLegsSession = 0; + public static int witherBootsSession = 0; + public static double f7CoinsSpentSession = 0; + public static double f7TimeSpentSession = 0; @Override public String getCommandName() { @@ -289,7 +315,7 @@ public class LootCommand extends CommandBase { @Override public String getCommandUsage(ICommandSender arg0) { - return "/" + getCommandName() + " [winter/festival/spooky/f(1-6)/session]"; + return "/" + getCommandName() + " [winter/festival/spooky/f(1-7)/session]"; } @Override @@ -304,7 +330,7 @@ public class LootCommand extends CommandBase { } else if (args.length == 2 && args[0].equalsIgnoreCase("fishing")) { return getListOfStringsMatchingLastWord(args, "winter", "festival", "spooky", "session"); } else if (args.length == 2 && args[0].equalsIgnoreCase("catacombs")) { - return getListOfStringsMatchingLastWord(args, "f1", "floor1", "f2", "floor2", "f3", "floor3", "f4", "floor4", "f5", "floor5", "f6", "floor6"); + return getListOfStringsMatchingLastWord(args, "f1", "floor1", "f2", "floor2", "f3", "floor3", "f4", "floor4", "f5", "floor5", "f6", "floor6", "f7", "floor7"); } else if (args.length > 1 || (args.length == 3 && args[0].equalsIgnoreCase("fishing") && args[1].equalsIgnoreCase("winter"))) { return getListOfStringsMatchingLastWord(args, "session"); } @@ -860,6 +886,44 @@ public class LootCommand extends CommandBase { EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f6CoinsSpent) + "\n" + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f6TimeSpent) + "\n" + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + } else if (arg1[1].equalsIgnoreCase("f7") || arg1[1].equalsIgnoreCase("floor7")) { + if (showSession) { + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F7 Summary (Current Session):\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Wither Bloods: " + nf.format(witherBloodsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Wither Cloaks: " + nf.format(witherCloaksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Implosions: " + nf.format(implosionsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Wither Shields: " + nf.format(witherShieldsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Shadow Warps: " + nf.format(shadowWarpsSession) + "\n" + + EnumChatFormatting.GOLD + " Auto Recombobulator: " + nf.format(autoRecombsSession) + "\n" + + EnumChatFormatting.GOLD + " Wither Helmets: " + nf.format(witherHelmsSession) + "\n" + + EnumChatFormatting.GOLD + " Wither Chesplates: " + nf.format(witherChestsSession) + "\n" + + EnumChatFormatting.GOLD + " Wither Leggings: " + nf.format(witherLegsSession) + "\n" + + EnumChatFormatting.GOLD + " Wither Boots: " + nf.format(witherBootsSession) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f7CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f7TimeSpentSession) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + return; + } + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F7 Summary:\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Wither Bloods: " + nf.format(witherBloods) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Wither Cloaks: " + nf.format(witherCloaks) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Implosions: " + nf.format(implosions) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Wither Shields: " + nf.format(witherShields) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Shadow Warps: " + nf.format(shadowWarps) + "\n" + + EnumChatFormatting.GOLD + " Auto Recombobulator: " + nf.format(autoRecombs) + "\n" + + EnumChatFormatting.GOLD + " Wither Helmets: " + nf.format(witherHelms) + "\n" + + EnumChatFormatting.GOLD + " Wither Chesplates: " + nf.format(witherChests) + "\n" + + EnumChatFormatting.GOLD + " Wither Leggings: " + nf.format(witherLegs) + "\n" + + EnumChatFormatting.GOLD + " Wither Boots: " + nf.format(witherBoots) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f7CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f7TimeSpent) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); } else { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: /loot catacombs ")); } diff --git a/src/main/java/me/Danker/commands/ResetLootCommand.java b/src/main/java/me/Danker/commands/ResetLootCommand.java index f99b5ae..6e92c20 100644 --- a/src/main/java/me/Danker/commands/ResetLootCommand.java +++ b/src/main/java/me/Danker/commands/ResetLootCommand.java @@ -224,6 +224,18 @@ public class ResetLootCommand extends CommandBase { LootCommand.necroSwordsSession = 0; LootCommand.f6CoinsSpentSession = 0; LootCommand.f6TimeSpentSession = 0; + LootCommand.witherBloodsSession = 0; + LootCommand.witherCloaksSession = 0; + LootCommand.implosionsSession = 0; + LootCommand.witherShieldsSession = 0; + LootCommand.shadowWarpsSession = 0; + LootCommand.autoRecombsSession = 0; + LootCommand.witherHelmsSession = 0; + LootCommand.witherChestsSession = 0; + LootCommand.witherLegsSession = 0; + LootCommand.witherBootsSession = 0; + LootCommand.f7CoinsSpentSession = 0; + LootCommand.f7TimeSpentSession = 0; ConfigHandler.deleteCategory("catacombs"); ConfigHandler.reloadConfig(); } diff --git a/src/main/java/me/Danker/gui/DisplayGui.java b/src/main/java/me/Danker/gui/DisplayGui.java index b944a2f..21bb05e 100644 --- a/src/main/java/me/Danker/gui/DisplayGui.java +++ b/src/main/java/me/Danker/gui/DisplayGui.java @@ -32,6 +32,7 @@ public class DisplayGui extends GuiScreen { private GuiButton catacombsF4; private GuiButton catacombsF5; private GuiButton catacombsF6; + private GuiButton catacombsF7; @Override public boolean doesGuiPauseGame() { @@ -58,12 +59,13 @@ public class DisplayGui extends GuiScreen { fishingWinter = new GuiButton(0, width / 2 - 110, (int) (height * 0.4), 100, 20, "Fishing Winter"); fishingFestival = new GuiButton(0, width / 2 + 10, (int) (height * 0.4), 100, 20, "Fishing Festival"); fishingSpooky = new GuiButton(0, width / 2 + 130, (int) (height * 0.4), 100, 20, "Fishing Spooky"); - catacombsF1 = new GuiButton(0, width / 2 - 145, (int) (height * 0.55), 50, 20, "F1"); - catacombsF2 = new GuiButton(0, width / 2 - 85, (int) (height * 0.55), 50, 20, "F2"); - catacombsF3 = new GuiButton(0, width / 2 - 25, (int) (height * 0.55), 50, 20, "F3"); - catacombsF4 = new GuiButton(0, width / 2 + 35, (int) (height * 0.55), 50, 20, "F4"); - catacombsF5 = new GuiButton(0, width / 2 + 95, (int) (height * 0.55), 50, 20, "F5"); - catacombsF6 = new GuiButton(0, width / 2 - 145, (int) (height * 0.63), 50, 20, "F6"); + catacombsF1 = new GuiButton(0, width / 2 - 205, (int) (height * 0.55), 50, 20, "F1"); + catacombsF2 = new GuiButton(0, width / 2 - 145, (int) (height * 0.55), 50, 20, "F2"); + catacombsF3 = new GuiButton(0, width / 2 - 85, (int) (height * 0.55), 50, 20, "F3"); + catacombsF4 = new GuiButton(0, width / 2 - 25, (int) (height * 0.55), 50, 20, "F4"); + catacombsF5 = new GuiButton(0, width / 2 + 35, (int) (height * 0.55), 50, 20, "F5"); + catacombsF6 = new GuiButton(0, width / 2 + 95, (int) (height * 0.55), 50, 20, "F6"); + catacombsF7 = new GuiButton(0, width / 2 + 155, (int) (height * 0.55), 50, 20, "F7"); this.buttonList.add(showSession); this.buttonList.add(off); @@ -81,6 +83,7 @@ public class DisplayGui extends GuiScreen { this.buttonList.add(catacombsF4); this.buttonList.add(catacombsF5); this.buttonList.add(catacombsF6); + this.buttonList.add(catacombsF7); this.buttonList.add(editLocations); this.buttonList.add(goBack); } @@ -146,6 +149,8 @@ public class DisplayGui extends GuiScreen { setDisplay("catacombs_floor_five", false); } else if (button == catacombsF6) { setDisplay("catacombs_floor_six", false); + } else if (button == catacombsF7) { + setDisplay("catacombs_floor_seven", false); } } diff --git a/src/main/java/me/Danker/handlers/ConfigHandler.java b/src/main/java/me/Danker/handlers/ConfigHandler.java index 08a78c4..6318abb 100644 --- a/src/main/java/me/Danker/handlers/ConfigHandler.java +++ b/src/main/java/me/Danker/handlers/ConfigHandler.java @@ -335,6 +335,19 @@ public class ConfigHandler { if (!hasKey("catacombs", "necroSword")) writeIntConfig("catacombs", "necroSword", 0); if (!hasKey("catacombs", "floorSixCoins")) writeDoubleConfig("catacombs", "floorSixCoins", 0); if (!hasKey("catacombs", "floorSixTime")) writeDoubleConfig("catacombs", "floorSixTime", 0); + // F7 + if (!hasKey("catacombs", "witherBlood")) writeIntConfig("catacombs", "witherBlood", 0); + if (!hasKey("catacombs", "witherCloak")) writeIntConfig("catacombs", "witherCloak", 0); + if (!hasKey("catacombs", "implosion")) writeIntConfig("catacombs", "implosion", 0); + if (!hasKey("catacombs", "witherShield")) writeIntConfig("catacombs", "witherShield", 0); + if (!hasKey("catacombs", "shadowWarp")) writeIntConfig("catacombs", "shadowWarp", 0); + if (!hasKey("catacombs", "autoRecomb")) writeIntConfig("catacombs", "autoRecomb", 0); + if (!hasKey("catacombs", "witherHelm")) writeIntConfig("catacombs", "witherHelm", 0); + if (!hasKey("catacombs", "witherChest")) writeIntConfig("catacombs", "witherChest", 0); + if (!hasKey("catacombs", "witherLegging")) writeIntConfig("catacombs", "witherLegging", 0); + if (!hasKey("catacombs", "witherBoot")) writeIntConfig("catacombs", "witherBoot", 0); + if (!hasKey("catacombs", "floorSevenCoins")) writeDoubleConfig("catacombs", "floorSevenCoins", 0); + if (!hasKey("catacombs", "floorSevenTime")) writeDoubleConfig("catacombs", "floorSevenTime", 0); if (!hasKey("misc", "display")) writeStringConfig("misc", "display", "off"); if (!hasKey("misc", "autoDisplay")) writeBooleanConfig("misc", "autoDisplay", false); @@ -540,6 +553,19 @@ public class ConfigHandler { LootCommand.necroSwords = getInt("catacombs", "necroSword"); LootCommand.f6CoinsSpent = getDouble("catacombs", "floorSixCoins"); LootCommand.f6TimeSpent = getDouble("catacombs", "floorSixTime"); + // F7 + LootCommand.witherBloods = getInt("catacombs", "witherBlood"); + LootCommand.witherCloaks = getInt("catacombs", "witherCloak"); + LootCommand.implosions = getInt("catacombs", "implosion"); + LootCommand.witherShields = getInt("catacombs", "witherShield"); + LootCommand.shadowWarps = getInt("catacombs", "shadowWarp"); + LootCommand.autoRecombs = getInt("catacombs", "autoRecomb"); + LootCommand.witherHelms = getInt("catacombs", "witherHelm"); + LootCommand.witherChests = getInt("catacombs", "witherChest"); + LootCommand.witherLegs = getInt("catacombs", "witherLegging"); + LootCommand.witherBoots = getInt("catacombs", "witherBoot"); + LootCommand.f7CoinsSpent = getDouble("catacombs", "floorSevenCoins"); + LootCommand.f7TimeSpent = getDouble("catacombs", "floorSevenTime"); // Misc DisplayCommand.display = getString("misc", "display"); -- cgit From ea9c0616fd3406c3a93995f6ab28309fe6cd8e05 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Mon, 23 Nov 2020 09:57:06 -0500 Subject: Add skill xp/hour tracker, add Necron's Handle and bug fixes Fix F7 loot not saving to config Fix water puzzle variant 3 solution --- README.md | 17 +- src/main/java/me/Danker/TheMod.java | 218 ++++++++++++++++++--- src/main/java/me/Danker/commands/DHelpCommand.java | 8 +- src/main/java/me/Danker/commands/LootCommand.java | 4 + src/main/java/me/Danker/commands/MoveCommand.java | 12 +- src/main/java/me/Danker/commands/ScaleCommand.java | 9 +- .../me/Danker/commands/SkillTrackerCommand.java | 94 +++++++++ src/main/java/me/Danker/gui/DankerGui.java | 43 ++-- src/main/java/me/Danker/gui/EditLocationsGui.java | 16 ++ src/main/java/me/Danker/gui/SkillTrackerGui.java | 99 ++++++++++ .../java/me/Danker/handlers/ConfigHandler.java | 12 ++ src/main/java/me/Danker/utils/Utils.java | 8 +- src/main/resources/mcmod.info | 3 +- 13 files changed, 486 insertions(+), 57 deletions(-) create mode 100644 src/main/java/me/Danker/commands/SkillTrackerCommand.java create mode 100644 src/main/java/me/Danker/gui/SkillTrackerGui.java (limited to 'src/main/java/me/Danker/gui') diff --git a/README.md b/README.md index 7a5369b..c0ab188 100644 --- a/README.md +++ b/README.md @@ -28,6 +28,7 @@ Discord Server: https://discord.gg/QsEkNQS - Find correct Livid (with graphic display of HP) (toggleable) - Pet background colors based on level - Golem spawning alerts (toggleable) +- Skill xp/hour tracker - Show total skill xp instead of progress to next level - Show time until century cakes run out - API commands @@ -42,8 +43,8 @@ Discord Server: https://discord.gg/QsEkNQS - /loot [winter/spooky/f(1-7)/session] - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead. - /display [winter/spooky/f(1-7)/session] - Text display for trackers. /display fishing winter displays winter sea creatures instead. /display auto automatically displays the loot for the slayer quest you have active. - /resetloot - - Resets loot for trackers. /resetloot confirm confirms the reset. -- /move - Moves text display to specified X and Y coordinates. -- /scale - Scales text display to a specified multipler between 0.1x and 10x. +- /move - Moves text display to specified X and Y coordinates. +- /scale - Scales text display to a specified multipler between 0.1x and 10x. - /slayer [player] - Uses API to get slayer xp of a person. If no name is provided, it checks yours. - /skills [player] - Uses API to get skill levels of a person. If no name is provided, it checks yours. - /lobbyskills - Uses API to find the average skills of the lobby, as well the three players with the highest skill average. @@ -55,12 +56,24 @@ Discord Server: https://discord.gg/QsEkNQS - /importfishing - Imports your fishing stats from your latest profile to your fishing tracker using the API. - /sbplayers - Uses API to find how many players are on each Skyblock island. - /onlyslayer <1/2/3/4> - Stops you from starting a slayer quest other than the one specified. +- /skilltracker - Text display for skill xp/hour. ## Keybinds - Open Maddox menu - M by default. +- Start/Stop Skill Tracker - Numpad 5 by default. ### Notes - Slayer tracker for token drops and 20% chance drops uses a 12x12x12 bounding box centered on the player to detect the drops. If you are out of the range of the item drop, it will not count on the tracker. - API commands may take a while depending on your internet connection. The API may also go down. - If you use too many API commands too fast, you can and will get rate-limited. - Importing fishing uses your sea creature kills, which may not always be exactly correct (e.x. someone else kills your sea creature). + +### Credits to Open Source Software +Credit to all the following open source software used in this mod. + +Software | License +------------ | ------------- +[SkyblockAddons](https://github.com/BiscuitDevelopment/SkyblockAddons/) | [MIT License](https://github.com/BiscuitDevelopment/SkyblockAddons/blob/master/LICENSE) +[Zealot Counter](https://github.com/symt/zealot-counter/) | No License +[NotEnoughUpdates](https://github.com/Moulberry/NotEnoughUpdates/) | [Creative Commons Public License](https://github.com/Moulberry/NotEnoughUpdates/blob/master/LICENSE) +[ForgeHax](https://github.com/fr1kin/ForgeHax) | [MIT License](https://github.com/fr1kin/ForgeHax/blob/1.16/LICENSE) \ No newline at end of file diff --git a/src/main/java/me/Danker/TheMod.java b/src/main/java/me/Danker/TheMod.java index 9478d6c..5c992ae 100644 --- a/src/main/java/me/Danker/TheMod.java +++ b/src/main/java/me/Danker/TheMod.java @@ -12,6 +12,7 @@ import java.util.Locale; import java.util.Map; import java.util.regex.Pattern; +import org.apache.commons.lang3.time.StopWatch; import org.lwjgl.input.Keyboard; import org.lwjgl.input.Mouse; import org.lwjgl.opengl.GL11; @@ -36,6 +37,7 @@ import me.Danker.commands.ReloadConfigCommand; import me.Danker.commands.ResetLootCommand; import me.Danker.commands.ScaleCommand; import me.Danker.commands.SetkeyCommand; +import me.Danker.commands.SkillTrackerCommand; import me.Danker.commands.SkillsCommand; import me.Danker.commands.SkyblockPlayersCommand; import me.Danker.commands.SlayerCommand; @@ -45,6 +47,7 @@ import me.Danker.gui.DisplayGui; import me.Danker.gui.EditLocationsGui; import me.Danker.gui.OnlySlayerGui; import me.Danker.gui.PuzzleSolversGui; +import me.Danker.gui.SkillTrackerGui; import me.Danker.handlers.APIHandler; import me.Danker.handlers.ConfigHandler; import me.Danker.handlers.PacketHandler; @@ -126,16 +129,22 @@ public class TheMod static int tickAmount = 1; static String lastMaddoxCommand = "/cb placeholder"; static double lastMaddoxTime = 0; - static KeyBinding[] keyBindings = new KeyBinding[1]; + static KeyBinding[] keyBindings = new KeyBinding[2]; static int lastMouse = -1; static boolean usingLabymod = false; public static String guiToOpen = null; + static boolean foundLivid = false; + static Entity livid = null; + public static double cakeTime; + + public static final ResourceLocation CAKE_ICON = new ResourceLocation("dsm", "icons/cake.png"); + static String[] riddleSolutions = {"The reward is not in my chest!", "At least one of them is lying, and the reward is not in", - "My chest doesn't have the reward. We are all telling the truth", "My chest has the reward and I'm telling the truth", - "The reward isn't in any of our chests", "Both of them are telling the truth."}; - static Map triviaSolutions = new HashMap(); - static String[] triviaAnswers = null; - static Entity highestBlaze = null; + "My chest doesn't have the reward. We are all telling the truth", "My chest has the reward and I'm telling the truth", + "The reward isn't in any of our chests", "Both of them are telling the truth."}; + static Map triviaSolutions = new HashMap(); + static String[] triviaAnswers = null; + static Entity highestBlaze = null; static Entity lowestBlaze = null; // Among Us colours static final int[] CREEPER_COLOURS = {0x50EF39, 0xC51111, 0x132ED1, 0x117F2D, 0xED54BA, 0xEF7D0D, 0xF5F557, 0xD6E0F0, 0x6B2FBB, 0x39FEDC}; @@ -144,12 +153,7 @@ public class TheMod static List creeperLines = new ArrayList(); static boolean prevInWaterRoom = false; static boolean inWaterRoom = false; - static boolean foundLivid = false; - static Entity livid = null; - public static double cakeTime; - public static final ResourceLocation CAKE_ICON = new ResourceLocation("dsm", "icons/cake.png"); - static double dungeonStartTime = 0; static double bloodOpenTime = 0; static double watcherClearTime = 0; @@ -158,6 +162,24 @@ public class TheMod static int dungeonDeaths = 0; static int puzzleFails = 0; + static String lastSkill = "Farming"; + public static boolean showSkillTracker; + public static StopWatch skillStopwatch = new StopWatch(); + static double farmingXP = 0; + public static double farmingXPGained = 0; + static double miningXP = 0; + public static double miningXPGained = 0; + static double combatXP = 0; + public static double combatXPGained = 0; + static double foragingXP = 0; + public static double foragingXPGained = 0; + static double fishingXP = 0; + public static double fishingXPGained = 0; + static double enchantingXP = 0; + public static double enchantingXPGained = 0; + static double alchemyXP = 0; + public static double alchemyXPGained = 0; + public static String MAIN_COLOUR; public static String SECONDARY_COLOUR; public static String ERROR_COLOUR; @@ -169,6 +191,7 @@ public class TheMod public static String SKILL_50_COLOUR; public static String COORDS_COLOUR; public static String CAKE_COLOUR; + public static String SKILL_TRACKER_COLOUR; @EventHandler public void init(FMLInitializationEvent event) { @@ -250,6 +273,7 @@ public class TheMod pattern = Pattern.compile(patternString); keyBindings[0] = new KeyBinding("Open Maddox Menu", Keyboard.KEY_M, "Danker's Skyblock Mod"); + keyBindings[1] = new KeyBinding("Start/Stop Skill Tracker", Keyboard.KEY_NUMPAD5, "Danker's Skyblock Mod"); for (int i = 0; i < keyBindings.length; i++) { ClientRegistry.registerKeyBinding(keyBindings[i]); @@ -279,7 +303,8 @@ public class TheMod ClientCommandHandler.instance.registerCommand(new BlockSlayerCommand()); ClientCommandHandler.instance.registerCommand(new DungeonsCommand()); ClientCommandHandler.instance.registerCommand(new LobbySkillsCommand()); - ClientCommandHandler.instance.registerCommand(new DankerGuiCommand()); + ClientCommandHandler.instance.registerCommand(new DankerGuiCommand()); + ClientCommandHandler.instance.registerCommand(new SkillTrackerCommand()); } @EventHandler @@ -339,12 +364,86 @@ public class TheMod if (event.type == 2) { String[] actionBarSections = event.message.getUnformattedText().split(" {3,}"); for (String section : actionBarSections) { - if (ToggleCommand.skill50DisplayToggled) { - if (section.contains("+") && section.contains("/") && section.contains("(")) { - if (section.contains("Runecrafting")) return; - + if (section.contains("+") && section.contains("/") && section.contains("(")) { + if (!section.contains("Runecrafting") && !section.contains("Carpentry")) { + int limit = section.contains("Farming") ? 60 : 50; + double currentXP = Double.parseDouble(section.substring(section.indexOf("(") + 1, section.indexOf("/")).replace(",", "")); + int previousXP = Utils.getPastXpEarned(Integer.parseInt(section.substring(section.indexOf("/") + 1, section.indexOf(")")).replaceAll(",", "")), limit); + double totalXP = currentXP + previousXP; + double xpGained = Double.parseDouble(section.substring(section.indexOf("+") + 1, section.indexOf(" ")).replace(",", "")); + String skill = section.substring(section.indexOf(" ") + 1, section.lastIndexOf(" ")); + switch (skill) { + case "Farming": + lastSkill = "Farming"; + if (farmingXP == 0) { + farmingXP = totalXP; + } else { + if (skillStopwatch.isStarted() && !skillStopwatch.isSuspended()) farmingXPGained += totalXP - farmingXP; + farmingXP = totalXP; + } + break; + case "Mining": + lastSkill = "Mining"; + if (miningXP == 0) { + miningXP = totalXP; + } else { + if (skillStopwatch.isStarted() && !skillStopwatch.isSuspended()) miningXPGained += totalXP - miningXP; + miningXP = totalXP; + } + break; + case "Combat": + lastSkill = "Combat"; + if (combatXP == 0) { + combatXP = totalXP; + } else { + if (skillStopwatch.isStarted() && !skillStopwatch.isSuspended()) combatXPGained += totalXP - combatXP; + combatXP = totalXP; + } + break; + case "Foraging": + lastSkill = "Foraging"; + if (foragingXP == 0) { + foragingXP = totalXP; + } else { + if (skillStopwatch.isStarted() && !skillStopwatch.isSuspended()) foragingXPGained += totalXP - foragingXP; + foragingXP = totalXP; + } + break; + case "Fishing": + lastSkill = "Fishing"; + if (fishingXP == 0) { + fishingXP = totalXP; + } else { + if (skillStopwatch.isStarted() && !skillStopwatch.isSuspended()) fishingXPGained += totalXP - fishingXP; + fishingXP = totalXP; + } + break; + case "Enchanting": + lastSkill = "Enchanting"; + if (enchantingXP == 0) { + enchantingXP = totalXP; + } else { + if (skillStopwatch.isStarted() && !skillStopwatch.isSuspended()) enchantingXPGained += totalXP - enchantingXP; + enchantingXP = totalXP; + } + break; + case "Alchemy": + lastSkill = "Alchemy"; + if (alchemyXP == 0) { + alchemyXP = totalXP; + } else { + if (skillStopwatch.isStarted() && !skillStopwatch.isSuspended()) alchemyXPGained += totalXP - alchemyXP; + alchemyXP = totalXP; + } + break; + default: + System.err.println("Unknown skill."); + } + } + + if (ToggleCommand.skill50DisplayToggled && !section.contains("Runecrafting")) { String xpGained = section.substring(section.indexOf("+"), section.indexOf("(") - 1); - double currentXp = Double.parseDouble(section.substring(section.indexOf("(") + 1, section.indexOf("/")).replaceAll(",", "")); + double currentXp = Double.parseDouble(section.substring(section.indexOf("(") + 1, section.indexOf("/")).replace(",", "")); int limit; int totalXp; if (section.contains("Farming")) { @@ -988,33 +1087,47 @@ public class TheMod } else if (message.contains("Wither Blood")) { // F7 LootCommand.witherBloods++; LootCommand.witherBloodsSession++; + ConfigHandler.writeIntConfig("catacombs", "witherBlood", LootCommand.witherBloods); } else if (message.contains("Wither Cloak")) { LootCommand.witherCloaks++; LootCommand.witherCloaksSession++; + ConfigHandler.writeIntConfig("catacombs", "witherCloak", LootCommand.witherCloaks); } else if (message.contains("Implosion")) { LootCommand.implosions++; LootCommand.implosionsSession++; + ConfigHandler.writeIntConfig("catacombs", "implosion", LootCommand.implosions); } else if (message.contains("Wither Shield")) { LootCommand.witherShields++; LootCommand.witherShieldsSession++; + ConfigHandler.writeIntConfig("catacombs", "witherShield", LootCommand.witherShields); } else if (message.contains("Shadow Warp")) { LootCommand.shadowWarps++; LootCommand.shadowWarpsSession++; + ConfigHandler.writeIntConfig("catacombs", "shadowWarp", LootCommand.shadowWarps); + } else if (message.contains("Necron's Handle")) { + LootCommand.necronsHandles++; + LootCommand.necronsHandlesSession++; + ConfigHandler.writeIntConfig("catacombs", "necronsHandle", LootCommand.necronsHandles); } else if (message.contains("Auto Recombobulator")) { LootCommand.autoRecombs++; LootCommand.autoRecombsSession++; + ConfigHandler.writeIntConfig("catacombs", "autoRecomb", LootCommand.autoRecombs); } else if (message.contains("Wither Helmet")) { LootCommand.witherHelms++; LootCommand.witherHelmsSession++; + ConfigHandler.writeIntConfig("catacombs", "witherHelm", LootCommand.witherHelms); } else if (message.contains("Wither Chestplate")) { LootCommand.witherChests++; LootCommand.witherChestsSession++; + ConfigHandler.writeIntConfig("catacombs", "witherChest", LootCommand.witherChests); } else if (message.contains("Wither Leggings")) { LootCommand.witherLegs++; LootCommand.witherLegsSession++; + ConfigHandler.writeIntConfig("catacombs", "witherLegging", LootCommand.witherLegs); } else if (message.contains("Wither Boots")) { LootCommand.witherBoots++; LootCommand.witherBootsSession++; + ConfigHandler.writeIntConfig("catacombs", "witherBoot", LootCommand.witherBoots); } } @@ -1109,6 +1222,45 @@ public class TheMod GL11.glScaled(scaleReset, scaleReset, scaleReset); } + if (showSkillTracker && Utils.inSkyblock) { + int xpPerHour = 0; + double xpToShow = 0; + switch (lastSkill) { + case "Farming": + xpToShow = farmingXPGained; + break; + case "Mining": + xpToShow = miningXPGained; + break; + case "Combat": + xpToShow = combatXPGained; + break; + case "Foraging": + xpToShow = foragingXPGained; + break; + case "Fishing": + xpToShow = fishingXPGained; + break; + case "Enchanting": + xpToShow = enchantingXPGained; + break; + case "Alchemy": + xpToShow = alchemyXPGained; + break; + default: + System.err.println("Unknown skill in rendering."); + } + xpPerHour = (int) Math.round(xpToShow / ((skillStopwatch.getTime() + 1) / 3600000d)); + String skillTrackerText = SKILL_TRACKER_COLOUR + lastSkill + " XP Earned: " + NumberFormat.getNumberInstance(Locale.US).format(xpToShow) + "\n" + + SKILL_TRACKER_COLOUR + "Time Elapsed: " + Utils.getTimeBetween(0, skillStopwatch.getTime() / 1000d) + "\n" + + SKILL_TRACKER_COLOUR + "XP Per Hour: " + NumberFormat.getIntegerInstance(Locale.US).format(xpPerHour); + if (!skillStopwatch.isStarted() || skillStopwatch.isSuspended()) { + skillTrackerText += "\n" + EnumChatFormatting.RED + "PAUSED"; + } + + new TextRenderer(mc, skillTrackerText, MoveCommand.skillTrackerXY[0], MoveCommand.skillTrackerXY[1], ScaleCommand.skillTrackerScale); + } + if (!DisplayCommand.display.equals("off")) { String dropsText = ""; String countText = ""; @@ -1850,6 +2002,7 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + "Implosions:\n" + EnumChatFormatting.DARK_PURPLE + "Wither Shields:\n" + EnumChatFormatting.DARK_PURPLE + "Shadow Warps:\n" + + EnumChatFormatting.DARK_PURPLE + "Necron's Handles:\n" + EnumChatFormatting.GOLD + "Auto Recombobs:\n" + EnumChatFormatting.GOLD + "Wither Helmets:\n" + EnumChatFormatting.GOLD + "Wither Chests:\n" + @@ -1864,6 +2017,7 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.implosions) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherShields) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowWarps) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.necronsHandles) + "\n" + EnumChatFormatting.GOLD + nf.format(LootCommand.autoRecombs) + "\n" + EnumChatFormatting.GOLD + nf.format(LootCommand.witherHelms) + "\n" + EnumChatFormatting.GOLD + nf.format(LootCommand.witherChests) + "\n" + @@ -1879,6 +2033,7 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + "Implosions:\n" + EnumChatFormatting.DARK_PURPLE + "Wither Shields:\n" + EnumChatFormatting.DARK_PURPLE + "Shadow Warps:\n" + + EnumChatFormatting.DARK_PURPLE + "Necron's Handles:\n" + EnumChatFormatting.GOLD + "Auto Recombobulators:\n" + EnumChatFormatting.GOLD + "Wither Helmets:\n" + EnumChatFormatting.GOLD + "Wither Chests:\n" + @@ -1893,6 +2048,7 @@ public class TheMod EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.implosionsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherShieldsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowWarpsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.necronsHandlesSession) + "\n" + EnumChatFormatting.GOLD + nf.format(LootCommand.autoRecombsSession) + "\n" + EnumChatFormatting.GOLD + nf.format(LootCommand.witherHelmsSession) + "\n" + EnumChatFormatting.GOLD + nf.format(LootCommand.witherChestsSession) + "\n" + @@ -2157,11 +2313,11 @@ public class TheMod red = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.DARK_GRAY + "Coal, " + EnumChatFormatting.GREEN + "Emerald"; break; case 3: - purple = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.AQUA + "Diamond"; - orange = EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.GREEN + "Emerald"; - blue = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.AQUA + "Diamond"; - green = EnumChatFormatting.YELLOW + "Gold"; - red = EnumChatFormatting.GREEN + "Emerald"; + purple = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.AQUA + "Diamond"; + orange = EnumChatFormatting.GREEN + "Emerald"; + blue = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.AQUA + "Diamond"; + green = EnumChatFormatting.GRAY + "None"; + red = EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.GREEN + "Emerald"; break; case 4: purple = EnumChatFormatting.WHITE + "Quartz, " + EnumChatFormatting.YELLOW + "Gold, " + EnumChatFormatting.GREEN + "Emerald, " + EnumChatFormatting.RED + "Clay"; @@ -2283,6 +2439,8 @@ public class TheMod mc.displayGuiScreen(new EditLocationsGui()); } else if (guiToOpen.equals("puzzlesolvers")) { mc.displayGuiScreen(new PuzzleSolversGui()); + } else if (guiToOpen.equals("skilltracker")) { + mc.displayGuiScreen(new SkillTrackerGui()); } guiToOpen = null; } @@ -2330,8 +2488,22 @@ public class TheMod @SubscribeEvent public void onKey(KeyInputEvent event) { if (!Utils.inSkyblock) return; + + EntityPlayerSP player = Minecraft.getMinecraft().thePlayer; if (keyBindings[0].isPressed()) { - Minecraft.getMinecraft().thePlayer.sendChatMessage(lastMaddoxCommand); + player.sendChatMessage(lastMaddoxCommand); + } + if (keyBindings[1].isPressed()) { + if (skillStopwatch.isStarted() && skillStopwatch.isSuspended()) { + skillStopwatch.resume(); + player.addChatMessage(new ChatComponentText(MAIN_COLOUR + "Skill tracker started.")); + } else if (!skillStopwatch.isStarted()) { + skillStopwatch.start(); + player.addChatMessage(new ChatComponentText(MAIN_COLOUR + "Skill tracker started.")); + } else if (skillStopwatch.isStarted() && !skillStopwatch.isSuspended()) { + skillStopwatch.suspend(); + player.addChatMessage(new ChatComponentText(MAIN_COLOUR + "Skill tracker paused.")); + } } } diff --git a/src/main/java/me/Danker/commands/DHelpCommand.java b/src/main/java/me/Danker/commands/DHelpCommand.java index 4fadb54..d514fbd 100644 --- a/src/main/java/me/Danker/commands/DHelpCommand.java +++ b/src/main/java/me/Danker/commands/DHelpCommand.java @@ -40,8 +40,8 @@ public class DHelpCommand extends CommandBase { EnumChatFormatting.GOLD + " /loot [winter/festival/spooky/f(1-7)/session]" + EnumChatFormatting.AQUA + " - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead.\n" + EnumChatFormatting.GOLD + " /display [winter/festival/spooky/f(1-7)/session]" + EnumChatFormatting.AQUA + " - Text display for trackers. /display fishing winter displays winter sea creatures instead. /display auto automatically displays the loot for the slayer quest you have active.\n" + EnumChatFormatting.GOLD + " /resetloot " + EnumChatFormatting.AQUA + " - Resets loot for trackers. /resetloot confirm confirms the reset.\n" + - EnumChatFormatting.GOLD + " /move " + EnumChatFormatting.AQUA + " - Moves text display to specified X and Y coordinates.\n" + - EnumChatFormatting.GOLD + " /scale " + EnumChatFormatting.AQUA + " - Scales text display to a specified multipler between 0.1x and 10x.\n" + + EnumChatFormatting.GOLD + " /move " + EnumChatFormatting.AQUA + " - Moves text display to specified X and Y coordinates.\n" + + EnumChatFormatting.GOLD + " /scale " + EnumChatFormatting.AQUA + " - Scales text display to a specified multipler between 0.1x and 10x.\n" + EnumChatFormatting.GOLD + " /slayer [player]" + EnumChatFormatting.AQUA + " - Uses API to get slayer xp of a person. If no name is provided, it checks yours.\n" + EnumChatFormatting.GOLD + " /skills [player]" + EnumChatFormatting.AQUA + " - Uses API to get skill levels of a person. If no name is provided, it checks yours.\n" + EnumChatFormatting.GOLD + " /lobbyskills" + EnumChatFormatting.AQUA + " - Uses API to find the average skills of the lobby, as well the three players with the highest skill average.\n" + @@ -53,7 +53,9 @@ public class DHelpCommand extends CommandBase { EnumChatFormatting.GOLD + " /importfishing" + EnumChatFormatting.AQUA + " - Imports your fishing stats from your latest profile to your fishing tracker using the API.\n" + EnumChatFormatting.GOLD + " /sbplayers" + EnumChatFormatting.AQUA + " - Uses API to find how many players are on each Skyblock island.\n" + EnumChatFormatting.GOLD + " /onlyslayer <1/2/3/4>" + EnumChatFormatting.AQUA + " - Stops you from starting a slayer quest other than the one specified.\n" + - EnumChatFormatting.GREEN + " Open Maddox Menu" + EnumChatFormatting.AQUA + " - M by default.\n")); + EnumChatFormatting.GOLD + " /skilltracker " + EnumChatFormatting.AQUA + " - Text display for skill xp/hour.\n" + + EnumChatFormatting.GREEN + " Open Maddox Menu" + EnumChatFormatting.AQUA + " - M by default.\n" + + EnumChatFormatting.GREEN + " Start/Stop Skill Tracker" + EnumChatFormatting.AQUA + " - Numpad 5 by default.\n")); } } diff --git a/src/main/java/me/Danker/commands/LootCommand.java b/src/main/java/me/Danker/commands/LootCommand.java index 867139f..f66d0c4 100644 --- a/src/main/java/me/Danker/commands/LootCommand.java +++ b/src/main/java/me/Danker/commands/LootCommand.java @@ -153,6 +153,7 @@ public class LootCommand extends CommandBase { public static int implosions; public static int witherShields; public static int shadowWarps; + public static int necronsHandles; public static int autoRecombs; public static int witherHelms; public static int witherChests; @@ -300,6 +301,7 @@ public class LootCommand extends CommandBase { public static int implosionsSession = 0; public static int witherShieldsSession = 0; public static int shadowWarpsSession = 0; + public static int necronsHandlesSession = 0; public static int autoRecombsSession = 0; public static int witherHelmsSession = 0; public static int witherChestsSession = 0; @@ -897,6 +899,7 @@ public class LootCommand extends CommandBase { EnumChatFormatting.DARK_PURPLE + " Implosions: " + nf.format(implosionsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + " Wither Shields: " + nf.format(witherShieldsSession) + "\n" + EnumChatFormatting.DARK_PURPLE + " Shadow Warps: " + nf.format(shadowWarpsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Necron's Handles: " + nf.format(necronsHandlesSession) + "\n" + EnumChatFormatting.GOLD + " Auto Recombobulator: " + nf.format(autoRecombsSession) + "\n" + EnumChatFormatting.GOLD + " Wither Helmets: " + nf.format(witherHelmsSession) + "\n" + EnumChatFormatting.GOLD + " Wither Chesplates: " + nf.format(witherChestsSession) + "\n" + @@ -916,6 +919,7 @@ public class LootCommand extends CommandBase { EnumChatFormatting.DARK_PURPLE + " Implosions: " + nf.format(implosions) + "\n" + EnumChatFormatting.DARK_PURPLE + " Wither Shields: " + nf.format(witherShields) + "\n" + EnumChatFormatting.DARK_PURPLE + " Shadow Warps: " + nf.format(shadowWarps) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Necron's Handles: " + nf.format(necronsHandles) + "\n" + EnumChatFormatting.GOLD + " Auto Recombobulator: " + nf.format(autoRecombs) + "\n" + EnumChatFormatting.GOLD + " Wither Helmets: " + nf.format(witherHelms) + "\n" + EnumChatFormatting.GOLD + " Wither Chesplates: " + nf.format(witherChests) + "\n" + diff --git a/src/main/java/me/Danker/commands/MoveCommand.java b/src/main/java/me/Danker/commands/MoveCommand.java index 0581d8c..93e04a3 100644 --- a/src/main/java/me/Danker/commands/MoveCommand.java +++ b/src/main/java/me/Danker/commands/MoveCommand.java @@ -19,6 +19,7 @@ public class MoveCommand extends CommandBase { public static int[] skill50XY = {0, 0}; public static int[] lividHpXY = {0, 0}; public static int[] cakeTimerXY = {0, 0}; + public static int[] skillTrackerXY = {0, 0}; @Override public String getCommandName() { @@ -27,7 +28,7 @@ public class MoveCommand extends CommandBase { @Override public String getCommandUsage(ICommandSender arg0) { - return "/" + getCommandName() + " "; + return "/" + getCommandName() + " "; } @Override @@ -38,7 +39,7 @@ public class MoveCommand extends CommandBase { @Override public List addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) { if (args.length == 1) { - return getListOfStringsMatchingLastWord(args, "coords", "display", "dungeontimer", "skill50", "lividhp", "caketimer"); + return getListOfStringsMatchingLastWord(args, "coords", "display", "dungeontimer", "skill50", "lividhp", "caketimer", "skilltracker"); } return null; } @@ -87,6 +88,13 @@ public class MoveCommand extends CommandBase { cakeTimerXY[1] = Integer.parseInt(arg1[2]); ConfigHandler.writeIntConfig("locations", "cakeTimerX", cakeTimerXY[0]); ConfigHandler.writeIntConfig("locations", "cakeTimerY", cakeTimerXY[1]); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Cake timer has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); + } else if (arg1[0].equalsIgnoreCase("skilltracker")) { + skillTrackerXY[0] = Integer.parseInt(arg1[1]); + skillTrackerXY[1] = Integer.parseInt(arg1[2]); + ConfigHandler.writeIntConfig("locations", "skillTrackerX", skillTrackerXY[0]); + ConfigHandler.writeIntConfig("locations", "skillTrackerY", skillTrackerXY[1]); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill tracker has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); } else { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); } diff --git a/src/main/java/me/Danker/commands/ScaleCommand.java b/src/main/java/me/Danker/commands/ScaleCommand.java index 1527e40..cfc7282 100644 --- a/src/main/java/me/Danker/commands/ScaleCommand.java +++ b/src/main/java/me/Danker/commands/ScaleCommand.java @@ -19,6 +19,7 @@ public class ScaleCommand extends CommandBase { public static double skill50Scale; public static double lividHpScale; public static double cakeTimerScale; + public static double skillTrackerScale; @Override public String getCommandName() { @@ -27,7 +28,7 @@ public class ScaleCommand extends CommandBase { @Override public String getCommandUsage(ICommandSender arg0) { - return "/" + getCommandName() + " "; + return "/" + getCommandName() + " "; } @Override @@ -38,7 +39,7 @@ public class ScaleCommand extends CommandBase { @Override public List addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) { if (args.length == 1) { - return getListOfStringsMatchingLastWord(args, "coords", "display", "dungeontimer", "skill50", "lividhp", "caketimer"); + return getListOfStringsMatchingLastWord(args, "coords", "display", "dungeontimer", "skill50", "lividhp", "caketimer", "skilltracker"); } return null; } @@ -82,6 +83,10 @@ public class ScaleCommand extends CommandBase { cakeTimerScale = scaleAmount; ConfigHandler.writeDoubleConfig("scales", "cakeTimerScale", cakeTimerScale); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Cake timer has been scaled to " + TheMod.SECONDARY_COLOUR + cakeTimerScale + "x")); + } else if (arg1[0].equalsIgnoreCase("skilltracker")) { + skillTrackerScale = scaleAmount; + ConfigHandler.writeDoubleConfig("scales", "skillTrackerScale", skillTrackerScale); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill tracker has been scaled to " + TheMod.SECONDARY_COLOUR + skillTrackerScale + "x")); } else { player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); } diff --git a/src/main/java/me/Danker/commands/SkillTrackerCommand.java b/src/main/java/me/Danker/commands/SkillTrackerCommand.java new file mode 100644 index 0000000..6e6d742 --- /dev/null +++ b/src/main/java/me/Danker/commands/SkillTrackerCommand.java @@ -0,0 +1,94 @@ +package me.Danker.commands; + +import java.util.List; + +import org.apache.commons.lang3.time.StopWatch; + +import me.Danker.TheMod; +import me.Danker.handlers.ConfigHandler; +import net.minecraft.command.CommandBase; +import net.minecraft.command.CommandException; +import net.minecraft.command.ICommandSender; +import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.util.BlockPos; +import net.minecraft.util.ChatComponentText; + +public class SkillTrackerCommand extends CommandBase { + + @Override + public String getCommandName() { + return "skilltracker"; + } + + @Override + public String getCommandUsage(ICommandSender arg0) { + return "/" + getCommandName() + " "; + } + + @Override + public int getRequiredPermissionLevel() { + return 0; + } + + @Override + public List addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) { + if (args.length == 1) { + return getListOfStringsMatchingLastWord(args, "start", "resume", "pause", "stop", "reset", "hide", "show"); + } + return null; + } + + @Override + public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException { + EntityPlayer player = (EntityPlayer) arg0; + + if (arg1.length < 1) { + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); + return; + } + + switch (arg1[0].toLowerCase()) { + case "start": + case "resume": + if (TheMod.skillStopwatch.isStarted() && TheMod.skillStopwatch.isSuspended()) { + TheMod.skillStopwatch.resume(); + } else if (!TheMod.skillStopwatch.isStarted()) { + TheMod.skillStopwatch.start(); + } + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill tracker started.")); + break; + case "pause": + case "stop": + if (TheMod.skillStopwatch.isStarted() && !TheMod.skillStopwatch.isSuspended()) { + TheMod.skillStopwatch.suspend(); + } else { + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill tracker paused.")); + } + break; + case "reset": + TheMod.skillStopwatch = new StopWatch(); + TheMod.farmingXPGained = 0; + TheMod.miningXPGained = 0; + TheMod.combatXPGained = 0; + TheMod.foragingXPGained = 0; + TheMod.fishingXPGained = 0; + TheMod.enchantingXPGained = 0; + TheMod.alchemyXPGained = 0; + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill tracker reset.")); + break; + case "hide": + TheMod.showSkillTracker = false; + ConfigHandler.writeBooleanConfig("misc", "showSkillTracker", false); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill tracker hidden.")); + break; + case "show": + TheMod.showSkillTracker = true; + ConfigHandler.writeBooleanConfig("misc", "showSkillTracker", true); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill tracker shown.")); + break; + default: + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); + } + } + +} diff --git a/src/main/java/me/Danker/gui/DankerGui.java b/src/main/java/me/Danker/gui/DankerGui.java index 73db9f0..205dc8b 100644 --- a/src/main/java/me/Danker/gui/DankerGui.java +++ b/src/main/java/me/Danker/gui/DankerGui.java @@ -27,6 +27,7 @@ public class DankerGui extends GuiScreen { private GuiButton changeDisplay; private GuiButton onlySlayer; private GuiButton puzzleSolvers; + private GuiButton skillTracker; // Toggles private GuiButton gparty; private GuiButton coords; @@ -78,44 +79,45 @@ public class DankerGui extends GuiScreen { changeDisplay = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Change Display Settings"); onlySlayer = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Set Slayer Quest"); puzzleSolvers = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Toggle Dungeons Puzzle Solvers"); - outlineText = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Outline Displayed Text: " + Utils.getColouredBoolean(ToggleCommand.outlineTextToggled)); - splitFishing = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Split Fishing Display: " + Utils.getColouredBoolean(ToggleCommand.splitFishing)); - dungeonTimer = new GuiButton(0, width / 2 - 100, (int) (height * 0.6), "Display Dungeon Timers: " + Utils.getColouredBoolean(ToggleCommand.dungeonTimerToggled)); + skillTracker = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Toggle Skill XP/Hour Tracking"); + outlineText = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Outline Displayed Text: " + Utils.getColouredBoolean(ToggleCommand.outlineTextToggled)); + splitFishing = new GuiButton(0, width / 2 - 100, (int) (height * 0.6), "Split Fishing Display: " + Utils.getColouredBoolean(ToggleCommand.splitFishing)); coords = new GuiButton(0, width / 2 - 100, (int) (height * 0.7), "Coordinate/Angle Display: " + Utils.getColouredBoolean(ToggleCommand.coordsToggled)); // Page 2 - cakeTimer = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Cake Timer: " + Utils.getColouredBoolean(ToggleCommand.cakeTimerToggled)); - skill50Display = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Display Progress To Skill Level 50: " + Utils.getColouredBoolean(ToggleCommand.skill50DisplayToggled)); - gparty = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Guild Party Notifications: " + Utils.getColouredBoolean(ToggleCommand.gpartyToggled)); + dungeonTimer = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Display Dungeon Timers: " + Utils.getColouredBoolean(ToggleCommand.dungeonTimerToggled)); + cakeTimer = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Cake Timer: " + Utils.getColouredBoolean(ToggleCommand.cakeTimerToggled)); + skill50Display = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Display Progress To Skill Level 50: " + Utils.getColouredBoolean(ToggleCommand.skill50DisplayToggled)); slayerCount = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Count Total 20% Drops: " + Utils.getColouredBoolean(ToggleCommand.slayerCountTotal)); chatMaddox = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Click On-Screen to Open Maddox: " + Utils.getColouredBoolean(ToggleCommand.chatMaddoxToggled)); aotd = new GuiButton(0, width / 2 - 100, (int) (height * 0.6), "Disable AOTD Ability: " + Utils.getColouredBoolean(ToggleCommand.aotdToggled)); lividDagger = new GuiButton(0, width / 2 - 100, (int) (height * 0.7), "Disable Livid Dagger Ability: " + Utils.getColouredBoolean(ToggleCommand.lividDaggerToggled)); // Page 3 - spiritBearAlert = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Spirit Bear Spawn Alerts: " + Utils.getColouredBoolean(ToggleCommand.spiritBearAlerts)); - sceptreMessages = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Spirit Sceptre Messages: " + Utils.getColouredBoolean(ToggleCommand.sceptreMessages)); - midasStaffMessages = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Midas Staff Messages: " + Utils.getColouredBoolean(ToggleCommand.midasStaffMessages)); - healMessages = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Heal Messages: " + Utils.getColouredBoolean(ToggleCommand.healMessages)); - goldenEnch = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Golden T10/T6/T4 Enchantments: " + Utils.getColouredBoolean(ToggleCommand.goldenToggled)); - petColours = new GuiButton(0, width / 2 - 100, (int) (height * 0.6), "Colour Pet Backgrounds: " + Utils.getColouredBoolean(ToggleCommand.petColoursToggled)); - expertiseLore = new GuiButton(0, width / 2 - 100, (int) (height * 0.7), "Expertise Kills In Lore: " + Utils.getColouredBoolean(ToggleCommand.expertiseLoreToggled)); + gparty = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Guild Party Notifications: " + Utils.getColouredBoolean(ToggleCommand.gpartyToggled)); + spiritBearAlert = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Spirit Bear Spawn Alerts: " + Utils.getColouredBoolean(ToggleCommand.spiritBearAlerts)); + sceptreMessages = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Spirit Sceptre Messages: " + Utils.getColouredBoolean(ToggleCommand.sceptreMessages)); + midasStaffMessages = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "Midas Staff Messages: " + Utils.getColouredBoolean(ToggleCommand.midasStaffMessages)); + healMessages = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Heal Messages: " + Utils.getColouredBoolean(ToggleCommand.healMessages)); + goldenEnch = new GuiButton(0, width / 2 - 100, (int) (height * 0.6), "Golden T10/T6/T4 Enchantments: " + Utils.getColouredBoolean(ToggleCommand.goldenToggled)); + petColours = new GuiButton(0, width / 2 - 100, (int) (height * 0.7), "Colour Pet Backgrounds: " + Utils.getColouredBoolean(ToggleCommand.petColoursToggled)); // Page 4 - lividSolver = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Find Correct Livid: " + Utils.getColouredBoolean(ToggleCommand.lividSolverToggled)); - golemAlerts = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Alert When Golem Spawns: " + Utils.getColouredBoolean(ToggleCommand.golemAlertToggled)); - rngesusAlert = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "RNGesus Alerts: " + Utils.getColouredBoolean(ToggleCommand.rngesusAlerts)); + expertiseLore = new GuiButton(0, width / 2 - 100, (int) (height * 0.1), "Expertise Kills In Lore: " + Utils.getColouredBoolean(ToggleCommand.expertiseLoreToggled)); + lividSolver = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Find Correct Livid: " + Utils.getColouredBoolean(ToggleCommand.lividSolverToggled)); + golemAlerts = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Alert When Golem Spawns: " + Utils.getColouredBoolean(ToggleCommand.golemAlertToggled)); + rngesusAlert = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "RNGesus Alerts: " + Utils.getColouredBoolean(ToggleCommand.rngesusAlerts)); if (page == 1) { this.buttonList.add(changeDisplay); this.buttonList.add(onlySlayer); this.buttonList.add(puzzleSolvers); + this.buttonList.add(skillTracker); this.buttonList.add(outlineText); this.buttonList.add(splitFishing); - this.buttonList.add(dungeonTimer); this.buttonList.add(coords); this.buttonList.add(nextPage); } else if (page == 2) { + this.buttonList.add(dungeonTimer); this.buttonList.add(cakeTimer); this.buttonList.add(skill50Display); - this.buttonList.add(gparty); this.buttonList.add(slayerCount); this.buttonList.add(chatMaddox); this.buttonList.add(aotd); @@ -123,16 +125,17 @@ public class DankerGui extends GuiScreen { this.buttonList.add(nextPage); this.buttonList.add(backPage); } else if (page == 3) { + this.buttonList.add(gparty); this.buttonList.add(spiritBearAlert); this.buttonList.add(sceptreMessages); this.buttonList.add(midasStaffMessages); this.buttonList.add(healMessages); this.buttonList.add(goldenEnch); this.buttonList.add(petColours); - this.buttonList.add(expertiseLore); this.buttonList.add(nextPage); this.buttonList.add(backPage); } else if (page == 4) { + this.buttonList.add(expertiseLore); this.buttonList.add(lividSolver); this.buttonList.add(golemAlerts); this.buttonList.add(rngesusAlert); @@ -179,6 +182,8 @@ public class DankerGui extends GuiScreen { TheMod.guiToOpen = "onlyslayergui"; } else if (button == puzzleSolvers) { TheMod.guiToOpen = "puzzlesolvers"; + } else if (button == skillTracker) { + TheMod.guiToOpen = "skilltracker"; } else if (button == outlineText) { ToggleCommand.outlineTextToggled = !ToggleCommand.outlineTextToggled; ConfigHandler.writeBooleanConfig("toggles", "OutlineText", ToggleCommand.outlineTextToggled); diff --git a/src/main/java/me/Danker/gui/EditLocationsGui.java b/src/main/java/me/Danker/gui/EditLocationsGui.java index 7e67c1e..75caf6a 100644 --- a/src/main/java/me/Danker/gui/EditLocationsGui.java +++ b/src/main/java/me/Danker/gui/EditLocationsGui.java @@ -25,6 +25,7 @@ public class EditLocationsGui extends GuiScreen { private LocationButton skill50; private LocationButton lividHP; private LocationButton cakeTimer; + private LocationButton skillTracker; @Override public boolean doesGuiPauseGame() { @@ -71,17 +72,23 @@ public class EditLocationsGui extends GuiScreen { EnumChatFormatting.YELLOW + 2 + "\n" + EnumChatFormatting.YELLOW + 1; + String skillTrackerText = TheMod.SKILL_TRACKER_COLOUR + "Farming XP Earned: 462,425.3\n" + + TheMod.SKILL_TRACKER_COLOUR + "Time Elapsed: " + Utils.getTimeBetween(0, 3602) + "\n" + + TheMod.SKILL_TRACKER_COLOUR + "XP Per Hour: 462,168"; + display = new LocationButton(0, MoveCommand.displayXY[0], MoveCommand.displayXY[1], 145 * ScaleCommand.displayScale, 102 * ScaleCommand.displayScale, ScaleCommand.displayScale, displayText, displayNums, 110); dungeonTimer = new LocationButton(0, MoveCommand.dungeonTimerXY[0], MoveCommand.dungeonTimerXY[1], 113 * ScaleCommand.dungeonTimerScale, 57 * ScaleCommand.dungeonTimerScale, ScaleCommand.dungeonTimerScale, dungeonTimerText, dungeonTimerNums, 80); coords = new LocationButton(0, MoveCommand.coordsXY[0], MoveCommand.coordsXY[1], 141 * ScaleCommand.coordsScale, 12 * ScaleCommand.coordsScale, ScaleCommand.coordsScale, TheMod.COORDS_COLOUR + "74 / 14 / -26 (141.1 / 6.7)", null, null); skill50 = new LocationButton(0, MoveCommand.skill50XY[0], MoveCommand.skill50XY[1], 233 * ScaleCommand.skill50Scale, 12 * ScaleCommand.skill50Scale, ScaleCommand.skill50Scale, TheMod.SKILL_50_COLOUR + "+3.5 Farming (28,882,117.7/55,172,425) 52.34%", null, null); lividHP = new LocationButton(0, MoveCommand.lividHpXY[0], MoveCommand.lividHpXY[1], 85 * ScaleCommand.lividHpScale, 12 * ScaleCommand.lividHpScale, ScaleCommand.lividHpScale, EnumChatFormatting.WHITE + "﴾ Livid " + EnumChatFormatting.YELLOW + "6.9M" + EnumChatFormatting.RED + "❤ " + EnumChatFormatting.WHITE + "﴿", null, null); cakeTimer = new LocationButton(0, MoveCommand.cakeTimerXY[0], MoveCommand.cakeTimerXY[1] + 5, 85 * ScaleCommand.cakeTimerScale, 18 * ScaleCommand.cakeTimerScale, ScaleCommand.cakeTimerScale, TheMod.CAKE_COLOUR + " 11h16m", null, null); + skillTracker = new LocationButton(0, MoveCommand.skillTrackerXY[0], MoveCommand.skillTrackerXY[1], 150 * ScaleCommand.skillTrackerScale, 28 * ScaleCommand.skillTrackerScale, ScaleCommand.skillTrackerScale, skillTrackerText, null, null); this.buttonList.add(coords); this.buttonList.add(dungeonTimer); this.buttonList.add(lividHP); this.buttonList.add(cakeTimer); + this.buttonList.add(skillTracker); this.buttonList.add(display); this.buttonList.add(skill50); } @@ -136,6 +143,11 @@ public class EditLocationsGui extends GuiScreen { MoveCommand.cakeTimerXY[1] += yMoved; cakeTimer.xPosition = MoveCommand.cakeTimerXY[0]; cakeTimer.yPosition = MoveCommand.cakeTimerXY[1]; + } else if (moving.equals("skillTracker")) { + MoveCommand.skillTrackerXY[0] += xMoved; + MoveCommand.skillTrackerXY[1] += yMoved; + skillTracker.xPosition = MoveCommand.skillTrackerXY[0]; + skillTracker.yPosition = MoveCommand.skillTrackerXY[1]; } this.buttonList.clear(); initGui(); @@ -160,6 +172,8 @@ public class EditLocationsGui extends GuiScreen { moving = "lividHP"; } else if (button == cakeTimer) { moving = "cakeTimer"; + } else if (button == skillTracker) { + moving = "skillTracker"; } } } @@ -180,6 +194,8 @@ public class EditLocationsGui extends GuiScreen { ConfigHandler.writeIntConfig("locations", "lividHpY", MoveCommand.lividHpXY[1]); ConfigHandler.writeIntConfig("locations", "cakeTimerX", MoveCommand.cakeTimerXY[0]); ConfigHandler.writeIntConfig("locations", "cakeTimerY", MoveCommand.cakeTimerXY[1]); + ConfigHandler.writeIntConfig("locations", "skillTrackerX", MoveCommand.skillTrackerXY[0]); + ConfigHandler.writeIntConfig("locations", "skillTrackerY", MoveCommand.skillTrackerXY[1]); } } diff --git a/src/main/java/me/Danker/gui/SkillTrackerGui.java b/src/main/java/me/Danker/gui/SkillTrackerGui.java new file mode 100644 index 0000000..9672890 --- /dev/null +++ b/src/main/java/me/Danker/gui/SkillTrackerGui.java @@ -0,0 +1,99 @@ +package me.Danker.gui; + +import org.apache.commons.lang3.time.StopWatch; + +import me.Danker.TheMod; +import me.Danker.handlers.ConfigHandler; +import me.Danker.handlers.TextRenderer; +import net.minecraft.client.Minecraft; +import net.minecraft.client.gui.GuiButton; +import net.minecraft.client.gui.GuiScreen; +import net.minecraft.client.gui.ScaledResolution; + +public class SkillTrackerGui extends GuiScreen { + + private GuiButton goBack; + private GuiButton start; + private GuiButton stop; + private GuiButton reset; + private GuiButton hide; + private GuiButton show; + + @Override + public boolean doesGuiPauseGame() { + return false; + } + + @Override + public void initGui() { + super.initGui(); + + ScaledResolution sr = new ScaledResolution(Minecraft.getMinecraft()); + int height = sr.getScaledHeight(); + int width = sr.getScaledWidth(); + + goBack = new GuiButton(0, 2, height - 30, 100, 20, "Go Back"); + start = new GuiButton(0, width / 2 - 140, (int) (height * 0.45), 80, 20, "Start"); + stop = new GuiButton(0, width / 2 - 40, (int) (height * 0.45), 80, 20, "Stop"); + reset = new GuiButton(0, width / 2 + 60, (int) (height * 0.45), 80, 20, "Reset"); + hide = new GuiButton(0, width / 2 - 70, (int) (height * 0.55), 60, 20, "Hide"); + show = new GuiButton(0, width / 2 + 10, (int) (height * 0.55), 60, 20, "Show"); + + this.buttonList.add(start); + this.buttonList.add(stop); + this.buttonList.add(reset); + this.buttonList.add(hide); + this.buttonList.add(show); + this.buttonList.add(goBack); + } + + @Override + public void drawScreen(int mouseX, int mouseY, float partialTicks) { + this.drawDefaultBackground(); + String stateText = ""; + if (TheMod.skillStopwatch.isStarted() && !TheMod.skillStopwatch.isSuspended()) { + stateText = "Timer: Running"; + } else if (!TheMod.skillStopwatch.isStarted() || TheMod.skillStopwatch.isSuspended()) { + stateText = "Timer: Paused"; + } + if (!TheMod.showSkillTracker) { + stateText += " (Hidden)"; + } + int stateTextWidth = mc.fontRendererObj.getStringWidth(stateText); + new TextRenderer(mc, stateText, width / 2 - stateTextWidth / 2, 10, 1D); + super.drawScreen(mouseX, mouseY, partialTicks); + } + + @Override + public void actionPerformed(GuiButton button) { + if (button == goBack) { + TheMod.guiToOpen = "dankergui1"; + } else if (button == start) { + if (TheMod.skillStopwatch.isStarted() && TheMod.skillStopwatch.isSuspended()) { + TheMod.skillStopwatch.resume(); + } else if (!TheMod.skillStopwatch.isStarted()) { + TheMod.skillStopwatch.start(); + } + } else if (button == stop) { + if (TheMod.skillStopwatch.isStarted() && !TheMod.skillStopwatch.isSuspended()) { + TheMod.skillStopwatch.suspend(); + } + } else if (button == reset) { + TheMod.skillStopwatch = new StopWatch(); + TheMod.farmingXPGained = 0; + TheMod.miningXPGained = 0; + TheMod.combatXPGained = 0; + TheMod.foragingXPGained = 0; + TheMod.fishingXPGained = 0; + TheMod.enchantingXPGained = 0; + TheMod.alchemyXPGained = 0; + } else if (button == hide) { + TheMod.showSkillTracker = false; + ConfigHandler.writeBooleanConfig("misc", "showSkillTracker", false); + } else if (button == show) { + TheMod.showSkillTracker = true; + ConfigHandler.writeBooleanConfig("misc", "showSkillTracker", true); + } + } + +} diff --git a/src/main/java/me/Danker/handlers/ConfigHandler.java b/src/main/java/me/Danker/handlers/ConfigHandler.java index 6318abb..b9bc860 100644 --- a/src/main/java/me/Danker/handlers/ConfigHandler.java +++ b/src/main/java/me/Danker/handlers/ConfigHandler.java @@ -341,6 +341,7 @@ public class ConfigHandler { if (!hasKey("catacombs", "implosion")) writeIntConfig("catacombs", "implosion", 0); if (!hasKey("catacombs", "witherShield")) writeIntConfig("catacombs", "witherShield", 0); if (!hasKey("catacombs", "shadowWarp")) writeIntConfig("catacombs", "shadowWarp", 0); + if (!hasKey("catacombs", "necronsHandle")) writeIntConfig("catacombs", "necronsHandle", 0); if (!hasKey("catacombs", "autoRecomb")) writeIntConfig("catacombs", "autoRecomb", 0); if (!hasKey("catacombs", "witherHelm")) writeIntConfig("catacombs", "witherHelm", 0); if (!hasKey("catacombs", "witherChest")) writeIntConfig("catacombs", "witherChest", 0); @@ -353,6 +354,7 @@ public class ConfigHandler { if (!hasKey("misc", "autoDisplay")) writeBooleanConfig("misc", "autoDisplay", false); if (!hasKey("misc", "skill50Time")) writeIntConfig("misc", "skill50Time", 3); if (!hasKey("misc", "cakeTime")) writeDoubleConfig("misc", "cakeTime", 0); + if (!hasKey("misc", "showSkillTracker")) writeBooleanConfig("misc", "showSkillTracker", false); ScaledResolution scaled = new ScaledResolution(Minecraft.getMinecraft()); int height = scaled.getScaledHeight(); @@ -368,12 +370,15 @@ public class ConfigHandler { if (!hasKey("locations", "lividHpY")) writeIntConfig("locations", "lividHpY", 20); if (!hasKey("locations", "cakeTimerX")) writeIntConfig("locations", "cakeTimerX", 40); if (!hasKey("locations", "cakeTimerY")) writeIntConfig("locations", "cakeTimerY", 30); + if (!hasKey("locations", "skillTrackerX")) writeIntConfig("locations", "skillTrackerX", 40); + if (!hasKey("locations", "skillTrackerY")) writeIntConfig("locations", "skillTrackerY", 50); if (!hasKey("scales", "coordsScale")) writeDoubleConfig("scales", "coordsScale", 1); if (!hasKey("scales", "displayScale")) writeDoubleConfig("scales", "displayScale", 1); if (!hasKey("scales", "dungeonTimerScale")) writeDoubleConfig("scales", "dungeonTimerScale", 1); if (!hasKey("scales", "skill50Scale")) writeDoubleConfig("scales", "skill50Scale", 1); if (!hasKey("scales", "lividHpScale")) writeDoubleConfig("scales", "lividHpScale", 1); if (!hasKey("scales", "cakeTimerScale")) writeDoubleConfig("scales", "cakeTimerScale", 1); + if (!hasKey("scales", "skillTrackerScale")) writeDoubleConfig("scales", "skillTrackerScale", 1); if (!hasKey("colors", "main")) writeStringConfig("colors", "main", "" + EnumChatFormatting.GREEN); if (!hasKey("colors", "secondary")) writeStringConfig("colors", "secondary", "" + EnumChatFormatting.DARK_GREEN); @@ -386,6 +391,7 @@ public class ConfigHandler { if (!hasKey("colors", "skill50Display")) writeStringConfig("colors", "skill50Display", "" + EnumChatFormatting.AQUA); if (!hasKey("colors", "coordsDisplay")) writeStringConfig("colors", "coordsDisplay", "" + EnumChatFormatting.WHITE); if (!hasKey("colors", "cakeDisplay")) writeStringConfig("colors", "cakeDisplay", "" + EnumChatFormatting.GOLD); + if (!hasKey("colors", "skillTracker")) writeStringConfig("colors", "skillTracker", "" + EnumChatFormatting.AQUA); ToggleCommand.gpartyToggled = getBoolean("toggles", "GParty"); ToggleCommand.coordsToggled = getBoolean("toggles", "Coords"); @@ -559,6 +565,7 @@ public class ConfigHandler { LootCommand.implosions = getInt("catacombs", "implosion"); LootCommand.witherShields = getInt("catacombs", "witherShield"); LootCommand.shadowWarps = getInt("catacombs", "shadowWarp"); + LootCommand.necronsHandles = getInt("catacombs", "necronsHandle"); LootCommand.autoRecombs = getInt("catacombs", "autoRecomb"); LootCommand.witherHelms = getInt("catacombs", "witherHelm"); LootCommand.witherChests = getInt("catacombs", "witherChest"); @@ -572,6 +579,7 @@ public class ConfigHandler { DisplayCommand.auto = getBoolean("misc", "autoDisplay"); TheMod.SKILL_TIME = getInt("misc", "skill50Time") * 20; TheMod.cakeTime = getDouble("misc", "cakeTime"); + TheMod.showSkillTracker = getBoolean("misc", "showSkillTracker"); MoveCommand.coordsXY[0] = getInt("locations", "coordsX"); MoveCommand.coordsXY[1] = getInt("locations", "coordsY"); @@ -585,6 +593,8 @@ public class ConfigHandler { MoveCommand.lividHpXY[1] = getInt("locations", "lividHpY"); MoveCommand.cakeTimerXY[0] = getInt("locations", "cakeTimerX"); MoveCommand.cakeTimerXY[1] = getInt("locations", "cakeTimerY"); + MoveCommand.skillTrackerXY[0] = getInt("locations", "skillTrackerX"); + MoveCommand.skillTrackerXY[1] = getInt("locations", "skillTrackerY"); ScaleCommand.coordsScale = getDouble("scales", "coordsScale"); ScaleCommand.displayScale = getDouble("scales", "displayScale"); @@ -592,6 +602,7 @@ public class ConfigHandler { ScaleCommand.skill50Scale = getDouble("scales", "skill50Scale"); ScaleCommand.lividHpScale = getDouble("scales", "lividHpScale"); ScaleCommand.cakeTimerScale = getDouble("scales", "cakeTimerScale"); + ScaleCommand.skillTrackerScale = getDouble("scales", "skillTrackerScale"); TheMod.MAIN_COLOUR = getString("colors", "main"); TheMod.SECONDARY_COLOUR = getString("colors", "secondary"); @@ -604,6 +615,7 @@ public class ConfigHandler { TheMod.SKILL_50_COLOUR = getString("colors", "skill50Display"); TheMod.COORDS_COLOUR = getString("colors", "coordsDisplay"); TheMod.CAKE_COLOUR = getString("colors", "cakeDisplay"); + TheMod.SKILL_TRACKER_COLOUR = getString("colors", "skillTracker"); } } diff --git a/src/main/java/me/Danker/utils/Utils.java b/src/main/java/me/Danker/utils/Utils.java index 7416c8e..4361f8f 100644 --- a/src/main/java/me/Danker/utils/Utils.java +++ b/src/main/java/me/Danker/utils/Utils.java @@ -37,10 +37,10 @@ public class Utils { public static boolean inSkyblock = false; public static boolean inDungeons = false; public static int[] skillXPPerLevel = {0, 50, 125, 200, 300, 500, 750, 1000, 1500, 2000, 3500, 5000, 7500, 10000, 15000, 20000, 30000, 50000, - 75000, 100000, 200000, 300000, 400000, 500000, 600000, 700000, 800000, 900000, 1000000, 1100000, - 1200000, 1300000, 1400000, 1500000, 1600000, 1700000, 1800000, 1900000, 2000000, 2100000, 2200000, - 2300000, 2400000, 2500000, 2600000, 2750000, 2900000, 3100000, 3400000, 3700000, 4000000, 4300000, - 4600000, 4900000, 5200000, 5500000, 5800000, 6100000, 6400000, 6700000, 7000000}; + 75000, 100000, 200000, 300000, 400000, 500000, 600000, 700000, 800000, 900000, 1000000, 1100000, + 1200000, 1300000, 1400000, 1500000, 1600000, 1700000, 1800000, 1900000, 2000000, 2100000, 2200000, + 2300000, 2400000, 2500000, 2600000, 2750000, 2900000, 3100000, 3400000, 3700000, 4000000, 4300000, + 4600000, 4900000, 5200000, 5500000, 5800000, 6100000, 6400000, 6700000, 7000000}; static int[] dungeonsXPPerLevel = {0, 50, 75, 110, 160, 230, 330, 470, 670, 950, 1340, 1890, 2665, 3760, 5260, 7380, 10300, 14400, 20000, 27600, 38000, 52500, 71500, 97000, 132000, 180000, 243000, 328000, 445000, 600000, 800000, 1065000, 1410000, 1900000, 2500000, 3300000, 4300000, 5600000, 7200000, 9200000, 12000000, 15000000, diff --git a/src/main/resources/mcmod.info b/src/main/resources/mcmod.info index 6070c23..68f25be 100644 --- a/src/main/resources/mcmod.info +++ b/src/main/resources/mcmod.info @@ -6,7 +6,6 @@ "version": "${version}", "mcversion": "${mcversion}", "url": "https://github.com/bowser0000/SkyblockMod", - "authorList": ["Danker"], - "credits": "smyt for parsing scoreboard info." + "authorList": ["Danker"] } ] -- cgit From 1850983cc3b17e64974ebcadcca1bda5edf4db23 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Tue, 24 Nov 2020 22:00:58 -0500 Subject: Add mythological event tracker that *might* work, bug fixes and changes Fix Wither Cloak triggering creeper solver Update README with more better information Replace most else ifs with switch statements Add Necron's Handle to /resetloot catacombs Update trivia answers --- README.md | 34 +- src/main/java/me/Danker/TheMod.java | 1741 +++++++++++--------- .../me/Danker/commands/BlockSlayerCommand.java | 34 +- src/main/java/me/Danker/commands/DHelpCommand.java | 6 +- .../java/me/Danker/commands/DisplayCommand.java | 190 ++- src/main/java/me/Danker/commands/LootCommand.java | 1066 ++++++------ src/main/java/me/Danker/commands/MoveCommand.java | 96 +- .../java/me/Danker/commands/ResetLootCommand.java | 104 +- src/main/java/me/Danker/commands/ScaleCommand.java | 70 +- .../java/me/Danker/commands/ToggleCommand.java | 294 ++-- src/main/java/me/Danker/gui/DisplayGui.java | 21 +- .../java/me/Danker/handlers/ConfigHandler.java | 24 + 12 files changed, 2023 insertions(+), 1657 deletions(-) (limited to 'src/main/java/me/Danker/gui') diff --git a/README.md b/README.md index c0ab188..ca46bc2 100644 --- a/README.md +++ b/README.md @@ -9,28 +9,30 @@ Discord Server: https://discord.gg/QsEkNQS - LabyMod + Sidebar Mod Revamp - Displays don't show ## Current features -- Guild party desktop notifications (toggleable) -- Coordinate and angle display (toggleable, graphic display) (scalable) -- Golden T10/T6/T4 enchant display (toggleable) -- Block AOTD ability (toggleable) -- Disable Spirit Sceptre messages (toggleable) -- Disable Midas Staff messages (toggleable) -- Disable heal messages (toggleable) -- Slayer item tracker (with graphic display) (scalable) -- RNGesus drop alerts (toggleable) -- Click anywhere on-screen to open Maddox (toggleable) -- Maddox Menu keybind +- Guild party desktop notifications +- Coordinate and angle display +- Golden T10/T6/T4 enchant display +- Block AOTD ability +- Block Livid Dagger ability +- Disable Spirit Sceptre messages +- Disable Midas Staff messages +- Disable heal messages +- Slayer item tracker +- RNGesus drop alerts +- Click anywhere on-screen to open Maddox +- Maddox menu keybind - Block starting other slayer quests -- Fishing tracker (with graphic display) (scalable) +- Fishing, jerry fishing, fishing festival, spooky fishing trackers - Expertise kills in fishing rod lore -- Dungeons tracker (with graphic display) (scalable) -- Dungeons puzzle solver (Riddle, trivia, blaze, creeper) (toggleable) -- Find correct Livid (with graphic display of HP) (toggleable) +- Catacombs trackers +- Dungeons puzzle solver (Riddle, trivia, blaze, creeper, water) +- Find correct Livid (with graphic display of HP) - Pet background colors based on level -- Golem spawning alerts (toggleable) +- Golem spawning alerts - Skill xp/hour tracker - Show total skill xp instead of progress to next level - Show time until century cakes run out +- Mythological event (Diana) tracker - API commands - Update checker diff --git a/src/main/java/me/Danker/TheMod.java b/src/main/java/me/Danker/TheMod.java index 5c992ae..fbe9633 100644 --- a/src/main/java/me/Danker/TheMod.java +++ b/src/main/java/me/Danker/TheMod.java @@ -265,9 +265,11 @@ public class TheMod triviaSolutions.put("What is the name of the lady of the Nether?", new String[]{"Elle"}); triviaSolutions.put("Which villager in the Village gives you a Rogue Sword?", new String[]{"Jamie"}); triviaSolutions.put("How many unique minions are there?", new String[]{"52 Minions"}); - triviaSolutions.put("Which of these enemies does not spawn in the Spider's Den?", new String[]{"Zombie Spider", "Cave Spider", "Wither Skeleton", "Dashing Spooder", "Broodfather", "Night Spider"}); + triviaSolutions.put("Which of these enemies does not spawn in the Spider's Den?", new String[]{"Zombie Spider", "Cave Spider", "Wither Skeleton", + "Dashing Spooder", "Broodfather", "Night Spider"}); triviaSolutions.put("Which of these monsters only spawns at night?", new String[]{"Zombie Villager", "Ghast"}); - triviaSolutions.put("Which of these is not a dragon in The End?", new String[]{"Zoomer Dragon", "Weak Dragon", "Stonk Dragon", "Holy Dragon", "Boomer Dragon", "Booger Dragon", "Older Dragon", "Elder Dragon"}); + triviaSolutions.put("Which of these is not a dragon in The End?", new String[]{"Zoomer Dragon", "Weak Dragon", "Stonk Dragon", "Holy Dragon", "Boomer Dragon", + "Booger Dragon", "Older Dragon", "Elder Dragon", "Stable Dragon", "Professor Dragon"}); String patternString = "(" + String.join("|", t6Enchants.keySet()) + ")"; pattern = Pattern.compile(patternString); @@ -954,6 +956,52 @@ public class TheMod ConfigHandler.writeIntConfig("zombie", "bossRNG", 0); } + // Mythological Tracker + if (message.contains("You dug out")) { + if (message.contains(" coins!")) { + double coinsEarned = Double.parseDouble(message.replaceAll("[^\\d]", "")); + LootCommand.mythCoins += coinsEarned; + LootCommand.mythCoinsSession += coinsEarned; + ConfigHandler.writeDoubleConfig("mythological", "coins", LootCommand.mythCoins); + } else if (message.contains("a Griffin Feather!")) { + LootCommand.griffinFeathers++; + LootCommand.griffinFeathersSession++; + ConfigHandler.writeIntConfig("mythological", "griffinFeather", LootCommand.griffinFeathers); + } else if (message.contains("a Crown of Greed!")) { + LootCommand.crownOfGreeds++; + LootCommand.crownOfGreedsSession++; + ConfigHandler.writeIntConfig("mythological", "crownOfGreed", LootCommand.crownOfGreeds); + } else if (message.contains("a Washed-up Souvenir!")) { + LootCommand.washedUpSouvenirs++; + LootCommand.washedUpSouvenirsSession++; + ConfigHandler.writeIntConfig("mythological", "washedUpSouvenir", LootCommand.washedUpSouvenirs); + } else if (message.contains("a Minos Hunter!")) { + LootCommand.minosHunters++; + LootCommand.minosHuntersSession++; + ConfigHandler.writeIntConfig("mythological", "minosHunter", LootCommand.minosHunters); + } else if (message.contains("Siamese Lynxes!!")) { + LootCommand.siameseLynxes++; + LootCommand.siameseLynxesSession++; + ConfigHandler.writeIntConfig("mythological", "siameseLynx", LootCommand.siameseLynxes); + } else if (message.contains("a Minotaur!")) { + LootCommand.minotaurs++; + LootCommand.minotaursSession++; + ConfigHandler.writeIntConfig("mythological", "minotaur", LootCommand.minotaurs); + } else if (message.contains("a Gaia Construct!")) { + LootCommand.gaiaConstructs++; + LootCommand.gaiaConstructsSession++; + ConfigHandler.writeIntConfig("mythological", "gaiaConstruct", LootCommand.gaiaConstructs); + } else if (message.contains("a Minos Champion!")) { + LootCommand.minosChampions++; + LootCommand.minosChampionsSession++; + ConfigHandler.writeIntConfig("mythological", "minosChampion", LootCommand.minosChampions); + } else if (message.contains("a Minos Inquisitor!")) { + LootCommand.minosInquisitors++; + LootCommand.minosInquisitorsSession++; + ConfigHandler.writeIntConfig("mythological", "minosInquisitor", LootCommand.minosInquisitors); + } + } + // Dungeons Trackers if (message.contains(" ")) { if (message.contains("Recombobulator 3000")) { @@ -1264,806 +1312,881 @@ public class TheMod if (!DisplayCommand.display.equals("off")) { String dropsText = ""; String countText = ""; + String dropsTextTwo = ""; + String countTextTwo = ""; String timeBetween = "Never"; String bossesBetween = "Never"; String drop20; double timeNow = System.currentTimeMillis() / 1000; NumberFormat nf = NumberFormat.getIntegerInstance(Locale.US); - if (DisplayCommand.display.equals("wolf")) { - if (LootCommand.wolfTime == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(LootCommand.wolfTime, timeNow); - } - if (LootCommand.wolfBosses == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(LootCommand.wolfBosses); - } - if (ToggleCommand.slayerCountTotal) { - drop20 = nf.format(LootCommand.wolfWheels); - } else { - drop20 = nf.format(LootCommand.wolfWheelsDrops) + " times"; - } - - dropsText = EnumChatFormatting.GOLD + "Svens Killed:\n" + - EnumChatFormatting.GREEN + "Wolf Teeth:\n" + - EnumChatFormatting.BLUE + "Hamster Wheels:\n" + - EnumChatFormatting.AQUA + "Spirit Runes:\n" + - EnumChatFormatting.WHITE + "Critical VI Books:\n" + - EnumChatFormatting.DARK_RED + "Red Claw Eggs:\n" + - EnumChatFormatting.GOLD + "Couture Runes:\n" + - EnumChatFormatting.AQUA + "Grizzly Baits:\n" + - EnumChatFormatting.DARK_PURPLE + "Overfluxes:\n" + - EnumChatFormatting.AQUA + "Time Since RNG:\n" + - EnumChatFormatting.AQUA + "Bosses Since RNG:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.wolfSvens) + "\n" + - EnumChatFormatting.GREEN + nf.format(LootCommand.wolfTeeth) + "\n" + - EnumChatFormatting.BLUE + drop20 + "\n" + - EnumChatFormatting.AQUA + LootCommand.wolfSpirits + "\n" + - EnumChatFormatting.WHITE + LootCommand.wolfBooks + "\n" + - EnumChatFormatting.DARK_RED + LootCommand.wolfEggs + "\n" + - EnumChatFormatting.GOLD + LootCommand.wolfCoutures + "\n" + - EnumChatFormatting.AQUA + LootCommand.wolfBaits + "\n" + - EnumChatFormatting.DARK_PURPLE + LootCommand.wolfFluxes + "\n" + - EnumChatFormatting.AQUA + timeBetween + "\n" + - EnumChatFormatting.AQUA + bossesBetween; - } else if (DisplayCommand.display.equals("wolf_session")) { - if (LootCommand.wolfTimeSession == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(LootCommand.wolfTimeSession, timeNow); - } - if (LootCommand.wolfBossesSession == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(LootCommand.wolfBossesSession); - } - if (ToggleCommand.slayerCountTotal) { - drop20 = nf.format(LootCommand.wolfWheelsSession); - } else { - drop20 = nf.format(LootCommand.wolfWheelsDropsSession) + " times"; - } - - dropsText = EnumChatFormatting.GOLD + "Svens Killed:\n" + - EnumChatFormatting.GREEN + "Wolf Teeth:\n" + - EnumChatFormatting.BLUE + "Hamster Wheels:\n" + - EnumChatFormatting.AQUA + "Spirit Runes:\n" + - EnumChatFormatting.WHITE + "Critical VI Books:\n" + - EnumChatFormatting.DARK_RED + "Red Claw Eggs:\n" + - EnumChatFormatting.GOLD + "Couture Runes:\n" + - EnumChatFormatting.AQUA + "Grizzly Baits:\n" + - EnumChatFormatting.DARK_PURPLE + "Overfluxes:\n" + - EnumChatFormatting.AQUA + "Time Since RNG:\n" + - EnumChatFormatting.AQUA + "Bosses Since RNG:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.wolfSvensSession) + "\n" + - EnumChatFormatting.GREEN + nf.format(LootCommand.wolfTeethSession) + "\n" + - EnumChatFormatting.BLUE + drop20 + "\n" + - EnumChatFormatting.AQUA + LootCommand.wolfSpiritsSession + "\n" + - EnumChatFormatting.WHITE + LootCommand.wolfBooksSession + "\n" + - EnumChatFormatting.DARK_RED + LootCommand.wolfEggsSession + "\n" + - EnumChatFormatting.GOLD + LootCommand.wolfCouturesSession + "\n" + - EnumChatFormatting.AQUA + LootCommand.wolfBaitsSession + "\n" + - EnumChatFormatting.DARK_PURPLE + LootCommand.wolfFluxesSession + "\n" + - EnumChatFormatting.AQUA + timeBetween + "\n" + - EnumChatFormatting.AQUA + bossesBetween; - } else if (DisplayCommand.display.equals("spider")) { - if (LootCommand.spiderTime == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(LootCommand.spiderTime, timeNow); - } - if (LootCommand.spiderBosses == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(LootCommand.spiderBosses); - } - if (ToggleCommand.slayerCountTotal) { - drop20 = nf.format(LootCommand.spiderTAP); - } else { - drop20 = nf.format(LootCommand.spiderTAPDrops) + " times"; - } - - dropsText = EnumChatFormatting.GOLD + "Tarantulas Killed:\n" + - EnumChatFormatting.GREEN + "Tarantula Webs:\n" + - EnumChatFormatting.DARK_GREEN + "Arrow Poison:\n" + - EnumChatFormatting.DARK_GRAY + "Bite Runes:\n" + - EnumChatFormatting.WHITE + "Bane VI Books:\n" + - EnumChatFormatting.AQUA + "Spider Catalysts:\n" + - EnumChatFormatting.DARK_PURPLE + "Tarantula Talismans:\n" + - EnumChatFormatting.LIGHT_PURPLE + "Fly Swatters:\n" + - EnumChatFormatting.GOLD + "Digested Mosquitos:\n" + - EnumChatFormatting.AQUA + "Time Since RNG:\n" + - EnumChatFormatting.AQUA + "Bosses Since RNG:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.spiderTarantulas) + "\n" + - EnumChatFormatting.GREEN + nf.format(LootCommand.spiderWebs) + "\n" + - EnumChatFormatting.DARK_GREEN + drop20 + "\n" + - EnumChatFormatting.DARK_GRAY + LootCommand.spiderBites + "\n" + - EnumChatFormatting.WHITE + LootCommand.spiderBooks + "\n" + - EnumChatFormatting.AQUA + LootCommand.spiderCatalysts + "\n" + - EnumChatFormatting.DARK_PURPLE + LootCommand.spiderTalismans + "\n" + - EnumChatFormatting.LIGHT_PURPLE + LootCommand.spiderSwatters + "\n" + - EnumChatFormatting.GOLD + LootCommand.spiderMosquitos + "\n" + - EnumChatFormatting.AQUA + timeBetween + "\n" + - EnumChatFormatting.AQUA + bossesBetween; - } else if (DisplayCommand.display.equals("spider_session")) { - if (LootCommand.spiderTimeSession == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(LootCommand.spiderTimeSession, timeNow); - } - if (LootCommand.spiderBossesSession == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(LootCommand.spiderBossesSession); - } - if (ToggleCommand.slayerCountTotal) { - drop20 = nf.format(LootCommand.spiderTAPSession); - } else { - drop20 = nf.format(LootCommand.spiderTAPDropsSession) + " times"; - } - - dropsText = EnumChatFormatting.GOLD + "Tarantulas Killed:\n" + - EnumChatFormatting.GREEN + "Tarantula Webs:\n" + - EnumChatFormatting.DARK_GREEN + "Arrow Poison:\n" + - EnumChatFormatting.DARK_GRAY + "Bite Runes:\n" + - EnumChatFormatting.WHITE + "Bane VI Books:\n" + - EnumChatFormatting.AQUA + "Spider Catalysts:\n" + - EnumChatFormatting.DARK_PURPLE + "Tarantula Talismans:\n" + - EnumChatFormatting.LIGHT_PURPLE + "Fly Swatters:\n" + - EnumChatFormatting.GOLD + "Digested Mosquitos:\n" + - EnumChatFormatting.AQUA + "Time Since RNG:\n" + - EnumChatFormatting.AQUA + "Bosses Since RNG:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.spiderTarantulasSession) + "\n" + - EnumChatFormatting.GREEN + nf.format(LootCommand.spiderWebsSession) + "\n" + - EnumChatFormatting.DARK_GREEN + drop20 + "\n" + - EnumChatFormatting.DARK_GRAY + LootCommand.spiderBitesSession + "\n" + - EnumChatFormatting.WHITE + LootCommand.spiderBooksSession + "\n" + - EnumChatFormatting.AQUA + LootCommand.spiderCatalystsSession + "\n" + - EnumChatFormatting.DARK_PURPLE + LootCommand.spiderTalismansSession + "\n" + - EnumChatFormatting.LIGHT_PURPLE + LootCommand.spiderSwattersSession + "\n" + - EnumChatFormatting.GOLD + LootCommand.spiderMosquitosSession + "\n" + - EnumChatFormatting.AQUA + timeBetween + "\n" + - EnumChatFormatting.AQUA + bossesBetween; - } else if (DisplayCommand.display.equals("zombie")) { - if (LootCommand.zombieTime == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(LootCommand.zombieTime, timeNow); - } - if (LootCommand.zombieBosses == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(LootCommand.zombieBosses); - } - if (ToggleCommand.slayerCountTotal) { - drop20 = nf.format(LootCommand.zombieFoulFlesh); - } else { - drop20 = nf.format(LootCommand.zombieFoulFleshDrops) + " times"; - } - - dropsText = EnumChatFormatting.GOLD + "Revs Killed:\n" + - EnumChatFormatting.GREEN + "Revenant Flesh:\n" + - EnumChatFormatting.BLUE + "Foul Flesh:\n" + - EnumChatFormatting.DARK_GREEN + "Pestilence Runes:\n" + - EnumChatFormatting.WHITE + "Smite VI Books:\n" + - EnumChatFormatting.AQUA + "Undead Catalysts:\n" + - EnumChatFormatting.DARK_PURPLE + "Beheaded Horrors:\n" + - EnumChatFormatting.RED + "Revenant Catalysts:\n" + - EnumChatFormatting.DARK_GREEN + "Snake Runes:\n" + - EnumChatFormatting.GOLD + "Scythe Blades:\n" + - EnumChatFormatting.AQUA + "Time Since RNG:\n" + - EnumChatFormatting.AQUA + "Bosses Since RNG:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.zombieRevs) + "\n" + - EnumChatFormatting.GREEN + nf.format(LootCommand.zombieRevFlesh) + "\n" + - EnumChatFormatting.BLUE + drop20 + "\n" + - EnumChatFormatting.DARK_GREEN + LootCommand.zombiePestilences + "\n" + - EnumChatFormatting.WHITE + LootCommand.zombieBooks + "\n" + - EnumChatFormatting.AQUA + LootCommand.zombieUndeadCatas + "\n" + - EnumChatFormatting.DARK_PURPLE + LootCommand.zombieBeheadeds + "\n" + - EnumChatFormatting.RED + LootCommand.zombieRevCatas + "\n" + - EnumChatFormatting.DARK_GREEN + LootCommand.zombieSnakes + "\n" + - EnumChatFormatting.GOLD + LootCommand.zombieScythes + "\n" + - EnumChatFormatting.AQUA + timeBetween + "\n" + - EnumChatFormatting.AQUA + bossesBetween; - } else if (DisplayCommand.display.equals("zombie_session")) { - if (LootCommand.zombieTimeSession == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(LootCommand.zombieTimeSession, timeNow); - } - if (LootCommand.zombieBossesSession == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(LootCommand.zombieBossesSession); - } - if (ToggleCommand.slayerCountTotal) { - drop20 = nf.format(LootCommand.zombieFoulFleshSession); - } else { - drop20 = nf.format(LootCommand.zombieFoulFleshDropsSession) + " times"; - } - - dropsText = EnumChatFormatting.GOLD + "Revs Killed:\n" + - EnumChatFormatting.GREEN + "Revenant Flesh:\n" + - EnumChatFormatting.BLUE + "Foul Flesh:\n" + - EnumChatFormatting.DARK_GREEN + "Pestilence Runes:\n" + - EnumChatFormatting.WHITE + "Smite VI Books:\n" + - EnumChatFormatting.AQUA + "Undead Catalysts:\n" + - EnumChatFormatting.DARK_PURPLE + "Beheaded Horrors:\n" + - EnumChatFormatting.RED + "Revenant Catalysts:\n" + - EnumChatFormatting.DARK_GREEN + "Snake Runes:\n" + - EnumChatFormatting.GOLD + "Scythe Blades:\n" + - EnumChatFormatting.AQUA + "Time Since RNG:\n" + - EnumChatFormatting.AQUA + "Bosses Since RNG:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.zombieRevsSession) + "\n" + - EnumChatFormatting.GREEN + nf.format(LootCommand.zombieRevFleshSession) + "\n" + - EnumChatFormatting.BLUE + drop20 + "\n" + - EnumChatFormatting.DARK_GREEN + LootCommand.zombiePestilencesSession + "\n" + - EnumChatFormatting.WHITE + LootCommand.zombieBooksSession + "\n" + - EnumChatFormatting.AQUA + LootCommand.zombieUndeadCatasSession + "\n" + - EnumChatFormatting.DARK_PURPLE + LootCommand.zombieBeheadedsSession + "\n" + - EnumChatFormatting.RED + LootCommand.zombieRevCatasSession + "\n" + - EnumChatFormatting.DARK_GREEN + LootCommand.zombieSnakesSession + "\n" + - EnumChatFormatting.GOLD + LootCommand.zombieScythes + "\n" + - EnumChatFormatting.AQUA + timeBetween + "\n" + - EnumChatFormatting.AQUA + bossesBetween; - } else if (DisplayCommand.display.equals("fishing")) { - if (LootCommand.empTime == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(LootCommand.empTime, timeNow); - } - if (LootCommand.empSCs == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(LootCommand.empSCs); - } - - dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + - EnumChatFormatting.AQUA + "Fishing Milestone:\n" + - EnumChatFormatting.GOLD + "Good Catches:\n" + - EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + - EnumChatFormatting.GRAY + "Squids:\n" + - EnumChatFormatting.GREEN + "Sea Walkers:\n" + - EnumChatFormatting.DARK_GRAY + "Night Squids:\n" + - EnumChatFormatting.DARK_AQUA + "Sea Guardians:\n" + - EnumChatFormatting.BLUE + "Sea Witches:\n" + - EnumChatFormatting.GREEN + "Sea Archers:"; - countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreatures) + "\n" + - EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestone) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatches) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatches) + "\n" + - EnumChatFormatting.GRAY + nf.format(LootCommand.squids) + "\n" + - EnumChatFormatting.GREEN + nf.format(LootCommand.seaWalkers) + "\n" + - EnumChatFormatting.DARK_GRAY + nf.format(LootCommand.nightSquids) + "\n" + - EnumChatFormatting.DARK_AQUA + nf.format(LootCommand.seaGuardians) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.seaWitches) + "\n" + - EnumChatFormatting.GREEN + nf.format(LootCommand.seaArchers); - // Seperated to save vertical space - String dropsTextTwo = EnumChatFormatting.GREEN + "Monster of Deeps:\n" + - EnumChatFormatting.YELLOW + "Catfishes:\n" + - EnumChatFormatting.GOLD + "Carrot Kings:\n" + - EnumChatFormatting.GRAY + "Sea Leeches:\n" + - EnumChatFormatting.DARK_PURPLE + "Guardian Defenders:\n" + - EnumChatFormatting.DARK_PURPLE + "Deep Sea Protectors:\n" + - EnumChatFormatting.GOLD + "Hydras:\n" + - EnumChatFormatting.GOLD + "Sea Emperors:\n" + - EnumChatFormatting.AQUA + "Time Since Emp:\n" + - EnumChatFormatting.AQUA + "Creatures Since Emp:"; - String countTextTwo = EnumChatFormatting.GREEN + nf.format(LootCommand.monsterOfTheDeeps) + "\n" + - EnumChatFormatting.YELLOW + nf.format(LootCommand.catfishes) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.carrotKings) + "\n" + - EnumChatFormatting.GRAY + nf.format(LootCommand.seaLeeches) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.guardianDefenders) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.deepSeaProtectors) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.hydras) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.seaEmperors) + "\n" + - EnumChatFormatting.AQUA + timeBetween + "\n" + - EnumChatFormatting.AQUA + bossesBetween; - - if (ToggleCommand.splitFishing) { - new TextRenderer(mc, dropsTextTwo, (int) (MoveCommand.displayXY[0] + (160 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); - new TextRenderer(mc, countTextTwo, (int) (MoveCommand.displayXY[0] + (270 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); - } else { - dropsText += "\n" + dropsTextTwo; - countText += "\n" + countTextTwo; - } - } else if (DisplayCommand.display.equals("fishing_session")) { - if (LootCommand.empTimeSession == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(LootCommand.empTimeSession, timeNow); - } - if (LootCommand.empSCsSession == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(LootCommand.empSCsSession); - } - - dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + - EnumChatFormatting.AQUA + "Fishing Milestone:\n" + - EnumChatFormatting.GOLD + "Good Catches:\n" + - EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + - EnumChatFormatting.GRAY + "Squids:\n" + - EnumChatFormatting.GREEN + "Sea Walkers:\n" + - EnumChatFormatting.DARK_GRAY + "Night Squids:\n" + - EnumChatFormatting.DARK_AQUA + "Sea Guardians:\n" + - EnumChatFormatting.BLUE + "Sea Witches:\n" + - EnumChatFormatting.GREEN + "Sea Archers:"; - countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreaturesSession) + "\n" + - EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestoneSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatchesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatchesSession) + "\n" + - EnumChatFormatting.GRAY + nf.format(LootCommand.squidsSession) + "\n" + - EnumChatFormatting.GREEN + nf.format(LootCommand.seaWalkersSession) + "\n" + - EnumChatFormatting.DARK_GRAY + nf.format(LootCommand.nightSquidsSession) + "\n" + - EnumChatFormatting.DARK_AQUA + nf.format(LootCommand.seaGuardiansSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.seaWitchesSession) + "\n" + - EnumChatFormatting.GREEN + nf.format(LootCommand.seaArchersSession); - // Seperated to save vertical space - String dropsTextTwo = EnumChatFormatting.GREEN + "Monster of Deeps:\n" + - EnumChatFormatting.YELLOW + "Catfishes:\n" + - EnumChatFormatting.GOLD + "Carrot Kings:\n" + - EnumChatFormatting.GRAY + "Sea Leeches:\n" + - EnumChatFormatting.DARK_PURPLE + "Guardian Defenders:\n" + - EnumChatFormatting.DARK_PURPLE + "Deep Sea Protectors:\n" + - EnumChatFormatting.GOLD + "Hydras:\n" + - EnumChatFormatting.GOLD + "Sea Emperors:\n" + - EnumChatFormatting.AQUA + "Time Since Emp:\n" + - EnumChatFormatting.AQUA + "Creatures Since Emp:"; - String countTextTwo = EnumChatFormatting.GREEN + nf.format(LootCommand.monsterOfTheDeepsSession) + "\n" + - EnumChatFormatting.YELLOW + nf.format(LootCommand.catfishesSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.carrotKingsSession) + "\n" + - EnumChatFormatting.GRAY + nf.format(LootCommand.seaLeechesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.guardianDefendersSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.deepSeaProtectorsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.hydrasSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.seaEmperorsSession) + "\n" + - EnumChatFormatting.AQUA + timeBetween + "\n" + - EnumChatFormatting.AQUA + bossesBetween; - - if (ToggleCommand.splitFishing) { - new TextRenderer(mc, dropsTextTwo, (int) (MoveCommand.displayXY[0] + (160 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); - new TextRenderer(mc, countTextTwo, (int) (MoveCommand.displayXY[0] + (270 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); - } else { - dropsText += "\n" + dropsTextTwo; - countText += "\n" + countTextTwo; - } - } else if (DisplayCommand.display.equals("fishing_winter")) { - if (LootCommand.yetiTime == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(LootCommand.yetiTime, timeNow); - } - if (LootCommand.yetiSCs == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(LootCommand.yetiSCs); - } - - dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + - EnumChatFormatting.AQUA + "Fishing Milestone:\n" + - EnumChatFormatting.GOLD + "Good Catches:\n" + - EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + - EnumChatFormatting.AQUA + "Frozen Steves:\n" + - EnumChatFormatting.WHITE + "Snowmans:\n" + - EnumChatFormatting.DARK_GREEN + "Grinches:\n" + - EnumChatFormatting.GOLD + "Yetis:\n" + - EnumChatFormatting.AQUA + "Time Since Yeti:\n" + - EnumChatFormatting.AQUA + "Creatures Since Yeti:"; - countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreatures) + "\n" + - EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestone) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatches) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatches) + "\n" + - EnumChatFormatting.AQUA + nf.format(LootCommand.frozenSteves) + "\n" + - EnumChatFormatting.WHITE + nf.format(LootCommand.frostyTheSnowmans) + "\n" + - EnumChatFormatting.DARK_GREEN + nf.format(LootCommand.grinches) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.yetis) + "\n" + - EnumChatFormatting.AQUA + timeBetween + "\n" + - EnumChatFormatting.AQUA + bossesBetween; - } else if (DisplayCommand.display.equals("fishing_winter_session")) { - if (LootCommand.yetiTimeSession == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(LootCommand.yetiTimeSession, timeNow); - } - if (LootCommand.yetiSCsSession == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(LootCommand.yetiSCsSession); - } - - dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + - EnumChatFormatting.AQUA + "Fishing Milestone:\n" + - EnumChatFormatting.GOLD + "Good Catches:\n" + - EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + - EnumChatFormatting.AQUA + "Frozen Steves:\n" + - EnumChatFormatting.WHITE + "Snowmans:\n" + - EnumChatFormatting.DARK_GREEN + "Grinches:\n" + - EnumChatFormatting.GOLD + "Yetis:\n" + - EnumChatFormatting.AQUA + "Time Since Yeti:\n" + - EnumChatFormatting.AQUA + "Creatures Since Yeti:"; - countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreaturesSession) + "\n" + - EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestoneSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatchesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatchesSession) + "\n" + - EnumChatFormatting.AQUA + nf.format(LootCommand.frozenStevesSession) + "\n" + - EnumChatFormatting.WHITE + nf.format(LootCommand.frostyTheSnowmansSession) + "\n" + - EnumChatFormatting.DARK_GREEN + nf.format(LootCommand.grinchesSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.yetisSession) + "\n" + - EnumChatFormatting.AQUA + timeBetween + "\n" + + switch (DisplayCommand.display) { + case "wolf": + if (LootCommand.wolfTime == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(LootCommand.wolfTime, timeNow); + } + if (LootCommand.wolfBosses == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(LootCommand.wolfBosses); + } + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(LootCommand.wolfWheels); + } else { + drop20 = nf.format(LootCommand.wolfWheelsDrops) + " times"; + } + + dropsText = EnumChatFormatting.GOLD + "Svens Killed:\n" + + EnumChatFormatting.GREEN + "Wolf Teeth:\n" + + EnumChatFormatting.BLUE + "Hamster Wheels:\n" + + EnumChatFormatting.AQUA + "Spirit Runes:\n" + + EnumChatFormatting.WHITE + "Critical VI Books:\n" + + EnumChatFormatting.DARK_RED + "Red Claw Eggs:\n" + + EnumChatFormatting.GOLD + "Couture Runes:\n" + + EnumChatFormatting.AQUA + "Grizzly Baits:\n" + + EnumChatFormatting.DARK_PURPLE + "Overfluxes:\n" + + EnumChatFormatting.AQUA + "Time Since RNG:\n" + + EnumChatFormatting.AQUA + "Bosses Since RNG:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.wolfSvens) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.wolfTeeth) + "\n" + + EnumChatFormatting.BLUE + drop20 + "\n" + + EnumChatFormatting.AQUA + LootCommand.wolfSpirits + "\n" + + EnumChatFormatting.WHITE + LootCommand.wolfBooks + "\n" + + EnumChatFormatting.DARK_RED + LootCommand.wolfEggs + "\n" + + EnumChatFormatting.GOLD + LootCommand.wolfCoutures + "\n" + + EnumChatFormatting.AQUA + LootCommand.wolfBaits + "\n" + + EnumChatFormatting.DARK_PURPLE + LootCommand.wolfFluxes + "\n" + + EnumChatFormatting.AQUA + timeBetween + "\n" + + EnumChatFormatting.AQUA + bossesBetween; + break; + case "wolf_session": + if (LootCommand.wolfTimeSession == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(LootCommand.wolfTimeSession, timeNow); + } + if (LootCommand.wolfBossesSession == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(LootCommand.wolfBossesSession); + } + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(LootCommand.wolfWheelsSession); + } else { + drop20 = nf.format(LootCommand.wolfWheelsDropsSession) + " times"; + } + + dropsText = EnumChatFormatting.GOLD + "Svens Killed:\n" + + EnumChatFormatting.GREEN + "Wolf Teeth:\n" + + EnumChatFormatting.BLUE + "Hamster Wheels:\n" + + EnumChatFormatting.AQUA + "Spirit Runes:\n" + + EnumChatFormatting.WHITE + "Critical VI Books:\n" + + EnumChatFormatting.DARK_RED + "Red Claw Eggs:\n" + + EnumChatFormatting.GOLD + "Couture Runes:\n" + + EnumChatFormatting.AQUA + "Grizzly Baits:\n" + + EnumChatFormatting.DARK_PURPLE + "Overfluxes:\n" + + EnumChatFormatting.AQUA + "Time Since RNG:\n" + + EnumChatFormatting.AQUA + "Bosses Since RNG:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.wolfSvensSession) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.wolfTeethSession) + "\n" + + EnumChatFormatting.BLUE + drop20 + "\n" + + EnumChatFormatting.AQUA + LootCommand.wolfSpiritsSession + "\n" + + EnumChatFormatting.WHITE + LootCommand.wolfBooksSession + "\n" + + EnumChatFormatting.DARK_RED + LootCommand.wolfEggsSession + "\n" + + EnumChatFormatting.GOLD + LootCommand.wolfCouturesSession + "\n" + + EnumChatFormatting.AQUA + LootCommand.wolfBaitsSession + "\n" + + EnumChatFormatting.DARK_PURPLE + LootCommand.wolfFluxesSession + "\n" + + EnumChatFormatting.AQUA + timeBetween + "\n" + EnumChatFormatting.AQUA + bossesBetween; - } else if (DisplayCommand.display.equals("fishing_festival")) { - dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + - EnumChatFormatting.AQUA + "Fishing Milestone:\n" + - EnumChatFormatting.GOLD + "Good Catches:\n" + - EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + - EnumChatFormatting.LIGHT_PURPLE + "Nurse Sharks:\n" + - EnumChatFormatting.BLUE + "Blue Sharks:\n" + - EnumChatFormatting.GOLD + "Tiger Sharks:\n" + - EnumChatFormatting.WHITE + "Great White Sharks:"; - countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreatures) + "\n" + - EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestone) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatches) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatches) + "\n" + - EnumChatFormatting.LIGHT_PURPLE + nf.format(LootCommand.nurseSharks) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.blueSharks) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.tigerSharks) + "\n" + - EnumChatFormatting.WHITE + nf.format(LootCommand.greatWhiteSharks); - } else if (DisplayCommand.display.equals("fishing_festival_session")) { - dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + - EnumChatFormatting.AQUA + "Fishing Milestone:\n" + - EnumChatFormatting.GOLD + "Good Catches:\n" + - EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + - EnumChatFormatting.LIGHT_PURPLE + "Nurse Sharks:\n" + - EnumChatFormatting.BLUE + "Blue Sharks:\n" + - EnumChatFormatting.GOLD + "Tiger Sharks:\n" + - EnumChatFormatting.WHITE + "Great White Sharks:"; - countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreaturesSession) + "\n" + - EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestoneSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatchesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatchesSession) + "\n" + - EnumChatFormatting.LIGHT_PURPLE + nf.format(LootCommand.nurseSharksSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.blueSharksSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.tigerSharksSession) + "\n" + - EnumChatFormatting.WHITE + nf.format(LootCommand.greatWhiteSharksSession); - } else if (DisplayCommand.display.equals("fishing_spooky")) { - dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + - EnumChatFormatting.AQUA + "Fishing Milestone:\n" + - EnumChatFormatting.GOLD + "Good Catches:\n" + - EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + - EnumChatFormatting.BLUE + "Scarecrows:\n" + - EnumChatFormatting.GRAY + "Nightmares:\n" + - EnumChatFormatting.DARK_PURPLE + "Werewolves:\n" + - EnumChatFormatting.GOLD + "Phantom Fishers:\n" + - EnumChatFormatting.GOLD + "Grim Reapers:"; - countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreatures) + "\n" + - EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestone) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatches) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatches) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.scarecrows) + "\n" + - EnumChatFormatting.GRAY + nf.format(LootCommand.nightmares) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.werewolfs) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.phantomFishers) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.grimReapers); - } else if (DisplayCommand.display.equals("fishing_spooky_session")) { - dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + - EnumChatFormatting.AQUA + "Fishing Milestone:\n" + - EnumChatFormatting.GOLD + "Good Catches:\n" + - EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + - EnumChatFormatting.BLUE + "Scarecrows:\n" + - EnumChatFormatting.GRAY + "Nightmares:\n" + - EnumChatFormatting.DARK_PURPLE + "Werewolves:\n" + - EnumChatFormatting.GOLD + "Phantom Fishers:\n" + - EnumChatFormatting.GOLD + "Grim Reapers:"; - countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreaturesSession) + "\n" + - EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestoneSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatchesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatchesSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.scarecrowsSession) + "\n" + - EnumChatFormatting.GRAY + nf.format(LootCommand.nightmaresSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.werewolfsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.phantomFishersSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.grimReapersSession); - } else if (DisplayCommand.display.equals("catacombs_floor_one")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.BLUE + "Bonzo's Staffs:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.bonzoStaffs) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f1CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f1TimeSpent); - } else if (DisplayCommand.display.equals("catacombs_floor_one_session")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.BLUE + "Bonzo's Staffs:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.bonzoStaffsSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f1CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f1TimeSpentSession); - } else if (DisplayCommand.display.equals("catacombs_floor_two")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.BLUE + "Scarf's Studies:\n" + - EnumChatFormatting.DARK_PURPLE + "Adaptive Blades:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.scarfStudies) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveSwords) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f2CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f2TimeSpent); - } else if (DisplayCommand.display.equals("catacombs_floor_two_session")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.BLUE + "Scarf's Studies:\n" + - EnumChatFormatting.DARK_PURPLE + "Adaptive Blades:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.scarfStudiesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveSwordsSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f2CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f2TimeSpentSession); - } else if (DisplayCommand.display.equals("catacombs_floor_three")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.DARK_PURPLE + "Adaptive Helmets:\n" + - EnumChatFormatting.DARK_PURPLE + "Adaptive Chestplates:\n" + - EnumChatFormatting.DARK_PURPLE + "Adaptive Leggings:\n" + - EnumChatFormatting.DARK_PURPLE + "Adaptive Boots:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveHelms) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveChests) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveLegs) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveBoots) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f3CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f3TimeSpent); - } else if (DisplayCommand.display.equals("catacombs_floor_three_session")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.DARK_PURPLE + "Adaptive Helmets:\n" + - EnumChatFormatting.DARK_PURPLE + "Adaptive Chestplates:\n" + - EnumChatFormatting.DARK_PURPLE + "Adaptive Leggings:\n" + - EnumChatFormatting.DARK_PURPLE + "Adaptive Boots:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveHelmsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveChestsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveLegsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveBootsSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f3CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f3TimeSpentSession); - } else if (DisplayCommand.display.equals("catacombs_floor_four")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.DARK_PURPLE + "Spirit Wings:\n" + - EnumChatFormatting.DARK_PURPLE + "Spirit Bones:\n" + - EnumChatFormatting.DARK_PURPLE + "Spirit Boots:\n" + - EnumChatFormatting.DARK_PURPLE + "Spirit Swords:\n" + - EnumChatFormatting.GOLD + "Spirit Bows:\n" + - EnumChatFormatting.DARK_PURPLE + "Epic Spirit Pets:\n" + - EnumChatFormatting.GOLD + "Leg Spirit Pets:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritWings) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritBones) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritBoots) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritSwords) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.spiritBows) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.epicSpiritPets) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.legSpiritPets) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f4CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f4TimeSpent); - } else if (DisplayCommand.display.equals("catacombs_floor_four_session")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.DARK_PURPLE + "Spirit Wings:\n" + - EnumChatFormatting.DARK_PURPLE + "Spirit Bones:\n" + - EnumChatFormatting.DARK_PURPLE + "Spirit Boots:\n" + - EnumChatFormatting.DARK_PURPLE + "Spirit Swords:\n" + - EnumChatFormatting.GOLD + "Spirit Bows:\n" + - EnumChatFormatting.DARK_PURPLE + "Epic Spirit Pets:\n" + - EnumChatFormatting.GOLD + "Leg Spirit Pets:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritWingsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritBonesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritBootsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritSwordsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.spiritBowsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.epicSpiritPetsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.legSpiritPetsSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f4CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f4TimeSpentSession); - } else if (DisplayCommand.display.equals("catacombs_floor_five")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.BLUE + "Warped Stones:\n" + - EnumChatFormatting.DARK_PURPLE + "Shadow Helmets:\n" + - EnumChatFormatting.DARK_PURPLE + "Shadow Chestplates:\n" + - EnumChatFormatting.DARK_PURPLE + "Shadow Leggings:\n" + - EnumChatFormatting.DARK_PURPLE + "Shadow Boots:\n" + - EnumChatFormatting.GOLD + "Last Breaths:\n" + - EnumChatFormatting.GOLD + "Livid Daggers:\n" + - EnumChatFormatting.GOLD + "Shadow Furys:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.warpedStones) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssHelms) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssChests) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssLegs) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssBoots) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.lastBreaths) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.lividDaggers) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.shadowFurys) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f5CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f5TimeSpent); - } else if (DisplayCommand.display.equals("catacombs_floor_five_session")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.BLUE + "Warped Stones:\n" + - EnumChatFormatting.DARK_PURPLE + "Shadow Helmets:\n" + - EnumChatFormatting.DARK_PURPLE + "Shadow Chestplates:\n" + - EnumChatFormatting.DARK_PURPLE + "Shadow Leggings:\n" + - EnumChatFormatting.DARK_PURPLE + "Shadow Boots:\n" + - EnumChatFormatting.GOLD + "Last Breaths:\n" + - EnumChatFormatting.GOLD + "Livid Daggers:\n" + - EnumChatFormatting.GOLD + "Shadow Furys:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.warpedStonesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssHelmsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssChestsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssLegsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssBootsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.lastBreathsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.lividDaggersSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.shadowFurysSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f5CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f5TimeSpentSession); - } else if (DisplayCommand.display.equals("catacombs_floor_six")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.BLUE + "Ancient Roses:\n" + - EnumChatFormatting.GOLD + "Precursor Eyes:\n" + - EnumChatFormatting.GOLD + "Giant's Swords:\n" + - EnumChatFormatting.GOLD + "Necro Lord Helmets:\n" + - EnumChatFormatting.GOLD + "Necro Lord Chests:\n" + - EnumChatFormatting.GOLD + "Necro Lord Leggings:\n" + - EnumChatFormatting.GOLD + "Necro Lord Boots:\n" + - EnumChatFormatting.GOLD + "Necro Swords:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.ancientRoses) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.precursorEyes) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.giantsSwords) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordHelms) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordChests) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordLegs) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordBoots) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.necroSwords) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f6CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f6TimeSpent); - } else if (DisplayCommand.display.equals("catacombs_floor_six_session")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.BLUE + "Ancient Roses:\n" + - EnumChatFormatting.GOLD + "Precursor Eyes:\n" + - EnumChatFormatting.GOLD + "Giant's Swords:\n" + - EnumChatFormatting.GOLD + "Necro Lord Helmets:\n" + - EnumChatFormatting.GOLD + "Necro Lord Chests:\n" + - EnumChatFormatting.GOLD + "Necro Lord Leggings:\n" + - EnumChatFormatting.GOLD + "Necro Lord Boots:\n" + - EnumChatFormatting.GOLD + "Necro Swords:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(LootCommand.ancientRosesSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.precursorEyesSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.giantsSwordsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordHelmsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordChestsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordLegsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordBootsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.necroSwordsSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f6CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f6TimeSpentSession); - } else if (DisplayCommand.display.equals("catacombs_floor_seven")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.DARK_PURPLE + "Wither Bloods:\n" + - EnumChatFormatting.DARK_PURPLE + "Wither Cloaks:\n" + - EnumChatFormatting.DARK_PURPLE + "Implosions:\n" + - EnumChatFormatting.DARK_PURPLE + "Wither Shields:\n" + - EnumChatFormatting.DARK_PURPLE + "Shadow Warps:\n" + - EnumChatFormatting.DARK_PURPLE + "Necron's Handles:\n" + - EnumChatFormatting.GOLD + "Auto Recombobs:\n" + - EnumChatFormatting.GOLD + "Wither Helmets:\n" + - EnumChatFormatting.GOLD + "Wither Chests:\n" + - EnumChatFormatting.GOLD + "Wither Leggings:\n" + - EnumChatFormatting.GOLD + "Wither Boots:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherBloods) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherCloaks) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.implosions) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherShields) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowWarps) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.necronsHandles) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.autoRecombs) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.witherHelms) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.witherChests) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.witherLegs) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.witherBoots) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f7CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f7TimeSpent); - } else if (DisplayCommand.display.equals("catacombs_floor_seven_session")) { - dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + - EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + - EnumChatFormatting.DARK_PURPLE + "Wither Bloods:\n" + - EnumChatFormatting.DARK_PURPLE + "Wither Cloaks:\n" + - EnumChatFormatting.DARK_PURPLE + "Implosions:\n" + - EnumChatFormatting.DARK_PURPLE + "Wither Shields:\n" + - EnumChatFormatting.DARK_PURPLE + "Shadow Warps:\n" + - EnumChatFormatting.DARK_PURPLE + "Necron's Handles:\n" + - EnumChatFormatting.GOLD + "Auto Recombobulators:\n" + - EnumChatFormatting.GOLD + "Wither Helmets:\n" + - EnumChatFormatting.GOLD + "Wither Chests:\n" + - EnumChatFormatting.GOLD + "Wither Leggings:\n" + - EnumChatFormatting.GOLD + "Wither Boots:\n" + - EnumChatFormatting.AQUA + "Coins Spent:\n" + - EnumChatFormatting.AQUA + "Time Spent:"; - countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherBloodsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherCloaksSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.implosionsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherShieldsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowWarpsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.necronsHandlesSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.autoRecombsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.witherHelmsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.witherChestsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.witherLegsSession) + "\n" + - EnumChatFormatting.GOLD + nf.format(LootCommand.witherBootsSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f7CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f7TimeSpentSession); - } else { - System.out.println("Display was an unknown value, turning off."); - DisplayCommand.display = "off"; - ConfigHandler.writeStringConfig("misc", "display", "off"); + break; + case "spider": + if (LootCommand.spiderTime == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(LootCommand.spiderTime, timeNow); + } + if (LootCommand.spiderBosses == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(LootCommand.spiderBosses); + } + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(LootCommand.spiderTAP); + } else { + drop20 = nf.format(LootCommand.spiderTAPDrops) + " times"; + } + + dropsText = EnumChatFormatting.GOLD + "Tarantulas Killed:\n" + + EnumChatFormatting.GREEN + "Tarantula Webs:\n" + + EnumChatFormatting.DARK_GREEN + "Arrow Poison:\n" + + EnumChatFormatting.DARK_GRAY + "Bite Runes:\n" + + EnumChatFormatting.WHITE + "Bane VI Books:\n" + + EnumChatFormatting.AQUA + "Spider Catalysts:\n" + + EnumChatFormatting.DARK_PURPLE + "Tarantula Talismans:\n" + + EnumChatFormatting.LIGHT_PURPLE + "Fly Swatters:\n" + + EnumChatFormatting.GOLD + "Digested Mosquitos:\n" + + EnumChatFormatting.AQUA + "Time Since RNG:\n" + + EnumChatFormatting.AQUA + "Bosses Since RNG:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.spiderTarantulas) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.spiderWebs) + "\n" + + EnumChatFormatting.DARK_GREEN + drop20 + "\n" + + EnumChatFormatting.DARK_GRAY + LootCommand.spiderBites + "\n" + + EnumChatFormatting.WHITE + LootCommand.spiderBooks + "\n" + + EnumChatFormatting.AQUA + LootCommand.spiderCatalysts + "\n" + + EnumChatFormatting.DARK_PURPLE + LootCommand.spiderTalismans + "\n" + + EnumChatFormatting.LIGHT_PURPLE + LootCommand.spiderSwatters + "\n" + + EnumChatFormatting.GOLD + LootCommand.spiderMosquitos + "\n" + + EnumChatFormatting.AQUA + timeBetween + "\n" + + EnumChatFormatting.AQUA + bossesBetween; + break; + case "spider_session": + if (LootCommand.spiderTimeSession == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(LootCommand.spiderTimeSession, timeNow); + } + if (LootCommand.spiderBossesSession == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(LootCommand.spiderBossesSession); + } + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(LootCommand.spiderTAPSession); + } else { + drop20 = nf.format(LootCommand.spiderTAPDropsSession) + " times"; + } + + dropsText = EnumChatFormatting.GOLD + "Tarantulas Killed:\n" + + EnumChatFormatting.GREEN + "Tarantula Webs:\n" + + EnumChatFormatting.DARK_GREEN + "Arrow Poison:\n" + + EnumChatFormatting.DARK_GRAY + "Bite Runes:\n" + + EnumChatFormatting.WHITE + "Bane VI Books:\n" + + EnumChatFormatting.AQUA + "Spider Catalysts:\n" + + EnumChatFormatting.DARK_PURPLE + "Tarantula Talismans:\n" + + EnumChatFormatting.LIGHT_PURPLE + "Fly Swatters:\n" + + EnumChatFormatting.GOLD + "Digested Mosquitos:\n" + + EnumChatFormatting.AQUA + "Time Since RNG:\n" + + EnumChatFormatting.AQUA + "Bosses Since RNG:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.spiderTarantulasSession) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.spiderWebsSession) + "\n" + + EnumChatFormatting.DARK_GREEN + drop20 + "\n" + + EnumChatFormatting.DARK_GRAY + LootCommand.spiderBitesSession + "\n" + + EnumChatFormatting.WHITE + LootCommand.spiderBooksSession + "\n" + + EnumChatFormatting.AQUA + LootCommand.spiderCatalystsSession + "\n" + + EnumChatFormatting.DARK_PURPLE + LootCommand.spiderTalismansSession + "\n" + + EnumChatFormatting.LIGHT_PURPLE + LootCommand.spiderSwattersSession + "\n" + + EnumChatFormatting.GOLD + LootCommand.spiderMosquitosSession + "\n" + + EnumChatFormatting.AQUA + timeBetween + "\n" + + EnumChatFormatting.AQUA + bossesBetween; + break; + case "zombie": + if (LootCommand.zombieTime == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(LootCommand.zombieTime, timeNow); + } + if (LootCommand.zombieBosses == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(LootCommand.zombieBosses); + } + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(LootCommand.zombieFoulFlesh); + } else { + drop20 = nf.format(LootCommand.zombieFoulFleshDrops) + " times"; + } + + dropsText = EnumChatFormatting.GOLD + "Revs Killed:\n" + + EnumChatFormatting.GREEN + "Revenant Flesh:\n" + + EnumChatFormatting.BLUE + "Foul Flesh:\n" + + EnumChatFormatting.DARK_GREEN + "Pestilence Runes:\n" + + EnumChatFormatting.WHITE + "Smite VI Books:\n" + + EnumChatFormatting.AQUA + "Undead Catalysts:\n" + + EnumChatFormatting.DARK_PURPLE + "Beheaded Horrors:\n" + + EnumChatFormatting.RED + "Revenant Catalysts:\n" + + EnumChatFormatting.DARK_GREEN + "Snake Runes:\n" + + EnumChatFormatting.GOLD + "Scythe Blades:\n" + + EnumChatFormatting.AQUA + "Time Since RNG:\n" + + EnumChatFormatting.AQUA + "Bosses Since RNG:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.zombieRevs) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.zombieRevFlesh) + "\n" + + EnumChatFormatting.BLUE + drop20 + "\n" + + EnumChatFormatting.DARK_GREEN + LootCommand.zombiePestilences + "\n" + + EnumChatFormatting.WHITE + LootCommand.zombieBooks + "\n" + + EnumChatFormatting.AQUA + LootCommand.zombieUndeadCatas + "\n" + + EnumChatFormatting.DARK_PURPLE + LootCommand.zombieBeheadeds + "\n" + + EnumChatFormatting.RED + LootCommand.zombieRevCatas + "\n" + + EnumChatFormatting.DARK_GREEN + LootCommand.zombieSnakes + "\n" + + EnumChatFormatting.GOLD + LootCommand.zombieScythes + "\n" + + EnumChatFormatting.AQUA + timeBetween + "\n" + + EnumChatFormatting.AQUA + bossesBetween; + break; + case "zombie_session": + if (LootCommand.zombieTimeSession == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(LootCommand.zombieTimeSession, timeNow); + } + if (LootCommand.zombieBossesSession == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(LootCommand.zombieBossesSession); + } + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(LootCommand.zombieFoulFleshSession); + } else { + drop20 = nf.format(LootCommand.zombieFoulFleshDropsSession) + " times"; + } + + dropsText = EnumChatFormatting.GOLD + "Revs Killed:\n" + + EnumChatFormatting.GREEN + "Revenant Flesh:\n" + + EnumChatFormatting.BLUE + "Foul Flesh:\n" + + EnumChatFormatting.DARK_GREEN + "Pestilence Runes:\n" + + EnumChatFormatting.WHITE + "Smite VI Books:\n" + + EnumChatFormatting.AQUA + "Undead Catalysts:\n" + + EnumChatFormatting.DARK_PURPLE + "Beheaded Horrors:\n" + + EnumChatFormatting.RED + "Revenant Catalysts:\n" + + EnumChatFormatting.DARK_GREEN + "Snake Runes:\n" + + EnumChatFormatting.GOLD + "Scythe Blades:\n" + + EnumChatFormatting.AQUA + "Time Since RNG:\n" + + EnumChatFormatting.AQUA + "Bosses Since RNG:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.zombieRevsSession) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.zombieRevFleshSession) + "\n" + + EnumChatFormatting.BLUE + drop20 + "\n" + + EnumChatFormatting.DARK_GREEN + LootCommand.zombiePestilencesSession + "\n" + + EnumChatFormatting.WHITE + LootCommand.zombieBooksSession + "\n" + + EnumChatFormatting.AQUA + LootCommand.zombieUndeadCatasSession + "\n" + + EnumChatFormatting.DARK_PURPLE + LootCommand.zombieBeheadedsSession + "\n" + + EnumChatFormatting.RED + LootCommand.zombieRevCatasSession + "\n" + + EnumChatFormatting.DARK_GREEN + LootCommand.zombieSnakesSession + "\n" + + EnumChatFormatting.GOLD + LootCommand.zombieScythes + "\n" + + EnumChatFormatting.AQUA + timeBetween + "\n" + + EnumChatFormatting.AQUA + bossesBetween; + break; + case "fishing": + if (LootCommand.empTime == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(LootCommand.empTime, timeNow); + } + if (LootCommand.empSCs == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(LootCommand.empSCs); + } + + dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + + EnumChatFormatting.AQUA + "Fishing Milestone:\n" + + EnumChatFormatting.GOLD + "Good Catches:\n" + + EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + + EnumChatFormatting.GRAY + "Squids:\n" + + EnumChatFormatting.GREEN + "Sea Walkers:\n" + + EnumChatFormatting.DARK_GRAY + "Night Squids:\n" + + EnumChatFormatting.DARK_AQUA + "Sea Guardians:\n" + + EnumChatFormatting.BLUE + "Sea Witches:\n" + + EnumChatFormatting.GREEN + "Sea Archers:"; + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreatures) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestone) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatches) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatches) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.squids) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.seaWalkers) + "\n" + + EnumChatFormatting.DARK_GRAY + nf.format(LootCommand.nightSquids) + "\n" + + EnumChatFormatting.DARK_AQUA + nf.format(LootCommand.seaGuardians) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.seaWitches) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.seaArchers); + // Seperated to save vertical space + dropsTextTwo = EnumChatFormatting.GREEN + "Monster of Deeps:\n" + + EnumChatFormatting.YELLOW + "Catfishes:\n" + + EnumChatFormatting.GOLD + "Carrot Kings:\n" + + EnumChatFormatting.GRAY + "Sea Leeches:\n" + + EnumChatFormatting.DARK_PURPLE + "Guardian Defenders:\n" + + EnumChatFormatting.DARK_PURPLE + "Deep Sea Protectors:\n" + + EnumChatFormatting.GOLD + "Hydras:\n" + + EnumChatFormatting.GOLD + "Sea Emperors:\n" + + EnumChatFormatting.AQUA + "Time Since Emp:\n" + + EnumChatFormatting.AQUA + "Creatures Since Emp:"; + countTextTwo = EnumChatFormatting.GREEN + nf.format(LootCommand.monsterOfTheDeeps) + "\n" + + EnumChatFormatting.YELLOW + nf.format(LootCommand.catfishes) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.carrotKings) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.seaLeeches) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.guardianDefenders) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.deepSeaProtectors) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.hydras) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.seaEmperors) + "\n" + + EnumChatFormatting.AQUA + timeBetween + "\n" + + EnumChatFormatting.AQUA + bossesBetween; + + if (ToggleCommand.splitFishing) { + new TextRenderer(mc, dropsTextTwo, (int) (MoveCommand.displayXY[0] + (160 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); + new TextRenderer(mc, countTextTwo, (int) (MoveCommand.displayXY[0] + (270 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); + } else { + dropsText += "\n" + dropsTextTwo; + countText += "\n" + countTextTwo; + } + break; + case "fishing_session": + if (LootCommand.empTimeSession == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(LootCommand.empTimeSession, timeNow); + } + if (LootCommand.empSCsSession == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(LootCommand.empSCsSession); + } + + dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + + EnumChatFormatting.AQUA + "Fishing Milestone:\n" + + EnumChatFormatting.GOLD + "Good Catches:\n" + + EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + + EnumChatFormatting.GRAY + "Squids:\n" + + EnumChatFormatting.GREEN + "Sea Walkers:\n" + + EnumChatFormatting.DARK_GRAY + "Night Squids:\n" + + EnumChatFormatting.DARK_AQUA + "Sea Guardians:\n" + + EnumChatFormatting.BLUE + "Sea Witches:\n" + + EnumChatFormatting.GREEN + "Sea Archers:"; + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreaturesSession) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestoneSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatchesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatchesSession) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.squidsSession) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.seaWalkersSession) + "\n" + + EnumChatFormatting.DARK_GRAY + nf.format(LootCommand.nightSquidsSession) + "\n" + + EnumChatFormatting.DARK_AQUA + nf.format(LootCommand.seaGuardiansSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.seaWitchesSession) + "\n" + + EnumChatFormatting.GREEN + nf.format(LootCommand.seaArchersSession); + // Seperated to save vertical space + dropsTextTwo = EnumChatFormatting.GREEN + "Monster of Deeps:\n" + + EnumChatFormatting.YELLOW + "Catfishes:\n" + + EnumChatFormatting.GOLD + "Carrot Kings:\n" + + EnumChatFormatting.GRAY + "Sea Leeches:\n" + + EnumChatFormatting.DARK_PURPLE + "Guardian Defenders:\n" + + EnumChatFormatting.DARK_PURPLE + "Deep Sea Protectors:\n" + + EnumChatFormatting.GOLD + "Hydras:\n" + + EnumChatFormatting.GOLD + "Sea Emperors:\n" + + EnumChatFormatting.AQUA + "Time Since Emp:\n" + + EnumChatFormatting.AQUA + "Creatures Since Emp:"; + countTextTwo = EnumChatFormatting.GREEN + nf.format(LootCommand.monsterOfTheDeepsSession) + "\n" + + EnumChatFormatting.YELLOW + nf.format(LootCommand.catfishesSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.carrotKingsSession) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.seaLeechesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.guardianDefendersSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.deepSeaProtectorsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.hydrasSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.seaEmperorsSession) + "\n" + + EnumChatFormatting.AQUA + timeBetween + "\n" + + EnumChatFormatting.AQUA + bossesBetween; + + if (ToggleCommand.splitFishing) { + new TextRenderer(mc, dropsTextTwo, (int) (MoveCommand.displayXY[0] + (160 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); + new TextRenderer(mc, countTextTwo, (int) (MoveCommand.displayXY[0] + (270 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); + } else { + dropsText += "\n" + dropsTextTwo; + countText += "\n" + countTextTwo; + } + break; + case "fishing_winter": + if (LootCommand.yetiTime == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(LootCommand.yetiTime, timeNow); + } + if (LootCommand.yetiSCs == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(LootCommand.yetiSCs); + } + + dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + + EnumChatFormatting.AQUA + "Fishing Milestone:\n" + + EnumChatFormatting.GOLD + "Good Catches:\n" + + EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + + EnumChatFormatting.AQUA + "Frozen Steves:\n" + + EnumChatFormatting.WHITE + "Snowmans:\n" + + EnumChatFormatting.DARK_GREEN + "Grinches:\n" + + EnumChatFormatting.GOLD + "Yetis:\n" + + EnumChatFormatting.AQUA + "Time Since Yeti:\n" + + EnumChatFormatting.AQUA + "Creatures Since Yeti:"; + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreatures) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestone) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatches) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatches) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.frozenSteves) + "\n" + + EnumChatFormatting.WHITE + nf.format(LootCommand.frostyTheSnowmans) + "\n" + + EnumChatFormatting.DARK_GREEN + nf.format(LootCommand.grinches) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.yetis) + "\n" + + EnumChatFormatting.AQUA + timeBetween + "\n" + + EnumChatFormatting.AQUA + bossesBetween; + break; + case "fishing_winter_session": + if (LootCommand.yetiTimeSession == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(LootCommand.yetiTimeSession, timeNow); + } + if (LootCommand.yetiSCsSession == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(LootCommand.yetiSCsSession); + } + + dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + + EnumChatFormatting.AQUA + "Fishing Milestone:\n" + + EnumChatFormatting.GOLD + "Good Catches:\n" + + EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + + EnumChatFormatting.AQUA + "Frozen Steves:\n" + + EnumChatFormatting.WHITE + "Snowmans:\n" + + EnumChatFormatting.DARK_GREEN + "Grinches:\n" + + EnumChatFormatting.GOLD + "Yetis:\n" + + EnumChatFormatting.AQUA + "Time Since Yeti:\n" + + EnumChatFormatting.AQUA + "Creatures Since Yeti:"; + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreaturesSession) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestoneSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatchesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatchesSession) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.frozenStevesSession) + "\n" + + EnumChatFormatting.WHITE + nf.format(LootCommand.frostyTheSnowmansSession) + "\n" + + EnumChatFormatting.DARK_GREEN + nf.format(LootCommand.grinchesSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.yetisSession) + "\n" + + EnumChatFormatting.AQUA + timeBetween + "\n" + + EnumChatFormatting.AQUA + bossesBetween; + break; + case "fishing_festival": + dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + + EnumChatFormatting.AQUA + "Fishing Milestone:\n" + + EnumChatFormatting.GOLD + "Good Catches:\n" + + EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + + EnumChatFormatting.LIGHT_PURPLE + "Nurse Sharks:\n" + + EnumChatFormatting.BLUE + "Blue Sharks:\n" + + EnumChatFormatting.GOLD + "Tiger Sharks:\n" + + EnumChatFormatting.WHITE + "Great White Sharks:"; + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreatures) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestone) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatches) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatches) + "\n" + + EnumChatFormatting.LIGHT_PURPLE + nf.format(LootCommand.nurseSharks) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.blueSharks) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.tigerSharks) + "\n" + + EnumChatFormatting.WHITE + nf.format(LootCommand.greatWhiteSharks); + break; + case "fishing_festival_session": + dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + + EnumChatFormatting.AQUA + "Fishing Milestone:\n" + + EnumChatFormatting.GOLD + "Good Catches:\n" + + EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + + EnumChatFormatting.LIGHT_PURPLE + "Nurse Sharks:\n" + + EnumChatFormatting.BLUE + "Blue Sharks:\n" + + EnumChatFormatting.GOLD + "Tiger Sharks:\n" + + EnumChatFormatting.WHITE + "Great White Sharks:"; + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreaturesSession) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestoneSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatchesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatchesSession) + "\n" + + EnumChatFormatting.LIGHT_PURPLE + nf.format(LootCommand.nurseSharksSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.blueSharksSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.tigerSharksSession) + "\n" + + EnumChatFormatting.WHITE + nf.format(LootCommand.greatWhiteSharksSession); + break; + case "fishing_spooky": + dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + + EnumChatFormatting.AQUA + "Fishing Milestone:\n" + + EnumChatFormatting.GOLD + "Good Catches:\n" + + EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + + EnumChatFormatting.BLUE + "Scarecrows:\n" + + EnumChatFormatting.GRAY + "Nightmares:\n" + + EnumChatFormatting.DARK_PURPLE + "Werewolves:\n" + + EnumChatFormatting.GOLD + "Phantom Fishers:\n" + + EnumChatFormatting.GOLD + "Grim Reapers:"; + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreatures) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestone) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatches) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatches) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.scarecrows) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.nightmares) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.werewolfs) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.phantomFishers) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.grimReapers); + break; + case "fishing_spooky_session": + dropsText = EnumChatFormatting.AQUA + "Creatures Caught:\n" + + EnumChatFormatting.AQUA + "Fishing Milestone:\n" + + EnumChatFormatting.GOLD + "Good Catches:\n" + + EnumChatFormatting.DARK_PURPLE + "Great Catches:\n" + + EnumChatFormatting.BLUE + "Scarecrows:\n" + + EnumChatFormatting.GRAY + "Nightmares:\n" + + EnumChatFormatting.DARK_PURPLE + "Werewolves:\n" + + EnumChatFormatting.GOLD + "Phantom Fishers:\n" + + EnumChatFormatting.GOLD + "Grim Reapers:"; + countText = EnumChatFormatting.AQUA + nf.format(LootCommand.seaCreaturesSession) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.fishingMilestoneSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.goodCatchesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.greatCatchesSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.scarecrowsSession) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.nightmaresSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.werewolfsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.phantomFishersSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.grimReapersSession); + break; + case "mythological": + dropsText = EnumChatFormatting.GOLD + "Coins:\n" + + EnumChatFormatting.WHITE + "Griffin Feathers:\n" + + EnumChatFormatting.GOLD + "Crown of Greeds:\n" + + EnumChatFormatting.AQUA + "Washed up Souvenirs:\n" + + EnumChatFormatting.RED + "Minos Hunters:\n" + + EnumChatFormatting.GRAY + "Siamese Lynxes:\n" + + EnumChatFormatting.RED + "Minotaurs:\n" + + EnumChatFormatting.WHITE + "Gaia Constructs:\n" + + EnumChatFormatting.DARK_PURPLE + "Minos Champions:\n" + + EnumChatFormatting.GOLD + "Minos Inquisitors:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.mythCoins) + "\n" + + EnumChatFormatting.WHITE + nf.format(LootCommand.griffinFeathers) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.crownOfGreeds) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.washedUpSouvenirs) + "\n" + + EnumChatFormatting.RED + nf.format(LootCommand.minosHunters) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.siameseLynxes) + "\n" + + EnumChatFormatting.RED + nf.format(LootCommand.minotaurs) + "\n" + + EnumChatFormatting.WHITE + nf.format(LootCommand.gaiaConstructs) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.minosChampions) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.minosInquisitors); + break; + case "mythological_session": + dropsText = EnumChatFormatting.GOLD + "Coins:\n" + + EnumChatFormatting.WHITE + "Griffin Feathers:\n" + + EnumChatFormatting.GOLD + "Crown of Greeds:\n" + + EnumChatFormatting.AQUA + "Washed up Souvenirs:\n" + + EnumChatFormatting.RED + "Minos Hunters:\n" + + EnumChatFormatting.GRAY + "Siamese Lynxes:\n" + + EnumChatFormatting.RED + "Minotaurs:\n" + + EnumChatFormatting.WHITE + "Gaia Constructs:\n" + + EnumChatFormatting.DARK_PURPLE + "Minos Champions:\n" + + EnumChatFormatting.GOLD + "Minos Inquisitors:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.mythCoinsSession) + "\n" + + EnumChatFormatting.WHITE + nf.format(LootCommand.griffinFeathersSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.crownOfGreedsSession) + "\n" + + EnumChatFormatting.AQUA + nf.format(LootCommand.washedUpSouvenirsSession) + "\n" + + EnumChatFormatting.RED + nf.format(LootCommand.minosHuntersSession) + "\n" + + EnumChatFormatting.GRAY + nf.format(LootCommand.siameseLynxesSession) + "\n" + + EnumChatFormatting.RED + nf.format(LootCommand.minotaursSession) + "\n" + + EnumChatFormatting.WHITE + nf.format(LootCommand.gaiaConstructsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.minosChampionsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.minosInquisitorsSession); + break; + case "catacombs_floor_one": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.BLUE + "Bonzo's Staffs:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.bonzoStaffs) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f1CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f1TimeSpent); + break; + case "catacombs_floor_one_session": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.BLUE + "Bonzo's Staffs:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.bonzoStaffsSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f1CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f1TimeSpentSession); + break; + case "catacombs_floor_two": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.BLUE + "Scarf's Studies:\n" + + EnumChatFormatting.DARK_PURPLE + "Adaptive Blades:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.scarfStudies) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveSwords) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f2CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f2TimeSpent); + break; + case "catacombs_floor_two_session": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.BLUE + "Scarf's Studies:\n" + + EnumChatFormatting.DARK_PURPLE + "Adaptive Blades:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.scarfStudiesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveSwordsSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f2CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f2TimeSpentSession); + break; + case "catacombs_floor_three": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.DARK_PURPLE + "Adaptive Helmets:\n" + + EnumChatFormatting.DARK_PURPLE + "Adaptive Chestplates:\n" + + EnumChatFormatting.DARK_PURPLE + "Adaptive Leggings:\n" + + EnumChatFormatting.DARK_PURPLE + "Adaptive Boots:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveHelms) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveChests) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveLegs) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveBoots) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f3CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f3TimeSpent); + break; + case "catacombs_floor_three_session": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.DARK_PURPLE + "Adaptive Helmets:\n" + + EnumChatFormatting.DARK_PURPLE + "Adaptive Chestplates:\n" + + EnumChatFormatting.DARK_PURPLE + "Adaptive Leggings:\n" + + EnumChatFormatting.DARK_PURPLE + "Adaptive Boots:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveHelmsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveChestsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveLegsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.adaptiveBootsSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f3CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f3TimeSpentSession); + break; + case "catacombs_floor_four": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.DARK_PURPLE + "Spirit Wings:\n" + + EnumChatFormatting.DARK_PURPLE + "Spirit Bones:\n" + + EnumChatFormatting.DARK_PURPLE + "Spirit Boots:\n" + + EnumChatFormatting.DARK_PURPLE + "Spirit Swords:\n" + + EnumChatFormatting.GOLD + "Spirit Bows:\n" + + EnumChatFormatting.DARK_PURPLE + "Epic Spirit Pets:\n" + + EnumChatFormatting.GOLD + "Leg Spirit Pets:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritWings) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritBones) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritBoots) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritSwords) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.spiritBows) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.epicSpiritPets) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.legSpiritPets) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f4CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f4TimeSpent); + break; + case "catacombs_floor_four_session": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.DARK_PURPLE + "Spirit Wings:\n" + + EnumChatFormatting.DARK_PURPLE + "Spirit Bones:\n" + + EnumChatFormatting.DARK_PURPLE + "Spirit Boots:\n" + + EnumChatFormatting.DARK_PURPLE + "Spirit Swords:\n" + + EnumChatFormatting.GOLD + "Spirit Bows:\n" + + EnumChatFormatting.DARK_PURPLE + "Epic Spirit Pets:\n" + + EnumChatFormatting.GOLD + "Leg Spirit Pets:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritWingsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritBonesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritBootsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.spiritSwordsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.spiritBowsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.epicSpiritPetsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.legSpiritPetsSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f4CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f4TimeSpentSession); + break; + case "catacombs_floor_five": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.BLUE + "Warped Stones:\n" + + EnumChatFormatting.DARK_PURPLE + "Shadow Helmets:\n" + + EnumChatFormatting.DARK_PURPLE + "Shadow Chestplates:\n" + + EnumChatFormatting.DARK_PURPLE + "Shadow Leggings:\n" + + EnumChatFormatting.DARK_PURPLE + "Shadow Boots:\n" + + EnumChatFormatting.GOLD + "Last Breaths:\n" + + EnumChatFormatting.GOLD + "Livid Daggers:\n" + + EnumChatFormatting.GOLD + "Shadow Furys:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.warpedStones) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssHelms) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssChests) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssLegs) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssBoots) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.lastBreaths) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.lividDaggers) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.shadowFurys) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f5CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f5TimeSpent); + break; + case "catacombs_floor_five_session": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.BLUE + "Warped Stones:\n" + + EnumChatFormatting.DARK_PURPLE + "Shadow Helmets:\n" + + EnumChatFormatting.DARK_PURPLE + "Shadow Chestplates:\n" + + EnumChatFormatting.DARK_PURPLE + "Shadow Leggings:\n" + + EnumChatFormatting.DARK_PURPLE + "Shadow Boots:\n" + + EnumChatFormatting.GOLD + "Last Breaths:\n" + + EnumChatFormatting.GOLD + "Livid Daggers:\n" + + EnumChatFormatting.GOLD + "Shadow Furys:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.warpedStonesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssHelmsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssChestsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssLegsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowAssBootsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.lastBreathsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.lividDaggersSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.shadowFurysSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f5CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f5TimeSpentSession); + break; + case "catacombs_floor_six": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.BLUE + "Ancient Roses:\n" + + EnumChatFormatting.GOLD + "Precursor Eyes:\n" + + EnumChatFormatting.GOLD + "Giant's Swords:\n" + + EnumChatFormatting.GOLD + "Necro Lord Helmets:\n" + + EnumChatFormatting.GOLD + "Necro Lord Chests:\n" + + EnumChatFormatting.GOLD + "Necro Lord Leggings:\n" + + EnumChatFormatting.GOLD + "Necro Lord Boots:\n" + + EnumChatFormatting.GOLD + "Necro Swords:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.ancientRoses) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.precursorEyes) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.giantsSwords) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordHelms) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordChests) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordLegs) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordBoots) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroSwords) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f6CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f6TimeSpent); + break; + case "catacombs_floor_six_session": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.BLUE + "Ancient Roses:\n" + + EnumChatFormatting.GOLD + "Precursor Eyes:\n" + + EnumChatFormatting.GOLD + "Giant's Swords:\n" + + EnumChatFormatting.GOLD + "Necro Lord Helmets:\n" + + EnumChatFormatting.GOLD + "Necro Lord Chests:\n" + + EnumChatFormatting.GOLD + "Necro Lord Leggings:\n" + + EnumChatFormatting.GOLD + "Necro Lord Boots:\n" + + EnumChatFormatting.GOLD + "Necro Swords:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.BLUE + nf.format(LootCommand.ancientRosesSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.precursorEyesSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.giantsSwordsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordHelmsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordChestsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordLegsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroLordBootsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.necroSwordsSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f6CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f6TimeSpentSession); + break; + case "catacombs_floor_seven": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.DARK_PURPLE + "Wither Bloods:\n" + + EnumChatFormatting.DARK_PURPLE + "Wither Cloaks:\n" + + EnumChatFormatting.DARK_PURPLE + "Implosions:\n" + + EnumChatFormatting.DARK_PURPLE + "Wither Shields:\n" + + EnumChatFormatting.DARK_PURPLE + "Shadow Warps:\n" + + EnumChatFormatting.DARK_PURPLE + "Necron's Handles:\n" + + EnumChatFormatting.GOLD + "Auto Recombobs:\n" + + EnumChatFormatting.GOLD + "Wither Helmets:\n" + + EnumChatFormatting.GOLD + "Wither Chests:\n" + + EnumChatFormatting.GOLD + "Wither Leggings:\n" + + EnumChatFormatting.GOLD + "Wither Boots:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooks) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherBloods) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherCloaks) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.implosions) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherShields) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowWarps) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.necronsHandles) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.autoRecombs) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherHelms) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherChests) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherLegs) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherBoots) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f7CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f7TimeSpent); + break; + case "catacombs_floor_seven_session": + dropsText = EnumChatFormatting.GOLD + "Recombobulators:\n" + + EnumChatFormatting.DARK_PURPLE + "Fuming Potato Books:\n" + + EnumChatFormatting.DARK_PURPLE + "Wither Bloods:\n" + + EnumChatFormatting.DARK_PURPLE + "Wither Cloaks:\n" + + EnumChatFormatting.DARK_PURPLE + "Implosions:\n" + + EnumChatFormatting.DARK_PURPLE + "Wither Shields:\n" + + EnumChatFormatting.DARK_PURPLE + "Shadow Warps:\n" + + EnumChatFormatting.DARK_PURPLE + "Necron's Handles:\n" + + EnumChatFormatting.GOLD + "Auto Recombobulators:\n" + + EnumChatFormatting.GOLD + "Wither Helmets:\n" + + EnumChatFormatting.GOLD + "Wither Chests:\n" + + EnumChatFormatting.GOLD + "Wither Leggings:\n" + + EnumChatFormatting.GOLD + "Wither Boots:\n" + + EnumChatFormatting.AQUA + "Coins Spent:\n" + + EnumChatFormatting.AQUA + "Time Spent:"; + countText = EnumChatFormatting.GOLD + nf.format(LootCommand.recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherBloodsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherCloaksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.implosionsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.witherShieldsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.shadowWarpsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + nf.format(LootCommand.necronsHandlesSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.autoRecombsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherHelmsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherChestsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherLegsSession) + "\n" + + EnumChatFormatting.GOLD + nf.format(LootCommand.witherBootsSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getMoneySpent(LootCommand.f7CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + Utils.getTimeBetween(0, LootCommand.f7TimeSpentSession); + break; + default: + System.out.println("Display was an unknown value, turning off."); + DisplayCommand.display = "off"; + ConfigHandler.writeStringConfig("misc", "display", "off"); + } + new TextRenderer(mc, dropsText, MoveCommand.displayXY[0], MoveCommand.displayXY[1], ScaleCommand.displayScale); + new TextRenderer(mc, countText, (int) (MoveCommand.displayXY[0] + (110 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); } - new TextRenderer(mc, dropsText, MoveCommand.displayXY[0], MoveCommand.displayXY[1], ScaleCommand.displayScale); - new TextRenderer(mc, countText, (int) (MoveCommand.displayXY[0] + (110 * ScaleCommand.displayScale)), MoveCommand.displayXY[1], ScaleCommand.displayScale); - } if (showTitle) { Utils.drawTitle(titleText); @@ -2214,7 +2337,7 @@ public class TheMod AxisAlignedBB creeperScan = new AxisAlignedBB(x - 14, y - 8, z - 13, x + 14, y + 8, z + 13); // 28x16x26 cube List creepers = world.getEntitiesWithinAABB(EntityCreeper.class, creeperScan); // Check if creeper is nearby - if (creepers.size() > 0) { + if (creepers.size() > 0 && !creepers.get(0).isInvisible()) { // Don't show Wither Cloak creepers EntityCreeper creeper = creepers.get(0); // Start creeper line drawings creeperLines.clear(); @@ -2431,16 +2554,24 @@ public class TheMod if (guiToOpen.startsWith("dankergui")) { int page = Character.getNumericValue(guiToOpen.charAt(guiToOpen.length() - 1)); mc.displayGuiScreen(new DankerGui(page)); - } else if (guiToOpen.equals("displaygui")) { - mc.displayGuiScreen(new DisplayGui()); - } else if (guiToOpen.equals("onlyslayergui")) { - mc.displayGuiScreen(new OnlySlayerGui()); - } else if (guiToOpen.equals("editlocations")) { - mc.displayGuiScreen(new EditLocationsGui()); - } else if (guiToOpen.equals("puzzlesolvers")) { - mc.displayGuiScreen(new PuzzleSolversGui()); - } else if (guiToOpen.equals("skilltracker")) { - mc.displayGuiScreen(new SkillTrackerGui()); + } else { + switch (guiToOpen) { + case "displaygui": + mc.displayGuiScreen(new DisplayGui()); + break; + case "onlyslayergui": + mc.displayGuiScreen(new OnlySlayerGui()); + break; + case "editlocations": + mc.displayGuiScreen(new EditLocationsGui()); + break; + case "puzzlesolvers": + mc.displayGuiScreen(new PuzzleSolversGui()); + break; + case "skilltracker": + mc.displayGuiScreen(new SkillTrackerGui()); + break; + } } guiToOpen = null; } diff --git a/src/main/java/me/Danker/commands/BlockSlayerCommand.java b/src/main/java/me/Danker/commands/BlockSlayerCommand.java index 96ea530..d2144f6 100644 --- a/src/main/java/me/Danker/commands/BlockSlayerCommand.java +++ b/src/main/java/me/Danker/commands/BlockSlayerCommand.java @@ -50,21 +50,25 @@ public class BlockSlayerCommand extends CommandBase { return; } - if (arg1[0].equalsIgnoreCase("zombie")) { - onlySlayerName = "Revenant Horror"; - } else if (arg1[0].equalsIgnoreCase("spider")) { - onlySlayerName = "Tarantula Broodfather"; - } else if (arg1[0].equalsIgnoreCase("wolf")) { - onlySlayerName = "Sven Packmaster"; - } else if (arg1[0].equalsIgnoreCase("off")) { - onlySlayerName = ""; - onlySlayerNumber = ""; - ConfigHandler.writeStringConfig("toggles", "BlockSlayer", ""); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Slayer blocking turned off.")); - return; - } else { - player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); - return; + switch (arg1[0].toLowerCase()) { + case "zombie": + onlySlayerName = "Revenant Horror"; + break; + case "spider": + onlySlayerName = "Tarantula Broodfather"; + break; + case "wolf": + onlySlayerName = "Sven Packmaster"; + break; + case "off": + onlySlayerName = ""; + onlySlayerNumber = ""; + ConfigHandler.writeStringConfig("toggles", "BlockSlayer", ""); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Slayer blocking turned off.")); + return; + default: + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); + return; } int slayerNumber = Integer.parseInt(arg1[1]); diff --git a/src/main/java/me/Danker/commands/DHelpCommand.java b/src/main/java/me/Danker/commands/DHelpCommand.java index d514fbd..e900c57 100644 --- a/src/main/java/me/Danker/commands/DHelpCommand.java +++ b/src/main/java/me/Danker/commands/DHelpCommand.java @@ -37,9 +37,9 @@ public class DHelpCommand extends CommandBase { EnumChatFormatting.GOLD + " /toggle " + EnumChatFormatting.AQUA + " - Toggles features. /toggle list returns values of every toggle.\n" + EnumChatFormatting.GOLD + " /setkey " + EnumChatFormatting.AQUA + " - Sets API key.\n" + EnumChatFormatting.GOLD + " /getkey" + EnumChatFormatting.AQUA + " - Returns key set with /setkey and copies it to your clipboard.\n" + - EnumChatFormatting.GOLD + " /loot [winter/festival/spooky/f(1-7)/session]" + EnumChatFormatting.AQUA + " - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead.\n" + - EnumChatFormatting.GOLD + " /display [winter/festival/spooky/f(1-7)/session]" + EnumChatFormatting.AQUA + " - Text display for trackers. /display fishing winter displays winter sea creatures instead. /display auto automatically displays the loot for the slayer quest you have active.\n" + - EnumChatFormatting.GOLD + " /resetloot " + EnumChatFormatting.AQUA + " - Resets loot for trackers. /resetloot confirm confirms the reset.\n" + + EnumChatFormatting.GOLD + " /loot [winter/festival/spooky/f(1-7)/session]" + EnumChatFormatting.AQUA + " - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead.\n" + + EnumChatFormatting.GOLD + " /display [winter/festival/spooky/f(1-7)/session]" + EnumChatFormatting.AQUA + " - Text display for trackers. /display fishing winter displays winter sea creatures instead. /display auto automatically displays the loot for the slayer quest you have active.\n" + + EnumChatFormatting.GOLD + " /resetloot " + EnumChatFormatting.AQUA + " - Resets loot for trackers. /resetloot confirm confirms the reset.\n" + EnumChatFormatting.GOLD + " /move " + EnumChatFormatting.AQUA + " - Moves text display to specified X and Y coordinates.\n" + EnumChatFormatting.GOLD + " /scale " + EnumChatFormatting.AQUA + " - Scales text display to a specified multipler between 0.1x and 10x.\n" + EnumChatFormatting.GOLD + " /slayer [player]" + EnumChatFormatting.AQUA + " - Uses API to get slayer xp of a person. If no name is provided, it checks yours.\n" + diff --git a/src/main/java/me/Danker/commands/DisplayCommand.java b/src/main/java/me/Danker/commands/DisplayCommand.java index 8ee18ec..1cd8c80 100644 --- a/src/main/java/me/Danker/commands/DisplayCommand.java +++ b/src/main/java/me/Danker/commands/DisplayCommand.java @@ -22,7 +22,7 @@ public class DisplayCommand extends CommandBase { @Override public String getCommandUsage(ICommandSender arg0) { - return "/" + getCommandName() + " [winter/festival/spooky/session/f(1-7)]"; + return "/" + getCommandName() + " [winter/festival/spooky/session/f(1-7)]"; } @Override @@ -33,7 +33,7 @@ public class DisplayCommand extends CommandBase { @Override public List addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) { if (args.length == 1) { - return getListOfStringsMatchingLastWord(args, "wolf", "spider", "zombie", "fishing", "catacombs", "auto", "off"); + return getListOfStringsMatchingLastWord(args, "wolf", "spider", "zombie", "fishing", "catacombs", "mythological", "auto", "off"); } else if (args.length == 2 && args[0].equalsIgnoreCase("fishing")) { return getListOfStringsMatchingLastWord(args, "winter", "festival", "spooky", "session"); } else if (args.length == 2 && args[0].equalsIgnoreCase("catacombs")) { @@ -57,42 +57,57 @@ public class DisplayCommand extends CommandBase { if (arg1[arg1.length - 1].equalsIgnoreCase("session")) showSession = true; - if (arg1[0].equalsIgnoreCase("wolf")) { + switch (arg1[0].toLowerCase()) { + case "wolf": if (showSession) { display = "wolf_session"; } else { display = "wolf"; } - } else if (arg1[0].equalsIgnoreCase("spider")) { + break; + case "spider": if (showSession) { display = "spider_session"; } else { display = "spider"; } - } else if (arg1[0].equalsIgnoreCase("zombie")) { + case "zombie": if (showSession) { display = "zombie_session"; } else { display = "zombie"; } - } else if (arg1[0].equalsIgnoreCase("fishing")) { - if (arg1.length > 1 && arg1[1].equalsIgnoreCase("winter")) { - if (showSession) { - display = "fishing_winter_session"; - } else { - display = "fishing_winter"; - } - } else if (arg1.length > 1 && arg1[1].equalsIgnoreCase("festival")) { - if (showSession) { - display = "fishing_festival_session"; - } else { - display = "fishing_festival"; - } - } else if (arg1.length > 1 && arg1[1].equalsIgnoreCase("spooky")) { - if (showSession) { - display = "fishing_spooky_session"; - } else { - display = "fishing_spooky"; + break; + case "fishing": + if (arg1.length > 1) { + switch (arg1[1].toLowerCase()) { + case "winter": + if (showSession) { + display = "fishing_winter_session"; + } else { + display = "fishing_winter"; + } + break; + case "festival": + if (showSession) { + display = "fishing_festival_session"; + } else { + display = "fishing_festival"; + } + break; + case "spooky": + if (showSession) { + display = "fishing_spooky_session"; + } else { + display = "fishing_spooky"; + } + break; + default: + if (showSession) { + display = "fishing_session"; + } else { + display = "fishing"; + } } } else { if (showSession) { @@ -100,69 +115,96 @@ public class DisplayCommand extends CommandBase { } else { display = "fishing"; } - } - } else if (arg1[0].equalsIgnoreCase("catacombs")) { - if (arg1.length == 1) { - player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: /display catacombs ")); - return; } - if (arg1[1].equalsIgnoreCase("f1") || arg1[1].equalsIgnoreCase("floor1")) { - if (showSession) { - display = "catacombs_floor_one_session"; - } else { - display = "catacombs_floor_one"; - } - } else if (arg1[1].equalsIgnoreCase("f2") || arg1[1].equalsIgnoreCase("floor2")) { - if (showSession) { - display = "catacombs_floor_two_session"; - } else { - display = "catacombs_floor_two"; - } - } else if (arg1[1].equalsIgnoreCase("f3") || arg1[1].equalsIgnoreCase("floor3")) { - if (showSession) { - display = "catacombs_floor_three_session"; - } else { - display = "catacombs_floor_three"; - } - } else if (arg1[1].equalsIgnoreCase("f4") || arg1[1].equalsIgnoreCase("floor4")) { - if (showSession) { - display = "catacombs_floor_four_session"; - } else { - display = "catacombs_floor_four"; - } - } else if (arg1[1].equalsIgnoreCase("f5") || arg1[1].equalsIgnoreCase("floor5")) { - if (showSession) { - display = "catacombs_floor_five_session"; - } else { - display = "catacombs_floor_five"; - } - } else if (arg1[1].equalsIgnoreCase("f6") || arg1[1].equalsIgnoreCase("floor6")) { - if (showSession) { - display = "catacombs_floor_six_session"; - } else { - display = "catacombs_floor_six"; - } - } else if (arg1[1].equalsIgnoreCase("f7") || arg1[1].equalsIgnoreCase("floor7")) { - if (showSession) { - display = "catacombs_floor_seven_session"; - } else { - display = "catacombs_floor_seven"; - } + break; + case "mythological": + if (showSession) { + display = "mythological_session"; } else { - player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: /display catacombs ")); + display = "mythological"; + } + break; + case "catacombs": + if (arg1.length == 1) { + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: /display catacombs ")); return; } - } else if (arg1[0].equalsIgnoreCase("auto")) { + + switch (arg1[1].toLowerCase()) { + case "f1": + case "floor1": + if (showSession) { + display = "catacombs_floor_one_session"; + } else { + display = "catacombs_floor_one"; + } + break; + case "f2": + case "floor2": + if (showSession) { + display = "catacombs_floor_two_session"; + } else { + display = "catacombs_floor_two"; + } + break; + case "f3": + case "floor3": + if (showSession) { + display = "catacombs_floor_three_session"; + } else { + display = "catacombs_floor_three"; + } + break; + case "f4": + case "floor4": + if (showSession) { + display = "catacombs_floor_four_session"; + } else { + display = "catacombs_floor_four"; + } + break; + case "f5": + case "floor5": + if (showSession) { + display = "catacombs_floor_five_session"; + } else { + display = "catacombs_floor_five"; + } + break; + case "f6": + case "floor6": + if (showSession) { + display = "catacombs_floor_six_session"; + } else { + display = "catacombs_floor_six"; + } + break; + case "f7": + case "floor7": + if (showSession) { + display = "catacombs_floor_seven_session"; + } else { + display = "catacombs_floor_seven"; + } + break; + default: + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: /display catacombs ")); + return; + } + break; + case "auto": auto = true; player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Display set to " + TheMod.SECONDARY_COLOUR + "auto" + TheMod.MAIN_COLOUR + ".")); ConfigHandler.writeBooleanConfig("misc", "autoDisplay", true); return; - } else if (arg1[0].equalsIgnoreCase("off")) { + case "off": display = "off"; - } else { + break; + default: player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); return; } + auto = false; player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Display set to " + TheMod.SECONDARY_COLOUR + display + TheMod.MAIN_COLOUR + ".")); ConfigHandler.writeBooleanConfig("misc", "autoDisplay", false); diff --git a/src/main/java/me/Danker/commands/LootCommand.java b/src/main/java/me/Danker/commands/LootCommand.java index f66d0c4..ffe5e49 100644 --- a/src/main/java/me/Danker/commands/LootCommand.java +++ b/src/main/java/me/Danker/commands/LootCommand.java @@ -96,6 +96,18 @@ public class LootCommand extends CommandBase { public static int phantomFishers; public static int grimReapers; + // Mythological + public static double mythCoins; + public static int griffinFeathers; + public static int crownOfGreeds; + public static int washedUpSouvenirs; + public static int minosHunters; + public static int siameseLynxes; + public static int minotaurs; + public static int gaiaConstructs; + public static int minosChampions; + public static int minosInquisitors; + // Catacombs Dungeons public static int recombobulators; public static int fumingPotatoBooks; @@ -244,6 +256,18 @@ public class LootCommand extends CommandBase { public static int phantomFishersSession = 0; public static int grimReapersSession = 0; + // Mythological + public static double mythCoinsSession = 0; + public static int griffinFeathersSession = 0; + public static int crownOfGreedsSession = 0; + public static int washedUpSouvenirsSession = 0; + public static int minosHuntersSession = 0; + public static int siameseLynxesSession = 0; + public static int minotaursSession = 0; + public static int gaiaConstructsSession = 0; + public static int minosChampionsSession = 0; + public static int minosInquisitorsSession = 0; + // Catacombs Dungeons public static int recombobulatorsSession = 0; public static int fumingPotatoBooksSession = 0; @@ -317,7 +341,7 @@ public class LootCommand extends CommandBase { @Override public String getCommandUsage(ICommandSender arg0) { - return "/" + getCommandName() + " [winter/festival/spooky/f(1-7)/session]"; + return "/" + getCommandName() + " [winter/festival/spooky/f(1-7)/session]"; } @Override @@ -328,7 +352,7 @@ public class LootCommand extends CommandBase { @Override public List addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) { if (args.length == 1) { - return getListOfStringsMatchingLastWord(args, "wolf", "spider", "zombie", "fishing", "catacombs"); + return getListOfStringsMatchingLastWord(args, "wolf", "spider", "zombie", "fishing", "catacombs", "mythological"); } else if (args.length == 2 && args[0].equalsIgnoreCase("fishing")) { return getListOfStringsMatchingLastWord(args, "winter", "festival", "spooky", "session"); } else if (args.length == 2 && args[0].equalsIgnoreCase("catacombs")) { @@ -357,584 +381,636 @@ public class LootCommand extends CommandBase { if (arg1[arg1.length - 1].equalsIgnoreCase("session")) showSession = true; - if (arg1[0].equalsIgnoreCase("wolf")) { - if (showSession) { - if (wolfTimeSession == -1) { + switch (arg1[0].toLowerCase()) { + case "wolf": + if (showSession) { + if (wolfTimeSession == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(wolfTimeSession, timeNow); + } + if (wolfBossesSession == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(wolfBossesSession); + } + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(wolfWheelsSession); + } else { + drop20 = nf.format(wolfWheelsDropsSession) + " times"; + } + + player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.DARK_AQUA + EnumChatFormatting.BOLD + " Sven Loot Summary (Current Session):\n" + + EnumChatFormatting.GOLD + " Svens Killed: " + nf.format(wolfSvensSession) + "\n" + + EnumChatFormatting.GREEN + " Wolf Teeth: " + nf.format(wolfTeethSession) + "\n" + + EnumChatFormatting.BLUE + " Hamster Wheels: " + drop20 + "\n" + + EnumChatFormatting.AQUA + " Spirit Runes: " + wolfSpiritsSession + "\n" + + EnumChatFormatting.WHITE + " Critical VI Books: " + wolfBooksSession + "\n" + + EnumChatFormatting.DARK_RED + " Red Claw Eggs: " + wolfEggsSession + "\n" + + EnumChatFormatting.GOLD + " Couture Runes: " + wolfCouturesSession + "\n" + + EnumChatFormatting.AQUA + " Grizzly Baits: " + wolfBaitsSession + "\n" + + EnumChatFormatting.DARK_PURPLE + " Overfluxes: " + wolfFluxesSession + "\n" + + EnumChatFormatting.AQUA + " Time Since RNG: " + timeBetween + "\n" + + EnumChatFormatting.AQUA + " Bosses Since RNG: " + bossesBetween + "\n" + + EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " -------------------")); + return; + } + + if (wolfTime == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(wolfTimeSession, timeNow); + timeBetween = Utils.getTimeBetween(wolfTime, timeNow); } - if (wolfBossesSession == -1) { + if (wolfBosses == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(wolfBossesSession); + bossesBetween = nf.format(wolfBosses); } if (ToggleCommand.slayerCountTotal) { - drop20 = nf.format(wolfWheelsSession); + drop20 = nf.format(wolfWheels); } else { - drop20 = nf.format(wolfWheelsDropsSession) + " times"; + drop20 = nf.format(wolfWheelsDrops) + " times"; } player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.DARK_AQUA + EnumChatFormatting.BOLD + " Sven Loot Summary (Current Session):\n" + - EnumChatFormatting.GOLD + " Svens Killed: " + nf.format(wolfSvensSession) + "\n" + - EnumChatFormatting.GREEN + " Wolf Teeth: " + nf.format(wolfTeethSession) + "\n" + + EnumChatFormatting.DARK_AQUA + EnumChatFormatting.BOLD + " Sven Loot Summary:\n" + + EnumChatFormatting.GOLD + " Svens Killed: " + nf.format(wolfSvens) + "\n" + + EnumChatFormatting.GREEN + " Wolf Teeth: " + nf.format(wolfTeeth) + "\n" + EnumChatFormatting.BLUE + " Hamster Wheels: " + drop20 + "\n" + - EnumChatFormatting.AQUA + " Spirit Runes: " + wolfSpiritsSession + "\n" + - EnumChatFormatting.WHITE + " Critical VI Books: " + wolfBooksSession + "\n" + - EnumChatFormatting.DARK_RED + " Red Claw Eggs: " + wolfEggsSession + "\n" + - EnumChatFormatting.GOLD + " Couture Runes: " + wolfCouturesSession + "\n" + - EnumChatFormatting.AQUA + " Grizzly Baits: " + wolfBaitsSession + "\n" + - EnumChatFormatting.DARK_PURPLE + " Overfluxes: " + wolfFluxesSession + "\n" + + EnumChatFormatting.AQUA + " Spirit Runes: " + wolfSpirits + "\n" + + EnumChatFormatting.WHITE + " Critical VI Books: " + wolfBooks + "\n" + + EnumChatFormatting.DARK_RED + " Red Claw Eggs: " + wolfEggs + "\n" + + EnumChatFormatting.GOLD + " Couture Runes: " + wolfCoutures + "\n" + + EnumChatFormatting.AQUA + " Grizzly Baits: " + wolfBaits + "\n" + + EnumChatFormatting.DARK_PURPLE + " Overfluxes: " + wolfFluxes + "\n" + EnumChatFormatting.AQUA + " Time Since RNG: " + timeBetween + "\n" + EnumChatFormatting.AQUA + " Bosses Since RNG: " + bossesBetween + "\n" + EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " -------------------")); - return; - } - - if (wolfTime == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(wolfTime, timeNow); - } - if (wolfBosses == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(wolfBosses); - } - if (ToggleCommand.slayerCountTotal) { - drop20 = nf.format(wolfWheels); - } else { - drop20 = nf.format(wolfWheelsDrops) + " times"; - } - - player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.DARK_AQUA + EnumChatFormatting.BOLD + " Sven Loot Summary:\n" + - EnumChatFormatting.GOLD + " Svens Killed: " + nf.format(wolfSvens) + "\n" + - EnumChatFormatting.GREEN + " Wolf Teeth: " + nf.format(wolfTeeth) + "\n" + - EnumChatFormatting.BLUE + " Hamster Wheels: " + drop20 + "\n" + - EnumChatFormatting.AQUA + " Spirit Runes: " + wolfSpirits + "\n" + - EnumChatFormatting.WHITE + " Critical VI Books: " + wolfBooks + "\n" + - EnumChatFormatting.DARK_RED + " Red Claw Eggs: " + wolfEggs + "\n" + - EnumChatFormatting.GOLD + " Couture Runes: " + wolfCoutures + "\n" + - EnumChatFormatting.AQUA + " Grizzly Baits: " + wolfBaits + "\n" + - EnumChatFormatting.DARK_PURPLE + " Overfluxes: " + wolfFluxes + "\n" + - EnumChatFormatting.AQUA + " Time Since RNG: " + timeBetween + "\n" + - EnumChatFormatting.AQUA + " Bosses Since RNG: " + bossesBetween + "\n" + - EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " -------------------")); - } else if (arg1[0].equalsIgnoreCase("spider")) { - if (showSession) { - if (spiderTimeSession == -1) { + break; + case "spider": + if (showSession) { + if (spiderTimeSession == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(spiderTimeSession, timeNow); + } + if (spiderBossesSession == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(spiderBossesSession); + } + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(spiderTAPSession); + } else { + drop20 = nf.format(spiderTAPDropsSession) + " times"; + } + + player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " Spider Loot Summary (Current Session):\n" + + EnumChatFormatting.GOLD + " Tarantulas Killed: " + nf.format(spiderTarantulasSession) + "\n" + + EnumChatFormatting.GREEN + " Tarantula Webs: " + nf.format(spiderWebsSession) + "\n" + + EnumChatFormatting.DARK_GREEN + " Arrow Poison: " + drop20 + "\n" + + EnumChatFormatting.DARK_GRAY + " Bite Runes: " + spiderBitesSession + "\n" + + EnumChatFormatting.WHITE + " Bane VI Books: " + spiderBooksSession + "\n" + + EnumChatFormatting.AQUA + " Spider Catalysts: " + spiderCatalystsSession + "\n" + + EnumChatFormatting.DARK_PURPLE + " Tarantula Talismans: " + spiderTalismansSession + "\n" + + EnumChatFormatting.LIGHT_PURPLE + " Fly Swatters: " + spiderSwattersSession + "\n" + + EnumChatFormatting.GOLD + " Digested Mosquitos: " + spiderMosquitosSession + "\n" + + EnumChatFormatting.AQUA + " Time Since RNG: " + timeBetween + "\n" + + EnumChatFormatting.AQUA + " Bosses Since RNG: " + bossesBetween + "\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " -------------------")); + return; + } + + if (spiderTime == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(spiderTimeSession, timeNow); + timeBetween = Utils.getTimeBetween(spiderTime, timeNow); } - if (spiderBossesSession == -1) { + if (spiderBosses == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(spiderBossesSession); + bossesBetween = nf.format(spiderBosses); } if (ToggleCommand.slayerCountTotal) { - drop20 = nf.format(spiderTAPSession); + drop20 = nf.format(spiderTAP); } else { - drop20 = nf.format(spiderTAPDropsSession) + " times"; + drop20 = nf.format(spiderTAPDrops) + " times"; } player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " Spider Loot Summary (Current Session):\n" + - EnumChatFormatting.GOLD + " Tarantulas Killed: " + nf.format(spiderTarantulasSession) + "\n" + - EnumChatFormatting.GREEN + " Tarantula Webs: " + nf.format(spiderWebsSession) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " Spider Loot Summary:\n" + + EnumChatFormatting.GOLD + " Tarantulas Killed: " + nf.format(spiderTarantulas) + "\n" + + EnumChatFormatting.GREEN + " Tarantula Webs: " + nf.format(spiderWebs) + "\n" + EnumChatFormatting.DARK_GREEN + " Arrow Poison: " + drop20 + "\n" + - EnumChatFormatting.DARK_GRAY + " Bite Runes: " + spiderBitesSession + "\n" + - EnumChatFormatting.WHITE + " Bane VI Books: " + spiderBooksSession + "\n" + - EnumChatFormatting.AQUA + " Spider Catalysts: " + spiderCatalystsSession + "\n" + - EnumChatFormatting.DARK_PURPLE + " Tarantula Talismans: " + spiderTalismansSession + "\n" + - EnumChatFormatting.LIGHT_PURPLE + " Fly Swatters: " + spiderSwattersSession + "\n" + - EnumChatFormatting.GOLD + " Digested Mosquitos: " + spiderMosquitosSession + "\n" + + EnumChatFormatting.DARK_GRAY + " Bite Runes: " + spiderBites + "\n" + + EnumChatFormatting.WHITE + " Bane VI Books: " + spiderBooks + "\n" + + EnumChatFormatting.AQUA + " Spider Catalysts: " + spiderCatalysts + "\n" + + EnumChatFormatting.DARK_PURPLE + " Tarantula Talismans: " + spiderTalismans + "\n" + + EnumChatFormatting.LIGHT_PURPLE + " Fly Swatters: " + spiderSwatters + "\n" + + EnumChatFormatting.GOLD + " Digested Mosquitos: " + spiderMosquitos + "\n" + EnumChatFormatting.AQUA + " Time Since RNG: " + timeBetween + "\n" + EnumChatFormatting.AQUA + " Bosses Since RNG: " + bossesBetween + "\n" + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " -------------------")); - return; - } - - if (spiderTime == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(spiderTime, timeNow); - } - if (spiderBosses == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(spiderBosses); - } - if (ToggleCommand.slayerCountTotal) { - drop20 = nf.format(spiderTAP); - } else { - drop20 = nf.format(spiderTAPDrops) + " times"; - } - - player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " Spider Loot Summary:\n" + - EnumChatFormatting.GOLD + " Tarantulas Killed: " + nf.format(spiderTarantulas) + "\n" + - EnumChatFormatting.GREEN + " Tarantula Webs: " + nf.format(spiderWebs) + "\n" + - EnumChatFormatting.DARK_GREEN + " Arrow Poison: " + drop20 + "\n" + - EnumChatFormatting.DARK_GRAY + " Bite Runes: " + spiderBites + "\n" + - EnumChatFormatting.WHITE + " Bane VI Books: " + spiderBooks + "\n" + - EnumChatFormatting.AQUA + " Spider Catalysts: " + spiderCatalysts + "\n" + - EnumChatFormatting.DARK_PURPLE + " Tarantula Talismans: " + spiderTalismans + "\n" + - EnumChatFormatting.LIGHT_PURPLE + " Fly Swatters: " + spiderSwatters + "\n" + - EnumChatFormatting.GOLD + " Digested Mosquitos: " + spiderMosquitos + "\n" + - EnumChatFormatting.AQUA + " Time Since RNG: " + timeBetween + "\n" + - EnumChatFormatting.AQUA + " Bosses Since RNG: " + bossesBetween + "\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " -------------------")); - } else if (arg1[0].equalsIgnoreCase("zombie")) { - if (showSession) { - if (zombieTimeSession == -1) { + break; + case "zombie": + if (showSession) { + if (zombieTimeSession == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(zombieTimeSession, timeNow); + } + if (zombieBossesSession == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(zombieBossesSession); + } + if (ToggleCommand.slayerCountTotal) { + drop20 = nf.format(zombieFoulFleshSession); + } else { + drop20 = nf.format(zombieFoulFleshDropsSession) + " times"; + } + + player.addChatMessage(new ChatComponentText(EnumChatFormatting.GREEN + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.DARK_GREEN + EnumChatFormatting.BOLD + " Zombie Loot Summary (Current Session):\n" + + EnumChatFormatting.GOLD + " Revs Killed: " + nf.format(zombieRevsSession) + "\n" + + EnumChatFormatting.GREEN + " Revenant Flesh: " + nf.format(zombieRevFleshSession) + "\n" + + EnumChatFormatting.BLUE + " Foul Flesh: " + drop20 + "\n" + + EnumChatFormatting.DARK_GREEN + " Pestilence Runes: " + zombiePestilencesSession + "\n" + + EnumChatFormatting.WHITE + " Smite VI Books: " + zombieBooksSession + "\n" + + EnumChatFormatting.AQUA + " Undead Catalysts: " + zombieUndeadCatasSession + "\n" + + EnumChatFormatting.DARK_PURPLE + " Beheaded Horrors: " + zombieBeheadedsSession + "\n" + + EnumChatFormatting.RED + " Revenant Catalysts: " + zombieRevCatasSession + "\n" + + EnumChatFormatting.DARK_GREEN + " Snake Runes: " + zombieSnakesSession + "\n" + + EnumChatFormatting.GOLD + " Scythe Blades: " + zombieScythesSession + "\n" + + EnumChatFormatting.AQUA + " Time Since RNG: " + timeBetween + "\n" + + EnumChatFormatting.AQUA + " Bosses Since RNG: " + bossesBetween + "\n" + + EnumChatFormatting.GREEN + EnumChatFormatting.BOLD + " -------------------")); + return; + } + + if (zombieTime == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(zombieTimeSession, timeNow); + timeBetween = Utils.getTimeBetween(zombieTime, timeNow); } - if (zombieBossesSession == -1) { + if (zombieBosses == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(zombieBossesSession); + bossesBetween = nf.format(zombieBosses); } if (ToggleCommand.slayerCountTotal) { - drop20 = nf.format(zombieFoulFleshSession); + drop20 = nf.format(zombieFoulFlesh); } else { - drop20 = nf.format(zombieFoulFleshDropsSession) + " times"; + drop20 = nf.format(zombieFoulFleshDrops) + " times"; } player.addChatMessage(new ChatComponentText(EnumChatFormatting.GREEN + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.DARK_GREEN + EnumChatFormatting.BOLD + " Zombie Loot Summary (Current Session):\n" + - EnumChatFormatting.GOLD + " Revs Killed: " + nf.format(zombieRevsSession) + "\n" + - EnumChatFormatting.GREEN + " Revenant Flesh: " + nf.format(zombieRevFleshSession) + "\n" + + EnumChatFormatting.DARK_GREEN + EnumChatFormatting.BOLD + " Zombie Loot Summary:\n" + + EnumChatFormatting.GOLD + " Revs Killed: " + nf.format(zombieRevs) + "\n" + + EnumChatFormatting.GREEN + " Revenant Flesh: " + nf.format(zombieRevFlesh) + "\n" + EnumChatFormatting.BLUE + " Foul Flesh: " + drop20 + "\n" + - EnumChatFormatting.DARK_GREEN + " Pestilence Runes: " + zombiePestilencesSession + "\n" + - EnumChatFormatting.WHITE + " Smite VI Books: " + zombieBooksSession + "\n" + - EnumChatFormatting.AQUA + " Undead Catalysts: " + zombieUndeadCatasSession + "\n" + - EnumChatFormatting.DARK_PURPLE + " Beheaded Horrors: " + zombieBeheadedsSession + "\n" + - EnumChatFormatting.RED + " Revenant Catalysts: " + zombieRevCatasSession + "\n" + - EnumChatFormatting.DARK_GREEN + " Snake Runes: " + zombieSnakesSession + "\n" + - EnumChatFormatting.GOLD + " Scythe Blades: " + zombieScythesSession + "\n" + + EnumChatFormatting.DARK_GREEN + " Pestilence Runes: " + zombiePestilences + "\n" + + EnumChatFormatting.WHITE + " Smite VI Books: " + zombieBooks + "\n" + + EnumChatFormatting.AQUA + " Undead Catalysts: " + zombieUndeadCatas + "\n" + + EnumChatFormatting.DARK_PURPLE + " Beheaded Horrors: " + zombieBeheadeds + "\n" + + EnumChatFormatting.RED + " Revenant Catalysts: " + zombieRevCatas + "\n" + + EnumChatFormatting.DARK_GREEN + " Snake Runes: " + zombieSnakes + "\n" + + EnumChatFormatting.GOLD + " Scythe Blades: " + zombieScythes + "\n" + EnumChatFormatting.AQUA + " Time Since RNG: " + timeBetween + "\n" + EnumChatFormatting.AQUA + " Bosses Since RNG: " + bossesBetween + "\n" + EnumChatFormatting.GREEN + EnumChatFormatting.BOLD + " -------------------")); - return; - } - - if (zombieTime == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(zombieTime, timeNow); - } - if (zombieBosses == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(zombieBosses); - } - if (ToggleCommand.slayerCountTotal) { - drop20 = nf.format(zombieFoulFlesh); - } else { - drop20 = nf.format(zombieFoulFleshDrops) + " times"; - } - - player.addChatMessage(new ChatComponentText(EnumChatFormatting.GREEN + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.DARK_GREEN + EnumChatFormatting.BOLD + " Zombie Loot Summary:\n" + - EnumChatFormatting.GOLD + " Revs Killed: " + nf.format(zombieRevs) + "\n" + - EnumChatFormatting.GREEN + " Revenant Flesh: " + nf.format(zombieRevFlesh) + "\n" + - EnumChatFormatting.BLUE + " Foul Flesh: " + drop20 + "\n" + - EnumChatFormatting.DARK_GREEN + " Pestilence Runes: " + zombiePestilences + "\n" + - EnumChatFormatting.WHITE + " Smite VI Books: " + zombieBooks + "\n" + - EnumChatFormatting.AQUA + " Undead Catalysts: " + zombieUndeadCatas + "\n" + - EnumChatFormatting.DARK_PURPLE + " Beheaded Horrors: " + zombieBeheadeds + "\n" + - EnumChatFormatting.RED + " Revenant Catalysts: " + zombieRevCatas + "\n" + - EnumChatFormatting.DARK_GREEN + " Snake Runes: " + zombieSnakes + "\n" + - EnumChatFormatting.GOLD + " Scythe Blades: " + zombieScythes + "\n" + - EnumChatFormatting.AQUA + " Time Since RNG: " + timeBetween + "\n" + - EnumChatFormatting.AQUA + " Bosses Since RNG: " + bossesBetween + "\n" + - EnumChatFormatting.GREEN + EnumChatFormatting.BOLD + " -------------------")); - } else if (arg1[0].equalsIgnoreCase("fishing")) { - if (arg1.length > 1) { - if (arg1[1].equalsIgnoreCase("winter")) { - if (showSession) { - if (yetiTimeSession == -1) { + break; + case "fishing": + if (arg1.length > 1) { + if (arg1[1].equalsIgnoreCase("winter")) { + if (showSession) { + if (yetiTimeSession == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(yetiTimeSession, timeNow); + } + if (yetiSCsSession == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(yetiSCsSession); + } + + player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.WHITE + EnumChatFormatting.BOLD + " Winter Fishing Summary (Current Session):\n" + + EnumChatFormatting.AQUA + " Frozen Steves: " + nf.format(frozenStevesSession) + "\n" + + EnumChatFormatting.WHITE + " Snowmans: " + nf.format(frostyTheSnowmansSession) + "\n" + + EnumChatFormatting.DARK_GREEN + " Grinches: " + nf.format(grinchesSession) + "\n" + + EnumChatFormatting.GOLD + " Yetis: " + nf.format(yetisSession) + "\n" + + EnumChatFormatting.AQUA + " Time Since Yeti: " + timeBetween + "\n" + + EnumChatFormatting.AQUA + " Creatures Since Yeti: " + bossesBetween + "\n" + + EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " -------------------")); + return; + } + + if (yetiTime == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(yetiTimeSession, timeNow); + timeBetween = Utils.getTimeBetween(yetiTime, timeNow); } - if (yetiSCsSession == -1) { + if (yetiSCs == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(yetiSCsSession); + bossesBetween = nf.format(yetiSCs); } player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.WHITE + EnumChatFormatting.BOLD + " Winter Fishing Summary (Current Session):\n" + - EnumChatFormatting.AQUA + " Frozen Steves: " + nf.format(frozenStevesSession) + "\n" + - EnumChatFormatting.WHITE + " Snowmans: " + nf.format(frostyTheSnowmansSession) + "\n" + - EnumChatFormatting.DARK_GREEN + " Grinches: " + nf.format(grinchesSession) + "\n" + - EnumChatFormatting.GOLD + " Yetis: " + nf.format(yetisSession) + "\n" + + EnumChatFormatting.WHITE + EnumChatFormatting.BOLD + " Winter Fishing Summary:\n" + + EnumChatFormatting.AQUA + " Frozen Steves: " + nf.format(frozenSteves) + "\n" + + EnumChatFormatting.WHITE + " Snowmans: " + nf.format(frostyTheSnowmans) + "\n" + + EnumChatFormatting.DARK_GREEN + " Grinches: " + nf.format(grinches) + "\n" + + EnumChatFormatting.GOLD + " Yetis: " + nf.format(yetis) + "\n" + EnumChatFormatting.AQUA + " Time Since Yeti: " + timeBetween + "\n" + EnumChatFormatting.AQUA + " Creatures Since Yeti: " + bossesBetween + "\n" + EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " -------------------")); return; + } else if (arg1[1].equalsIgnoreCase("festival")) { + if (showSession) { + player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.DARK_BLUE + EnumChatFormatting.BOLD + " Fishing Festival Summary (Current Session):\n" + + EnumChatFormatting.LIGHT_PURPLE + " Nurse Sharks: " + nf.format(nurseSharksSession) + "\n" + + EnumChatFormatting.BLUE + " Blue Sharks: " + nf.format(blueSharksSession) + "\n" + + EnumChatFormatting.GOLD + " Tiger Sharks: " + nf.format(tigerSharksSession) + "\n" + + EnumChatFormatting.WHITE + " Great White Sharks: " + nf.format(greatWhiteSharksSession) + "\n" + + EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " -------------------")); + return; + } + + player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.DARK_BLUE + EnumChatFormatting.BOLD + " Fishing Festival Summary:\n" + + EnumChatFormatting.LIGHT_PURPLE + " Nurse Sharks: " + nf.format(nurseSharks) + "\n" + + EnumChatFormatting.BLUE + " Blue Sharks: " + nf.format(blueSharks) + "\n" + + EnumChatFormatting.GOLD + " Tiger Sharks: " + nf.format(tigerSharks) + "\n" + + EnumChatFormatting.WHITE + " Great White Sharks: " + nf.format(greatWhiteSharks) + "\n" + + EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " -------------------")); + } else if (arg1[1].equalsIgnoreCase("spooky")) { + if (showSession) { + player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + " Spooky Fishing Summary (Current Session):\n" + + EnumChatFormatting.BLUE + " Scarecrows: " + nf.format(scarecrowsSession) + "\n" + + EnumChatFormatting.GRAY + " Nightmares: " + nf.format(nightmaresSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Werewolves: " + nf.format(werewolfsSession) + "\n" + + EnumChatFormatting.GOLD + " Phantom Fishers: " + nf.format(phantomFishersSession) + "\n" + + EnumChatFormatting.GOLD + " Grim Reapers: " + nf.format(grimReapersSession) + "\n" + + EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------")); + return; + } + + player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + " Spooky Fishing Summary:\n" + + EnumChatFormatting.BLUE + " Scarecrows: " + nf.format(scarecrows) + "\n" + + EnumChatFormatting.GRAY + " Nightmares: " + nf.format(nightmares) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Werewolves: " + nf.format(werewolfs) + "\n" + + EnumChatFormatting.GOLD + " Phantom Fishers: " + nf.format(phantomFishers) + "\n" + + EnumChatFormatting.GOLD + " Grim Reapers: " + nf.format(grimReapers) + "\n" + + EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------")); } - - if (yetiTime == -1) { + } + + if (showSession) { + if (empTimeSession == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(yetiTime, timeNow); + timeBetween = Utils.getTimeBetween(empTimeSession, timeNow); } - if (yetiSCs == -1) { + if (empSCsSession == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(yetiSCs); + bossesBetween = nf.format(empSCsSession); } - player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.WHITE + EnumChatFormatting.BOLD + " Winter Fishing Summary:\n" + - EnumChatFormatting.AQUA + " Frozen Steves: " + nf.format(frozenSteves) + "\n" + - EnumChatFormatting.WHITE + " Snowmans: " + nf.format(frostyTheSnowmans) + "\n" + - EnumChatFormatting.DARK_GREEN + " Grinches: " + nf.format(grinches) + "\n" + - EnumChatFormatting.GOLD + " Yetis: " + nf.format(yetis) + "\n" + - EnumChatFormatting.AQUA + " Time Since Yeti: " + timeBetween + "\n" + - EnumChatFormatting.AQUA + " Creatures Since Yeti: " + bossesBetween + "\n" + - EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " -------------------")); + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " Fishing Summary (Current Session):\n" + + EnumChatFormatting.AQUA + " Sea Creatures Caught: " + nf.format(seaCreaturesSession) + "\n" + + EnumChatFormatting.GOLD + " Good Catches: " + nf.format(goodCatchesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Great Catches: " + nf.format(greatCatchesSession) + "\n\n" + + EnumChatFormatting.GRAY + " Squids: " + nf.format(squidsSession) + "\n" + + EnumChatFormatting.GREEN + " Sea Walkers: " + nf.format(seaWalkersSession) + "\n" + + EnumChatFormatting.DARK_GRAY + " Night Squids: " + nf.format(nightSquidsSession) + "\n" + + EnumChatFormatting.DARK_AQUA + " Sea Guardians: " + nf.format(seaGuardiansSession) + "\n" + + EnumChatFormatting.BLUE + " Sea Witches: " + nf.format(seaWitchesSession) + "\n" + + EnumChatFormatting.GREEN + " Sea Archers: " + nf.format(seaArchersSession) + "\n" + + EnumChatFormatting.GREEN + " Monster of the Deeps: " + nf.format(monsterOfTheDeepsSession) + "\n" + + EnumChatFormatting.YELLOW + " Catfishes: " + nf.format(catfishesSession) + "\n" + + EnumChatFormatting.GOLD + " Carrot Kings: " + nf.format(carrotKingsSession) + "\n" + + EnumChatFormatting.GRAY + " Sea Leeches: " + nf.format(seaLeechesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Guardian Defenders: " + nf.format(guardianDefendersSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Deep Sea Protectors: " + nf.format(deepSeaProtectorsSession) + "\n" + + EnumChatFormatting.GOLD + " Hydras: " + nf.format(hydrasSession) + "\n" + + EnumChatFormatting.GOLD + " Sea Emperors: " + nf.format(seaEmperorsSession) + "\n" + + EnumChatFormatting.AQUA + " Time Since Sea Emperor: " + timeBetween + "\n" + + EnumChatFormatting.AQUA + " Sea Creatures Since Sea Emperor: " + bossesBetween + "\n" + + EnumChatFormatting.DARK_AQUA + EnumChatFormatting.BOLD + " -------------------")); return; - } else if (arg1[1].equalsIgnoreCase("festival")) { - if (showSession) { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.DARK_BLUE + EnumChatFormatting.BOLD + " Fishing Festival Summary (Current Session):\n" + - EnumChatFormatting.LIGHT_PURPLE + " Nurse Sharks: " + nf.format(nurseSharksSession) + "\n" + - EnumChatFormatting.BLUE + " Blue Sharks: " + nf.format(blueSharksSession) + "\n" + - EnumChatFormatting.GOLD + " Tiger Sharks: " + nf.format(tigerSharksSession) + "\n" + - EnumChatFormatting.WHITE + " Great White Sharks: " + nf.format(greatWhiteSharksSession) + "\n" + - EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " -------------------")); - return; - } - - player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.DARK_BLUE + EnumChatFormatting.BOLD + " Fishing Festival Summary:\n" + - EnumChatFormatting.LIGHT_PURPLE + " Nurse Sharks: " + nf.format(nurseSharks) + "\n" + - EnumChatFormatting.BLUE + " Blue Sharks: " + nf.format(blueSharks) + "\n" + - EnumChatFormatting.GOLD + " Tiger Sharks: " + nf.format(tigerSharks) + "\n" + - EnumChatFormatting.WHITE + " Great White Sharks: " + nf.format(greatWhiteSharks) + "\n" + - EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " -------------------")); - } else if (arg1[1].equalsIgnoreCase("spooky")) { - if (showSession) { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + " Spooky Fishing Summary (Current Session):\n" + - EnumChatFormatting.BLUE + " Scarecrows: " + nf.format(scarecrowsSession) + "\n" + - EnumChatFormatting.GRAY + " Nightmares: " + nf.format(nightmaresSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Werewolves: " + nf.format(werewolfsSession) + "\n" + - EnumChatFormatting.GOLD + " Phantom Fishers: " + nf.format(phantomFishersSession) + "\n" + - EnumChatFormatting.GOLD + " Grim Reapers: " + nf.format(grimReapersSession) + "\n" + - EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------")); - return; - } - - player.addChatMessage(new ChatComponentText(EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + " Spooky Fishing Summary:\n" + - EnumChatFormatting.BLUE + " Scarecrows: " + nf.format(scarecrows) + "\n" + - EnumChatFormatting.GRAY + " Nightmares: " + nf.format(nightmares) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Werewolves: " + nf.format(werewolfs) + "\n" + - EnumChatFormatting.GOLD + " Phantom Fishers: " + nf.format(phantomFishers) + "\n" + - EnumChatFormatting.GOLD + " Grim Reapers: " + nf.format(grimReapers) + "\n" + - EnumChatFormatting.AQUA + "" + EnumChatFormatting.BOLD + "-------------------")); } - } - - if (showSession) { - if (empTimeSession == -1) { + + if (empTime == -1) { timeBetween = "Never"; } else { - timeBetween = Utils.getTimeBetween(empTimeSession, timeNow); + timeBetween = Utils.getTimeBetween(empTime, timeNow); } - if (empSCsSession == -1) { + if (empSCs == -1) { bossesBetween = "Never"; } else { - bossesBetween = nf.format(empSCsSession); + bossesBetween = nf.format(empSCs); } player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " Fishing Summary (Current Session):\n" + - EnumChatFormatting.AQUA + " Sea Creatures Caught: " + nf.format(seaCreaturesSession) + "\n" + - EnumChatFormatting.GOLD + " Good Catches: " + nf.format(goodCatchesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Great Catches: " + nf.format(greatCatchesSession) + "\n\n" + - EnumChatFormatting.GRAY + " Squids: " + nf.format(squidsSession) + "\n" + - EnumChatFormatting.GREEN + " Sea Walkers: " + nf.format(seaWalkersSession) + "\n" + - EnumChatFormatting.DARK_GRAY + " Night Squids: " + nf.format(nightSquidsSession) + "\n" + - EnumChatFormatting.DARK_AQUA + " Sea Guardians: " + nf.format(seaGuardiansSession) + "\n" + - EnumChatFormatting.BLUE + " Sea Witches: " + nf.format(seaWitchesSession) + "\n" + - EnumChatFormatting.GREEN + " Sea Archers: " + nf.format(seaArchersSession) + "\n" + - EnumChatFormatting.GREEN + " Monster of the Deeps: " + nf.format(monsterOfTheDeepsSession) + "\n" + - EnumChatFormatting.YELLOW + " Catfishes: " + nf.format(catfishesSession) + "\n" + - EnumChatFormatting.GOLD + " Carrot Kings: " + nf.format(carrotKingsSession) + "\n" + - EnumChatFormatting.GRAY + " Sea Leeches: " + nf.format(seaLeechesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Guardian Defenders: " + nf.format(guardianDefendersSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Deep Sea Protectors: " + nf.format(deepSeaProtectorsSession) + "\n" + - EnumChatFormatting.GOLD + " Hydras: " + nf.format(hydrasSession) + "\n" + - EnumChatFormatting.GOLD + " Sea Emperors: " + nf.format(seaEmperorsSession) + "\n" + + EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " Fishing Summary:\n" + + EnumChatFormatting.AQUA + " Sea Creatures Caught: " + nf.format(seaCreatures) + "\n" + + EnumChatFormatting.GOLD + " Good Catches: " + nf.format(goodCatches) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Great Catches: " + nf.format(greatCatches) + "\n\n" + + EnumChatFormatting.GRAY + " Squids: " + nf.format(squids) + "\n" + + EnumChatFormatting.GREEN + " Sea Walkers: " + nf.format(seaWalkers) + "\n" + + EnumChatFormatting.DARK_GRAY + " Night Squids: " + nf.format(nightSquids) + "\n" + + EnumChatFormatting.DARK_AQUA + " Sea Guardians: " + nf.format(seaGuardians) + "\n" + + EnumChatFormatting.BLUE + " Sea Witches: " + nf.format(seaWitches) + "\n" + + EnumChatFormatting.GREEN + " Sea Archers: " + nf.format(seaArchers) + "\n" + + EnumChatFormatting.GREEN + " Monster of the Deeps: " + nf.format(monsterOfTheDeeps) + "\n" + + EnumChatFormatting.YELLOW + " Catfishes: " + nf.format(catfishes) + "\n" + + EnumChatFormatting.GOLD + " Carrot Kings: " + nf.format(carrotKings) + "\n" + + EnumChatFormatting.GRAY + " Sea Leeches: " + nf.format(seaLeeches) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Guardian Defenders: " + nf.format(guardianDefenders) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Deep Sea Protectors: " + nf.format(deepSeaProtectors) + "\n" + + EnumChatFormatting.GOLD + " Hydras: " + nf.format(hydras) + "\n" + + EnumChatFormatting.GOLD + " Sea Emperors: " + nf.format(seaEmperors) + "\n" + EnumChatFormatting.AQUA + " Time Since Sea Emperor: " + timeBetween + "\n" + EnumChatFormatting.AQUA + " Sea Creatures Since Sea Emperor: " + bossesBetween + "\n" + EnumChatFormatting.DARK_AQUA + EnumChatFormatting.BOLD + " -------------------")); - return; - } - - if (empTime == -1) { - timeBetween = "Never"; - } else { - timeBetween = Utils.getTimeBetween(empTime, timeNow); - } - if (empSCs == -1) { - bossesBetween = "Never"; - } else { - bossesBetween = nf.format(empSCs); - } - - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_AQUA + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.AQUA + EnumChatFormatting.BOLD + " Fishing Summary:\n" + - EnumChatFormatting.AQUA + " Sea Creatures Caught: " + nf.format(seaCreatures) + "\n" + - EnumChatFormatting.GOLD + " Good Catches: " + nf.format(goodCatches) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Great Catches: " + nf.format(greatCatches) + "\n\n" + - EnumChatFormatting.GRAY + " Squids: " + nf.format(squids) + "\n" + - EnumChatFormatting.GREEN + " Sea Walkers: " + nf.format(seaWalkers) + "\n" + - EnumChatFormatting.DARK_GRAY + " Night Squids: " + nf.format(nightSquids) + "\n" + - EnumChatFormatting.DARK_AQUA + " Sea Guardians: " + nf.format(seaGuardians) + "\n" + - EnumChatFormatting.BLUE + " Sea Witches: " + nf.format(seaWitches) + "\n" + - EnumChatFormatting.GREEN + " Sea Archers: " + nf.format(seaArchers) + "\n" + - EnumChatFormatting.GREEN + " Monster of the Deeps: " + nf.format(monsterOfTheDeeps) + "\n" + - EnumChatFormatting.YELLOW + " Catfishes: " + nf.format(catfishes) + "\n" + - EnumChatFormatting.GOLD + " Carrot Kings: " + nf.format(carrotKings) + "\n" + - EnumChatFormatting.GRAY + " Sea Leeches: " + nf.format(seaLeeches) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Guardian Defenders: " + nf.format(guardianDefenders) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Deep Sea Protectors: " + nf.format(deepSeaProtectors) + "\n" + - EnumChatFormatting.GOLD + " Hydras: " + nf.format(hydras) + "\n" + - EnumChatFormatting.GOLD + " Sea Emperors: " + nf.format(seaEmperors) + "\n" + - EnumChatFormatting.AQUA + " Time Since Sea Emperor: " + timeBetween + "\n" + - EnumChatFormatting.AQUA + " Sea Creatures Since Sea Emperor: " + bossesBetween + "\n" + - EnumChatFormatting.DARK_AQUA + EnumChatFormatting.BOLD + " -------------------")); - } else if (arg1[0].equalsIgnoreCase("catacombs")) { - if (arg1.length == 1) { - player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: /loot catacombs ")); - return; - } - if (arg1[1].equalsIgnoreCase("f1") || arg1[1].equalsIgnoreCase("floor1")) { - if (showSession) { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F1 Summary (Current Session):\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.BLUE + " Bonzo's Staffs: " + nf.format(bonzoStaffsSession) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f1CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f1TimeSpentSession) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); - return; - } - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F1 Summary:\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + - EnumChatFormatting.BLUE + " Bonzo's Staffs: " + nf.format(bonzoStaffs) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f1CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f1TimeSpent) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); - } else if (arg1[1].equalsIgnoreCase("f2") || arg1[1].equalsIgnoreCase("floor2")) { - if (showSession) { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F2 Summary (Current Session):\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.BLUE + " Scarf's Studies: " + nf.format(scarfStudiesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Adaptive Blades: " + nf.format(adaptiveSwordsSession) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f2CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f2TimeSpentSession) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); - return; - } - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F2 Summary:\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + - EnumChatFormatting.BLUE + " Scarf's Studies: " + nf.format(scarfStudies) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Adaptive Blades: " + nf.format(adaptiveSwords) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f2CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f2TimeSpent) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); - } else if (arg1[1].equalsIgnoreCase("f3") || arg1[1].equalsIgnoreCase("floor3")) { - if (showSession) { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F3 Summary (Current Session):\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Adaptive Helmets: " + nf.format(adaptiveHelmsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Adaptive Chestplates: " + nf.format(adaptiveChestsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Adaptive Leggings: " + nf.format(adaptiveLegsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Adaptive Boots: " + nf.format(adaptiveBootsSession) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f3CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f3TimeSpentSession) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); - return; - } - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F3 Summary:\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Adaptive Helmets: " + nf.format(adaptiveHelms) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Adaptive Chestplates: " + nf.format(adaptiveChests) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Adaptive Leggings: " + nf.format(adaptiveLegs) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Adaptive Boots: " + nf.format(adaptiveBoots) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f3CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f3TimeSpent) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); - } else if (arg1[1].equalsIgnoreCase("f4") || arg1[1].equalsIgnoreCase("floor4")) { - if (showSession) { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F4 Summary (Current Session):\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Spirit Wings: " + nf.format(spiritWingsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Spirit Bones: " + nf.format(spiritBonesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Spirit Boots: " + nf.format(spiritBootsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Spirit Swords: " + nf.format(spiritSwordsSession) + "\n" + - EnumChatFormatting.GOLD + " Spirit Bows: " + nf.format(spiritBowsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Epic Spirit Pets: " + nf.format(epicSpiritPetsSession) + "\n" + - EnumChatFormatting.GOLD + " Leg Spirit Pets: " + nf.format(legSpiritPetsSession) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f4CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f4TimeSpentSession) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); - return; - } - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F4 Summary:\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Spirit Wings: " + nf.format(spiritWings) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Spirit Bones: " + nf.format(spiritBones) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Spirit Boots: " + nf.format(spiritBoots) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Spirit Swords: " + nf.format(spiritSwords) + "\n" + - EnumChatFormatting.GOLD + " Spirit Bows: " + nf.format(spiritBows) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Epic Spirit Pets: " + nf.format(epicSpiritPets) + "\n" + - EnumChatFormatting.GOLD + " Leg Spirit Pets: " + nf.format(legSpiritPets) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f4CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f4TimeSpent) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); - } else if (arg1[1].equalsIgnoreCase("f5") || arg1[1].equalsIgnoreCase("floor5")) { + + break; + case "mythological": if (showSession) { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F5 Summary (Current Session):\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + - EnumChatFormatting.BLUE + " Warped Stones: " + nf.format(warpedStonesSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Helmets: " + nf.format(shadowAssHelmsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Chests: " + nf.format(shadowAssChestsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Legs: " + nf.format(shadowAssLegsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Boots: " + nf.format(shadowAssBootsSession) + "\n" + - EnumChatFormatting.GOLD + " Last Breaths: " + nf.format(lastBreathsSession) + "\n" + - EnumChatFormatting.GOLD + " Livid Daggers: " + nf.format(lividDaggersSession) + "\n" + - EnumChatFormatting.GOLD + " Shadow Furys: " + nf.format(shadowFurysSession) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f5CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f5TimeSpentSession) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + player.addChatMessage(new ChatComponentText(EnumChatFormatting.GOLD + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.YELLOW + EnumChatFormatting.BOLD + " Mythological Event Summary (Current Session):\n" + + EnumChatFormatting.YELLOW + " Coins: " + Utils.getMoneySpent(mythCoinsSession) + "\n" + + EnumChatFormatting.WHITE + " Griffin Feathers: " + nf.format(griffinFeathersSession) + "\n" + + EnumChatFormatting.GOLD + " Crown of Greeds: " + nf.format(crownOfGreedsSession) + "\n" + + EnumChatFormatting.AQUA + " Washed-up Souvenirs: " + nf.format(washedUpSouvenirsSession) + "\n" + + EnumChatFormatting.RED + " Minos Hunters: " + nf.format(minosHuntersSession) + "\n" + + EnumChatFormatting.GRAY + " Siamese Lynxes: " + nf.format(siameseLynxesSession) + "\n" + + EnumChatFormatting.RED + " Minotaurs: " + nf.format(minotaursSession) + "\n" + + EnumChatFormatting.WHITE + " Gaia Constructs: " + nf.format(gaiaConstructsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Minos Champions: " + nf.format(minosChampionsSession) + "\n" + + EnumChatFormatting.GOLD + " Minos Inquisitors: " + nf.format(minosInquisitorsSession) + "\n" + + EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + "-------------------")); return; } - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F5 Summary:\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + - EnumChatFormatting.BLUE + " Warped Stones: " + nf.format(warpedStones) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Helmets: " + nf.format(shadowAssHelms) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Chests: " + nf.format(shadowAssChests) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Legs: " + nf.format(shadowAssLegs) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Boots: " + nf.format(shadowAssBoots) + "\n" + - EnumChatFormatting.GOLD + " Last Breaths: " + nf.format(lastBreaths) + "\n" + - EnumChatFormatting.GOLD + " Livid Daggers: " + nf.format(lividDaggers) + "\n" + - EnumChatFormatting.GOLD + " Shadow Furys: " + nf.format(shadowFurys) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f5CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f5TimeSpent) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); - } else if (arg1[1].equalsIgnoreCase("f6") || arg1[1].equalsIgnoreCase("floor6")) { - if (showSession) { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F6 Summary (Current Session):\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.BLUE + " Ancient Roses: " + nf.format(ancientRosesSession) + "\n" + - EnumChatFormatting.GOLD + " Precursor Eyes: " + nf.format(precursorEyesSession) + "\n" + - EnumChatFormatting.GOLD + " Giant's Swords: " + nf.format(giantsSwordsSession) + "\n" + - EnumChatFormatting.GOLD + " Necro Lord Helmets: " + nf.format(necroLordHelmsSession) + "\n" + - EnumChatFormatting.GOLD + " Necro Lord Chestplates: " + nf.format(necroLordChestsSession) + "\n" + - EnumChatFormatting.GOLD + " Necro Lord Leggings: " + nf.format(necroLordLegsSession) + "\n" + - EnumChatFormatting.GOLD + " Necro Lord Boots: " + nf.format(necroLordBootsSession) + "\n" + - EnumChatFormatting.GOLD + " Necro Swords: " + nf.format(necroSwordsSession) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f6CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f6TimeSpentSession) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + player.addChatMessage(new ChatComponentText(EnumChatFormatting.GOLD + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.YELLOW + EnumChatFormatting.BOLD + " Mythological Event Summary:\n" + + EnumChatFormatting.YELLOW + " Coins: " + Utils.getMoneySpent(mythCoins) + "\n" + + EnumChatFormatting.WHITE + " Griffin Feathers: " + nf.format(griffinFeathers) + "\n" + + EnumChatFormatting.GOLD + " Crown of Greeds: " + nf.format(crownOfGreeds) + "\n" + + EnumChatFormatting.AQUA + " Washed-up Souvenirs: " + nf.format(washedUpSouvenirs) + "\n" + + EnumChatFormatting.RED + " Minos Hunters: " + nf.format(minosHunters) + "\n" + + EnumChatFormatting.GRAY + " Siamese Lynxes: " + nf.format(siameseLynxes) + "\n" + + EnumChatFormatting.RED + " Minotaurs: " + nf.format(minotaurs) + "\n" + + EnumChatFormatting.WHITE + " Gaia Constructs: " + nf.format(gaiaConstructs) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Minos Champions: " + nf.format(minosChampions) + "\n" + + EnumChatFormatting.GOLD + " Minos Inquisitors: " + nf.format(minosInquisitors) + "\n" + + EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + "-------------------")); + break; + case "catacombs": + if (arg1.length == 1) { + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: /loot catacombs ")); return; } - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F6 Summary:\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + - EnumChatFormatting.BLUE + " Ancient Roses: " + nf.format(ancientRoses) + "\n" + - EnumChatFormatting.GOLD + " Precursor Eyes: " + nf.format(precursorEyes) + "\n" + - EnumChatFormatting.GOLD + " Giant's Swords: " + nf.format(giantsSwords) + "\n" + - EnumChatFormatting.GOLD + " Necro Lord Helmets: " + nf.format(necroLordHelms) + "\n" + - EnumChatFormatting.GOLD + " Necro Lord Chestplates: " + nf.format(necroLordChests) + "\n" + - EnumChatFormatting.GOLD + " Necro Lord Leggings: " + nf.format(necroLordLegs) + "\n" + - EnumChatFormatting.GOLD + " Necro Lord Boots: " + nf.format(necroLordBoots) + "\n" + - EnumChatFormatting.GOLD + " Necro Swords: " + nf.format(necroSwords) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f6CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f6TimeSpent) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); - } else if (arg1[1].equalsIgnoreCase("f7") || arg1[1].equalsIgnoreCase("floor7")) { - if (showSession) { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F7 Summary (Current Session):\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Wither Bloods: " + nf.format(witherBloodsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Wither Cloaks: " + nf.format(witherCloaksSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Implosions: " + nf.format(implosionsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Wither Shields: " + nf.format(witherShieldsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Shadow Warps: " + nf.format(shadowWarpsSession) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Necron's Handles: " + nf.format(necronsHandlesSession) + "\n" + - EnumChatFormatting.GOLD + " Auto Recombobulator: " + nf.format(autoRecombsSession) + "\n" + - EnumChatFormatting.GOLD + " Wither Helmets: " + nf.format(witherHelmsSession) + "\n" + - EnumChatFormatting.GOLD + " Wither Chesplates: " + nf.format(witherChestsSession) + "\n" + - EnumChatFormatting.GOLD + " Wither Leggings: " + nf.format(witherLegsSession) + "\n" + - EnumChatFormatting.GOLD + " Wither Boots: " + nf.format(witherBootsSession) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f7CoinsSpentSession) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f7TimeSpentSession) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); - return; + switch (arg1[1].toLowerCase()) { + case "f1": + case "floor1": + if (showSession) { + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F1 Summary (Current Session):\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.BLUE + " Bonzo's Staffs: " + nf.format(bonzoStaffsSession) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f1CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f1TimeSpentSession) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + return; + } + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F1 Summary:\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + + EnumChatFormatting.BLUE + " Bonzo's Staffs: " + nf.format(bonzoStaffs) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f1CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f1TimeSpent) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + break; + case "f2": + case "floor2": + if (showSession) { + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F2 Summary (Current Session):\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.BLUE + " Scarf's Studies: " + nf.format(scarfStudiesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Adaptive Blades: " + nf.format(adaptiveSwordsSession) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f2CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f2TimeSpentSession) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + return; + } + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F2 Summary:\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + + EnumChatFormatting.BLUE + " Scarf's Studies: " + nf.format(scarfStudies) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Adaptive Blades: " + nf.format(adaptiveSwords) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f2CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f2TimeSpent) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + break; + case "f3": + case "floor3": + if (showSession) { + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F3 Summary (Current Session):\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Adaptive Helmets: " + nf.format(adaptiveHelmsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Adaptive Chestplates: " + nf.format(adaptiveChestsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Adaptive Leggings: " + nf.format(adaptiveLegsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Adaptive Boots: " + nf.format(adaptiveBootsSession) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f3CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f3TimeSpentSession) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + return; + } + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F3 Summary:\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Adaptive Helmets: " + nf.format(adaptiveHelms) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Adaptive Chestplates: " + nf.format(adaptiveChests) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Adaptive Leggings: " + nf.format(adaptiveLegs) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Adaptive Boots: " + nf.format(adaptiveBoots) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f3CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f3TimeSpent) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + break; + case "f4": + case "floor4": + if (showSession) { + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F4 Summary (Current Session):\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Spirit Wings: " + nf.format(spiritWingsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Spirit Bones: " + nf.format(spiritBonesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Spirit Boots: " + nf.format(spiritBootsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Spirit Swords: " + nf.format(spiritSwordsSession) + "\n" + + EnumChatFormatting.GOLD + " Spirit Bows: " + nf.format(spiritBowsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Epic Spirit Pets: " + nf.format(epicSpiritPetsSession) + "\n" + + EnumChatFormatting.GOLD + " Leg Spirit Pets: " + nf.format(legSpiritPetsSession) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f4CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f4TimeSpentSession) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + return; + } + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F4 Summary:\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Spirit Wings: " + nf.format(spiritWings) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Spirit Bones: " + nf.format(spiritBones) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Spirit Boots: " + nf.format(spiritBoots) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Spirit Swords: " + nf.format(spiritSwords) + "\n" + + EnumChatFormatting.GOLD + " Spirit Bows: " + nf.format(spiritBows) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Epic Spirit Pets: " + nf.format(epicSpiritPets) + "\n" + + EnumChatFormatting.GOLD + " Leg Spirit Pets: " + nf.format(legSpiritPets) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f4CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f4TimeSpent) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + break; + case "f5": + case "floor5": + if (showSession) { + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F5 Summary (Current Session):\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + + EnumChatFormatting.BLUE + " Warped Stones: " + nf.format(warpedStonesSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Helmets: " + nf.format(shadowAssHelmsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Chests: " + nf.format(shadowAssChestsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Legs: " + nf.format(shadowAssLegsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Boots: " + nf.format(shadowAssBootsSession) + "\n" + + EnumChatFormatting.GOLD + " Last Breaths: " + nf.format(lastBreathsSession) + "\n" + + EnumChatFormatting.GOLD + " Livid Daggers: " + nf.format(lividDaggersSession) + "\n" + + EnumChatFormatting.GOLD + " Shadow Furys: " + nf.format(shadowFurysSession) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f5CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f5TimeSpentSession) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + return; + } + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F5 Summary:\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + + EnumChatFormatting.BLUE + " Warped Stones: " + nf.format(warpedStones) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Helmets: " + nf.format(shadowAssHelms) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Chests: " + nf.format(shadowAssChests) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Legs: " + nf.format(shadowAssLegs) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Shadow Assassin Boots: " + nf.format(shadowAssBoots) + "\n" + + EnumChatFormatting.GOLD + " Last Breaths: " + nf.format(lastBreaths) + "\n" + + EnumChatFormatting.GOLD + " Livid Daggers: " + nf.format(lividDaggers) + "\n" + + EnumChatFormatting.GOLD + " Shadow Furys: " + nf.format(shadowFurys) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f5CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f5TimeSpent) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + break; + case "f6": + case "floor6": + if (showSession) { + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F6 Summary (Current Session):\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.BLUE + " Ancient Roses: " + nf.format(ancientRosesSession) + "\n" + + EnumChatFormatting.GOLD + " Precursor Eyes: " + nf.format(precursorEyesSession) + "\n" + + EnumChatFormatting.GOLD + " Giant's Swords: " + nf.format(giantsSwordsSession) + "\n" + + EnumChatFormatting.GOLD + " Necro Lord Helmets: " + nf.format(necroLordHelmsSession) + "\n" + + EnumChatFormatting.GOLD + " Necro Lord Chestplates: " + nf.format(necroLordChestsSession) + "\n" + + EnumChatFormatting.GOLD + " Necro Lord Leggings: " + nf.format(necroLordLegsSession) + "\n" + + EnumChatFormatting.GOLD + " Necro Lord Boots: " + nf.format(necroLordBootsSession) + "\n" + + EnumChatFormatting.GOLD + " Necro Swords: " + nf.format(necroSwordsSession) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f6CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f6TimeSpentSession) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + return; + } + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F6 Summary:\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + + EnumChatFormatting.BLUE + " Ancient Roses: " + nf.format(ancientRoses) + "\n" + + EnumChatFormatting.GOLD + " Precursor Eyes: " + nf.format(precursorEyes) + "\n" + + EnumChatFormatting.GOLD + " Giant's Swords: " + nf.format(giantsSwords) + "\n" + + EnumChatFormatting.GOLD + " Necro Lord Helmets: " + nf.format(necroLordHelms) + "\n" + + EnumChatFormatting.GOLD + " Necro Lord Chestplates: " + nf.format(necroLordChests) + "\n" + + EnumChatFormatting.GOLD + " Necro Lord Leggings: " + nf.format(necroLordLegs) + "\n" + + EnumChatFormatting.GOLD + " Necro Lord Boots: " + nf.format(necroLordBoots) + "\n" + + EnumChatFormatting.GOLD + " Necro Swords: " + nf.format(necroSwords) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f6CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f6TimeSpent) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + break; + case "f7": + case "floor7": + if (showSession) { + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F7 Summary (Current Session):\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulatorsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Wither Bloods: " + nf.format(witherBloodsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Wither Cloaks: " + nf.format(witherCloaksSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Implosions: " + nf.format(implosionsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Wither Shields: " + nf.format(witherShieldsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Shadow Warps: " + nf.format(shadowWarpsSession) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Necron's Handles: " + nf.format(necronsHandlesSession) + "\n" + + EnumChatFormatting.GOLD + " Auto Recombobulator: " + nf.format(autoRecombsSession) + "\n" + + EnumChatFormatting.GOLD + " Wither Helmets: " + nf.format(witherHelmsSession) + "\n" + + EnumChatFormatting.GOLD + " Wither Chesplates: " + nf.format(witherChestsSession) + "\n" + + EnumChatFormatting.GOLD + " Wither Leggings: " + nf.format(witherLegsSession) + "\n" + + EnumChatFormatting.GOLD + " Wither Boots: " + nf.format(witherBootsSession) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f7CoinsSpentSession) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f7TimeSpentSession) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + return; + } + player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F7 Summary:\n" + + EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Wither Bloods: " + nf.format(witherBloods) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Wither Cloaks: " + nf.format(witherCloaks) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Implosions: " + nf.format(implosions) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Wither Shields: " + nf.format(witherShields) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Shadow Warps: " + nf.format(shadowWarps) + "\n" + + EnumChatFormatting.DARK_PURPLE + " Necron's Handles: " + nf.format(necronsHandles) + "\n" + + EnumChatFormatting.GOLD + " Auto Recombobulator: " + nf.format(autoRecombs) + "\n" + + EnumChatFormatting.GOLD + " Wither Helmets: " + nf.format(witherHelms) + "\n" + + EnumChatFormatting.GOLD + " Wither Chesplates: " + nf.format(witherChests) + "\n" + + EnumChatFormatting.GOLD + " Wither Leggings: " + nf.format(witherLegs) + "\n" + + EnumChatFormatting.GOLD + " Wither Boots: " + nf.format(witherBoots) + "\n" + + EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f7CoinsSpent) + "\n" + + EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f7TimeSpent) + "\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); + break; + default: + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: /loot catacombs ")); } - player.addChatMessage(new ChatComponentText(EnumChatFormatting.DARK_RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.RED + EnumChatFormatting.BOLD + " Catacombs F7 Summary:\n" + - EnumChatFormatting.GOLD + " Recombobulator 3000s: " + nf.format(recombobulators) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Fuming Potato Books: " + nf.format(fumingPotatoBooks) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Wither Bloods: " + nf.format(witherBloods) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Wither Cloaks: " + nf.format(witherCloaks) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Implosions: " + nf.format(implosions) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Wither Shields: " + nf.format(witherShields) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Shadow Warps: " + nf.format(shadowWarps) + "\n" + - EnumChatFormatting.DARK_PURPLE + " Necron's Handles: " + nf.format(necronsHandles) + "\n" + - EnumChatFormatting.GOLD + " Auto Recombobulator: " + nf.format(autoRecombs) + "\n" + - EnumChatFormatting.GOLD + " Wither Helmets: " + nf.format(witherHelms) + "\n" + - EnumChatFormatting.GOLD + " Wither Chesplates: " + nf.format(witherChests) + "\n" + - EnumChatFormatting.GOLD + " Wither Leggings: " + nf.format(witherLegs) + "\n" + - EnumChatFormatting.GOLD + " Wither Boots: " + nf.format(witherBoots) + "\n" + - EnumChatFormatting.AQUA + " Coins Spent: " + Utils.getMoneySpent(f7CoinsSpent) + "\n" + - EnumChatFormatting.AQUA + " Time Spent: " + Utils.getTimeBetween(0, f7TimeSpent) + "\n" + - EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " -------------------")); - } else { - player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: /loot catacombs ")); - } - } else { - player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); + break; + default: + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); } - } } diff --git a/src/main/java/me/Danker/commands/MoveCommand.java b/src/main/java/me/Danker/commands/MoveCommand.java index 93e04a3..76babad 100644 --- a/src/main/java/me/Danker/commands/MoveCommand.java +++ b/src/main/java/me/Danker/commands/MoveCommand.java @@ -53,50 +53,58 @@ public class MoveCommand extends CommandBase { return; } - if (arg1[0].equalsIgnoreCase("coords")) { - coordsXY[0] = Integer.parseInt(arg1[1]); - coordsXY[1] = Integer.parseInt(arg1[2]); - ConfigHandler.writeIntConfig("locations", "coordsX", coordsXY[0]); - ConfigHandler.writeIntConfig("locations", "coordsY", coordsXY[1]); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Coords have been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); - } else if (arg1[0].equalsIgnoreCase("display")) { - displayXY[0] = Integer.parseInt(arg1[1]); - displayXY[1] = Integer.parseInt(arg1[2]); - ConfigHandler.writeIntConfig("locations", "displayX", displayXY[0]); - ConfigHandler.writeIntConfig("locations", "displayY", displayXY[1]); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Tracker display has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); - } else if (arg1[0].equalsIgnoreCase("dungeontimer")) { - dungeonTimerXY[0] = Integer.parseInt(arg1[1]); - dungeonTimerXY[1] = Integer.parseInt(arg1[2]); - ConfigHandler.writeIntConfig("locations", "dungeonTimerX", dungeonTimerXY[0]); - ConfigHandler.writeIntConfig("locations", "dungeonTimerY", dungeonTimerXY[1]); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Dungeon timer has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); - } else if (arg1[0].equalsIgnoreCase("skill50")) { - skill50XY[0] = Integer.parseInt(arg1[1]); - skill50XY[1] = Integer.parseInt(arg1[2]); - ConfigHandler.writeIntConfig("locations", "skill50X", skill50XY[0]); - ConfigHandler.writeIntConfig("locations", "skill50Y", skill50XY[1]); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill 50 display has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); - } else if (arg1[0].equalsIgnoreCase("lividhp")) { - lividHpXY[0] = Integer.parseInt(arg1[1]); - lividHpXY[1] = Integer.parseInt(arg1[2]); - ConfigHandler.writeIntConfig("locations", "lividHpX", lividHpXY[0]); - ConfigHandler.writeIntConfig("locations", "lividHpY", lividHpXY[1]); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Livid HP has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); - } else if (arg1[0].equalsIgnoreCase("caketimer")) { - cakeTimerXY[0] = Integer.parseInt(arg1[1]); - cakeTimerXY[1] = Integer.parseInt(arg1[2]); - ConfigHandler.writeIntConfig("locations", "cakeTimerX", cakeTimerXY[0]); - ConfigHandler.writeIntConfig("locations", "cakeTimerY", cakeTimerXY[1]); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Cake timer has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); - } else if (arg1[0].equalsIgnoreCase("skilltracker")) { - skillTrackerXY[0] = Integer.parseInt(arg1[1]); - skillTrackerXY[1] = Integer.parseInt(arg1[2]); - ConfigHandler.writeIntConfig("locations", "skillTrackerX", skillTrackerXY[0]); - ConfigHandler.writeIntConfig("locations", "skillTrackerY", skillTrackerXY[1]); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill tracker has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); - } else { - player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); + switch (arg1[0].toLowerCase()) { + case "coords": + coordsXY[0] = Integer.parseInt(arg1[1]); + coordsXY[1] = Integer.parseInt(arg1[2]); + ConfigHandler.writeIntConfig("locations", "coordsX", coordsXY[0]); + ConfigHandler.writeIntConfig("locations", "coordsY", coordsXY[1]); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Coords have been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); + break; + case "display": + displayXY[0] = Integer.parseInt(arg1[1]); + displayXY[1] = Integer.parseInt(arg1[2]); + ConfigHandler.writeIntConfig("locations", "displayX", displayXY[0]); + ConfigHandler.writeIntConfig("locations", "displayY", displayXY[1]); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Tracker display has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); + break; + case "dungeontimer": + dungeonTimerXY[0] = Integer.parseInt(arg1[1]); + dungeonTimerXY[1] = Integer.parseInt(arg1[2]); + ConfigHandler.writeIntConfig("locations", "dungeonTimerX", dungeonTimerXY[0]); + ConfigHandler.writeIntConfig("locations", "dungeonTimerY", dungeonTimerXY[1]); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Dungeon timer has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); + break; + case "skill50": + skill50XY[0] = Integer.parseInt(arg1[1]); + skill50XY[1] = Integer.parseInt(arg1[2]); + ConfigHandler.writeIntConfig("locations", "skill50X", skill50XY[0]); + ConfigHandler.writeIntConfig("locations", "skill50Y", skill50XY[1]); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill 50 display has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); + break; + case "lividhp": + lividHpXY[0] = Integer.parseInt(arg1[1]); + lividHpXY[1] = Integer.parseInt(arg1[2]); + ConfigHandler.writeIntConfig("locations", "lividHpX", lividHpXY[0]); + ConfigHandler.writeIntConfig("locations", "lividHpY", lividHpXY[1]); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Livid HP has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); + break; + case "caketimer": + cakeTimerXY[0] = Integer.parseInt(arg1[1]); + cakeTimerXY[1] = Integer.parseInt(arg1[2]); + ConfigHandler.writeIntConfig("locations", "cakeTimerX", cakeTimerXY[0]); + ConfigHandler.writeIntConfig("locations", "cakeTimerY", cakeTimerXY[1]); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Cake timer has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); + break; + case "skilltracker": + skillTrackerXY[0] = Integer.parseInt(arg1[1]); + skillTrackerXY[1] = Integer.parseInt(arg1[2]); + ConfigHandler.writeIntConfig("locations", "skillTrackerX", skillTrackerXY[0]); + ConfigHandler.writeIntConfig("locations", "skillTrackerY", skillTrackerXY[1]); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill tracker has been moved to " + TheMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2])); + break; + default: + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); } } diff --git a/src/main/java/me/Danker/commands/ResetLootCommand.java b/src/main/java/me/Danker/commands/ResetLootCommand.java index 6e92c20..939ed6e 100644 --- a/src/main/java/me/Danker/commands/ResetLootCommand.java +++ b/src/main/java/me/Danker/commands/ResetLootCommand.java @@ -39,7 +39,7 @@ public class ResetLootCommand extends CommandBase { if (confirmReset) { return getListOfStringsMatchingLastWord(args, "confirm", "cancel"); } else { - return getListOfStringsMatchingLastWord(args, "zombie", "spider", "wolf", "fishing", "catacombs"); + return getListOfStringsMatchingLastWord(args, "zombie", "spider", "wolf", "fishing", "mythological", "catacombs"); } } @@ -48,44 +48,66 @@ public class ResetLootCommand extends CommandBase { final EntityPlayer player = (EntityPlayer) arg0; if (arg1.length == 0) { - player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: /resetloot ")); + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: /resetloot ")); return; } if (confirmReset) { - if (arg1[0].equalsIgnoreCase("confirm")) { - confirmReset = false; - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Resetting " + resetOption + " tracker...")); - if (resetOption.equalsIgnoreCase("zombie")) { - resetZombie(); - } else if (resetOption.equalsIgnoreCase("spider")) { - resetSpider(); - } else if (resetOption.equalsIgnoreCase("wolf")) { - resetWolf(); - } else if (resetOption.equalsIgnoreCase("fishing")) { - resetFishing(); - } else if (resetOption.equalsIgnoreCase("catacombs")) { - resetCatacombs(); - } - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Reset complete.")); - } else if (arg1[0].equalsIgnoreCase("cancel")) { - confirmReset = false; - player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Reset cancelled.")); - } else { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "Please confirm the reset of the " + resetOption + " tracker by using /resetloot confirm." + - EnumChatFormatting.RED + " Cancel by using /resetloot cancel.")); + switch (arg1[0].toLowerCase()) { + case "confirm": + confirmReset = false; + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Resetting " + resetOption + " tracker...")); + switch (resetOption.toLowerCase()) { + case "zombie": + resetZombie(); + break; + case "spider": + resetSpider(); + break; + case "wolf": + resetWolf(); + break; + case "fishing": + resetFishing(); + break; + case "mythological": + resetMythological(); + case "catacombs": + resetCatacombs(); + default: + System.err.println("Resetting unknown tracker."); + return; + } + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Reset complete.")); + break; + case "cancel": + confirmReset = false; + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Reset cancelled.")); + break; + default: + player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "Please confirm the reset of the " + resetOption + " tracker by using /resetloot confirm." + + EnumChatFormatting.RED + " Cancel by using /resetloot cancel.")); } } else { - if (arg1[0].equalsIgnoreCase("zombie") || arg1[0].equalsIgnoreCase("spider") || arg1[0].equalsIgnoreCase("wolf") || arg1[0].equalsIgnoreCase("fishing") || arg1[0].equalsIgnoreCase("catacombs")) { - resetOption = arg1[0]; - player.addChatMessage(new ChatComponentText(EnumChatFormatting.YELLOW + "Are you sure you want to reset the " + resetOption + " tracker?" + - " Confirm with " + TheMod.MAIN_COLOUR + "/resetloot confirm" + EnumChatFormatting.YELLOW + "." + - " Cancel by using " + TheMod.MAIN_COLOUR + "/resetloot cancel" + EnumChatFormatting.YELLOW + ".")); - confirmReset = true; - } else if (arg1[0].equalsIgnoreCase("confirm") || arg1[0].equalsIgnoreCase("cancel")) { - player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Pick something to reset first.")); - } else { - player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: /resetloot ")); + switch (arg1[0].toLowerCase()) { + case "zombie": + case "spider": + case "wolf": + case "fishing": + case "mythological": + case "catacombs": + resetOption = arg1[0]; + player.addChatMessage(new ChatComponentText(EnumChatFormatting.YELLOW + "Are you sure you want to reset the " + resetOption + " tracker?" + + " Confirm with " + TheMod.MAIN_COLOUR + "/resetloot confirm" + EnumChatFormatting.YELLOW + "." + + " Cancel by using " + TheMod.MAIN_COLOUR + "/resetloot cancel" + EnumChatFormatting.YELLOW + ".")); + confirmReset = true; + break; + case "confirm": + case "cancel": + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Pick something to reset first.")); + break; + default: + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); } } } @@ -182,6 +204,21 @@ public class ResetLootCommand extends CommandBase { ConfigHandler.reloadConfig(); } + static void resetMythological() { + LootCommand.mythCoinsSession = 0; + LootCommand.griffinFeathersSession = 0; + LootCommand.crownOfGreedsSession = 0; + LootCommand.washedUpSouvenirsSession = 0; + LootCommand.minosHuntersSession = 0; + LootCommand.siameseLynxesSession = 0; + LootCommand.minotaursSession = 0; + LootCommand.gaiaConstructsSession = 0; + LootCommand.minosChampionsSession = 0; + LootCommand.minosInquisitorsSession = 0; + ConfigHandler.deleteCategory("mythological"); + ConfigHandler.reloadConfig(); + } + static void resetCatacombs() { LootCommand.recombobulatorsSession = 0; LootCommand.fumingPotatoBooksSession = 0; @@ -229,6 +266,7 @@ public class ResetLootCommand extends CommandBase { LootCommand.implosionsSession = 0; LootCommand.witherShieldsSession = 0; LootCommand.shadowWarpsSession = 0; + LootCommand.necronsHandlesSession = 0; LootCommand.autoRecombsSession = 0; LootCommand.witherHelmsSession = 0; LootCommand.witherChestsSession = 0; diff --git a/src/main/java/me/Danker/commands/ScaleCommand.java b/src/main/java/me/Danker/commands/ScaleCommand.java index cfc7282..65239c5 100644 --- a/src/main/java/me/Danker/commands/ScaleCommand.java +++ b/src/main/java/me/Danker/commands/ScaleCommand.java @@ -59,37 +59,45 @@ public class ScaleCommand extends CommandBase { return; } - if (arg1[0].equalsIgnoreCase("coords")) { - coordsScale = scaleAmount; - ConfigHandler.writeDoubleConfig("scales", "coordsScale", coordsScale); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Coords have been scaled to " + TheMod.SECONDARY_COLOUR + coordsScale + "x")); - } else if (arg1[0].equalsIgnoreCase("display")) { - displayScale = scaleAmount; - ConfigHandler.writeDoubleConfig("scales", "displayScale", displayScale); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Display has been scaled to " + TheMod.SECONDARY_COLOUR + displayScale + "x")); - } else if (arg1[0].equalsIgnoreCase("dungeontimer")) { - dungeonTimerScale = scaleAmount; - ConfigHandler.writeDoubleConfig("scales", "dungeonTimerScale", dungeonTimerScale); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Dungeon timer has been scaled to " + TheMod.SECONDARY_COLOUR + dungeonTimerScale + "x")); - } else if (arg1[0].equalsIgnoreCase("skill50")) { - skill50Scale = scaleAmount; - ConfigHandler.writeDoubleConfig("scales", "skill50Scale", skill50Scale); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill 50 display has been scaled to " + TheMod.SECONDARY_COLOUR + skill50Scale + "x")); - } else if (arg1[0].equalsIgnoreCase("lividhp")) { - lividHpScale = scaleAmount; - ConfigHandler.writeDoubleConfig("scales", "lividHpScale", lividHpScale); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Livid HP has been scaled to " + TheMod.SECONDARY_COLOUR + lividHpScale + "x")); - } else if (arg1[0].equalsIgnoreCase("caketimer")) { - cakeTimerScale = scaleAmount; - ConfigHandler.writeDoubleConfig("scales", "cakeTimerScale", cakeTimerScale); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Cake timer has been scaled to " + TheMod.SECONDARY_COLOUR + cakeTimerScale + "x")); - } else if (arg1[0].equalsIgnoreCase("skilltracker")) { - skillTrackerScale = scaleAmount; - ConfigHandler.writeDoubleConfig("scales", "skillTrackerScale", skillTrackerScale); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill tracker has been scaled to " + TheMod.SECONDARY_COLOUR + skillTrackerScale + "x")); - } else { - player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); - } + switch (arg1[0].toLowerCase()) { + case "coords": + coordsScale = scaleAmount; + ConfigHandler.writeDoubleConfig("scales", "coordsScale", coordsScale); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Coords have been scaled to " + TheMod.SECONDARY_COLOUR + coordsScale + "x")); + break; + case "display": + displayScale = scaleAmount; + ConfigHandler.writeDoubleConfig("scales", "displayScale", displayScale); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Display has been scaled to " + TheMod.SECONDARY_COLOUR + displayScale + "x")); + break; + case "dungeontimer": + dungeonTimerScale = scaleAmount; + ConfigHandler.writeDoubleConfig("scales", "dungeonTimerScale", dungeonTimerScale); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Dungeon timer has been scaled to " + TheMod.SECONDARY_COLOUR + dungeonTimerScale + "x")); + break; + case "skill50": + skill50Scale = scaleAmount; + ConfigHandler.writeDoubleConfig("scales", "skill50Scale", skill50Scale); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill 50 display has been scaled to " + TheMod.SECONDARY_COLOUR + skill50Scale + "x")); + break; + case "lividhp": + lividHpScale = scaleAmount; + ConfigHandler.writeDoubleConfig("scales", "lividHpScale", lividHpScale); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Livid HP has been scaled to " + TheMod.SECONDARY_COLOUR + lividHpScale + "x")); + break; + case "caketimer": + cakeTimerScale = scaleAmount; + ConfigHandler.writeDoubleConfig("scales", "cakeTimerScale", cakeTimerScale); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Cake timer has been scaled to " + TheMod.SECONDARY_COLOUR + cakeTimerScale + "x")); + break; + case "skilltracker": + skillTrackerScale = scaleAmount; + ConfigHandler.writeDoubleConfig("scales", "skillTrackerScale", skillTrackerScale); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill tracker has been scaled to " + TheMod.SECONDARY_COLOUR + skillTrackerScale + "x")); + break; + default: + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); + } } } diff --git a/src/main/java/me/Danker/commands/ToggleCommand.java b/src/main/java/me/Danker/commands/ToggleCommand.java index 93cce26..0aba64b 100644 --- a/src/main/java/me/Danker/commands/ToggleCommand.java +++ b/src/main/java/me/Danker/commands/ToggleCommand.java @@ -81,139 +81,167 @@ public class ToggleCommand extends CommandBase implements ICommand { return; } - if (arg1[0].equalsIgnoreCase("gparty")) { - gpartyToggled = !gpartyToggled; - ConfigHandler.writeBooleanConfig("toggles", "GParty", gpartyToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Guild party notifications has been set to " + TheMod.SECONDARY_COLOUR + gpartyToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("coords")) { - coordsToggled = !coordsToggled; - ConfigHandler.writeBooleanConfig("toggles", "Coords", coordsToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Coord/Angle display has been set to " + TheMod.SECONDARY_COLOUR + coordsToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("golden")) { - goldenToggled = !goldenToggled; - ConfigHandler.writeBooleanConfig("toggles", "Golden", goldenToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Golden T6 enchants has been set to " + TheMod.SECONDARY_COLOUR + goldenToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("slayercount")) { - slayerCountTotal = !slayerCountTotal; - ConfigHandler.writeBooleanConfig("toggles", "SlayerCount", slayerCountTotal); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Counting total 20% slayer drops has been set to " + TheMod.SECONDARY_COLOUR + slayerCountTotal + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("rngesusalerts")) { - rngesusAlerts = !rngesusAlerts; - ConfigHandler.writeBooleanConfig("toggles", "RNGesusAlerts", rngesusAlerts); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Slayer RNGesus alerts has been set to " + TheMod.SECONDARY_COLOUR + rngesusAlerts + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("splitfishing")) { - splitFishing = !splitFishing; - ConfigHandler.writeBooleanConfig("toggles", "SplitFishing", splitFishing); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Split fishing display has been set to " + TheMod.SECONDARY_COLOUR + splitFishing + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("chatmaddox")) { - chatMaddoxToggled = !chatMaddoxToggled; - ConfigHandler.writeBooleanConfig("toggles", "ChatMaddox", chatMaddoxToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Click screen to open Maddox menu has been set to " + TheMod.SECONDARY_COLOUR + chatMaddoxToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("spiritbearalerts")) { - spiritBearAlerts = !spiritBearAlerts; - ConfigHandler.writeBooleanConfig("toggles", "SpiritBearAlerts", spiritBearAlerts); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Spirit Bear alerts have been set to " + TheMod.SECONDARY_COLOUR + spiritBearAlerts + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("aotd")) { - aotdToggled = !aotdToggled; - ConfigHandler.writeBooleanConfig("toggles", "AOTD", aotdToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Block AOTD ability been set to " + TheMod.SECONDARY_COLOUR + aotdToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("lividdagger")) { - lividDaggerToggled = !lividDaggerToggled; - ConfigHandler.writeBooleanConfig("toggles", "LividDagger", lividDaggerToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Block Livid Dagger ability been set to " + TheMod.SECONDARY_COLOUR + lividDaggerToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("sceptremessages")) { - sceptreMessages = !sceptreMessages; - ConfigHandler.writeBooleanConfig("toggles", "SceptreMessages", sceptreMessages); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Spirit Sceptre messages have been set to " + TheMod.SECONDARY_COLOUR + sceptreMessages + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("petcolors") || arg1[0].equalsIgnoreCase("petcolours")) { - petColoursToggled = !petColoursToggled; - ConfigHandler.writeBooleanConfig("toggles", "PetColors", petColoursToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Pet colours have been set to " + TheMod.SECONDARY_COLOUR + petColoursToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("dungeontimer")) { - dungeonTimerToggled = !dungeonTimerToggled; - ConfigHandler.writeBooleanConfig("toggles", "DungeonTimer", dungeonTimerToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Dungeon timer has been set to " + TheMod.SECONDARY_COLOUR + dungeonTimerToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("golemalerts")) { - golemAlertToggled = !golemAlertToggled; - ConfigHandler.writeBooleanConfig("toggles", "GolemAlerts", golemAlertToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Golem spawn alerts has been set to " + TheMod.SECONDARY_COLOUR + golemAlertToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("expertiselore")) { - expertiseLoreToggled = !expertiseLoreToggled; - ConfigHandler.writeBooleanConfig("toggles", "ExpertiseLore", expertiseLoreToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Expertise in lore has been set to " + TheMod.SECONDARY_COLOUR + expertiseLoreToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("skill50display")) { - skill50DisplayToggled = !skill50DisplayToggled; - ConfigHandler.writeBooleanConfig("toggles", "Skill50Display", skill50DisplayToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill 50 display has been set to " + TheMod.SECONDARY_COLOUR + skill50DisplayToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("outlinetext")) { - outlineTextToggled = !outlineTextToggled; - ConfigHandler.writeBooleanConfig("toggles", "OutlineText", outlineTextToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Outline displayed text has been set to " + TheMod.SECONDARY_COLOUR + outlineTextToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("midasstaffmessages")) { - midasStaffMessages = !midasStaffMessages; - ConfigHandler.writeBooleanConfig("toggles", "MidasStaffMessages", midasStaffMessages); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Midas Staff messages have been set to " + TheMod.SECONDARY_COLOUR + midasStaffMessages + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("healmessages")) { - healMessages = !healMessages; - ConfigHandler.writeBooleanConfig("toggles", "HealMessages", healMessages); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Heal messages have been set to " + TheMod.SECONDARY_COLOUR + healMessages + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("caketimer")) { - cakeTimerToggled = !cakeTimerToggled; - ConfigHandler.writeBooleanConfig("toggles", "CakeTimer", cakeTimerToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Cake timer has been set to " + TheMod.SECONDARY_COLOUR + cakeTimerToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("lividsolver")) { - lividSolverToggled = !lividSolverToggled; - ConfigHandler.writeBooleanConfig("toggles", "LividSolver", lividSolverToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Livid solver has been set to " + TheMod.SECONDARY_COLOUR + lividSolverToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("threemanpuzzle")) { - threeManToggled = !threeManToggled; - ConfigHandler.writeBooleanConfig("toggles", "ThreeManPuzzle", threeManToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Three man puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + threeManToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("oruopuzzle")) { - oruoToggled = !oruoToggled; - ConfigHandler.writeBooleanConfig("toggles", "OruoPuzzle", oruoToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Oruo trivia solver has been set to " + TheMod.SECONDARY_COLOUR + oruoToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("blazepuzzle")) { - blazeToggled = !blazeToggled; - ConfigHandler.writeBooleanConfig("toggles", "BlazePuzzle", blazeToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Blaze puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + blazeToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("creeperpuzzle")) { - creeperToggled = !creeperToggled; - ConfigHandler.writeBooleanConfig("creeperpuzzle", "CreeperPuzzle", creeperToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Creeper puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + creeperToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("waterpuzzle")) { - waterToggled = !waterToggled; - ConfigHandler.writeBooleanConfig("waterpuzzle", "WaterPuzzle", waterToggled); - player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Water puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + waterToggled + TheMod.MAIN_COLOUR + ".")); - } else if (arg1[0].equalsIgnoreCase("list")) { - player.addChatMessage(new ChatComponentText(TheMod.TYPE_COLOUR + "Guild party notifications: " + TheMod.VALUE_COLOUR + gpartyToggled + "\n" + - TheMod.TYPE_COLOUR + " Coord/Angle display: " + TheMod.VALUE_COLOUR + coordsToggled + "\n" + - TheMod.TYPE_COLOUR + " Golden T6 enchants: " + TheMod.VALUE_COLOUR + goldenToggled + "\n" + - TheMod.TYPE_COLOUR + " Counting total 20% slayer drops: " + TheMod.VALUE_COLOUR + slayerCountTotal + "\n" + - TheMod.TYPE_COLOUR + " Slayer RNGesus alerts: " + TheMod.VALUE_COLOUR + rngesusAlerts + "\n" + - TheMod.TYPE_COLOUR + " Split fishing display: " + TheMod.VALUE_COLOUR + splitFishing + "\n" + - TheMod.TYPE_COLOUR + " Chat Maddox menu: " + TheMod.VALUE_COLOUR + chatMaddoxToggled + "\n" + - TheMod.TYPE_COLOUR + " Spirit Bear alerts: " + TheMod.VALUE_COLOUR + spiritBearAlerts + "\n" + - TheMod.TYPE_COLOUR + " Block AOTD ability: " + TheMod.VALUE_COLOUR + aotdToggled + "\n" + - TheMod.TYPE_COLOUR + " Block Livid Dagger ability: " + TheMod.VALUE_COLOUR + lividDaggerToggled + "\n" + - TheMod.TYPE_COLOUR + " Spirit Sceptre messages: " + TheMod.VALUE_COLOUR + sceptreMessages + "\n" + - TheMod.TYPE_COLOUR + " Pet colours: " + TheMod.VALUE_COLOUR + petColoursToggled + "\n" + - TheMod.TYPE_COLOUR + " Dungeon timer: " + TheMod.VALUE_COLOUR + dungeonTimerToggled + "\n" + - TheMod.TYPE_COLOUR + " Golem spawn alerts: " + TheMod.VALUE_COLOUR + golemAlertToggled + "\n" + - TheMod.TYPE_COLOUR + " Expertise in lore: " + TheMod.VALUE_COLOUR + expertiseLoreToggled + "\n" + - TheMod.TYPE_COLOUR + " Skill 50 display: " + TheMod.VALUE_COLOUR + skill50DisplayToggled + "\n" + - TheMod.TYPE_COLOUR + " Outline displayed text: " + TheMod.VALUE_COLOUR + outlineTextToggled + "\n" + - TheMod.TYPE_COLOUR + " Midas Staff messages: " + TheMod.VALUE_COLOUR + midasStaffMessages + "\n" + - TheMod.TYPE_COLOUR + " Heal messages: " + TheMod.VALUE_COLOUR + healMessages + "\n" + - TheMod.TYPE_COLOUR + " Cake timer: " + TheMod.VALUE_COLOUR + cakeTimerToggled + "\n" + - TheMod.TYPE_COLOUR + " Livid solver: " + TheMod.VALUE_COLOUR + lividSolverToggled + "\n" + - TheMod.TYPE_COLOUR + " Three man puzzle solver: " + TheMod.VALUE_COLOUR + threeManToggled + "\n" + - TheMod.TYPE_COLOUR + " Oruo trivia solver: " + TheMod.VALUE_COLOUR + oruoToggled + "\n" + - TheMod.TYPE_COLOUR + " Blaze puzzle solver: " + TheMod.VALUE_COLOUR + blazeToggled + "\n" + - TheMod.TYPE_COLOUR + " Creeper puzzle solver: " + TheMod.VALUE_COLOUR + creeperToggled + "\n" + - TheMod.TYPE_COLOUR + " Water puzzle solver: " + TheMod.VALUE_COLOUR + waterToggled)); - } else { - player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); + switch (arg1[0].toLowerCase()) { + case "gparty": + gpartyToggled = !gpartyToggled; + ConfigHandler.writeBooleanConfig("toggles", "GParty", gpartyToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Guild party notifications has been set to " + TheMod.SECONDARY_COLOUR + gpartyToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "coords": + coordsToggled = !coordsToggled; + ConfigHandler.writeBooleanConfig("toggles", "Coords", coordsToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Coord/Angle display has been set to " + TheMod.SECONDARY_COLOUR + coordsToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "golden": + goldenToggled = !goldenToggled; + ConfigHandler.writeBooleanConfig("toggles", "Golden", goldenToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Golden T6 enchants has been set to " + TheMod.SECONDARY_COLOUR + goldenToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "slayercount": + slayerCountTotal = !slayerCountTotal; + ConfigHandler.writeBooleanConfig("toggles", "SlayerCount", slayerCountTotal); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Counting total 20% slayer drops has been set to " + TheMod.SECONDARY_COLOUR + slayerCountTotal + TheMod.MAIN_COLOUR + ".")); + break; + case "rngesusalerts": + rngesusAlerts = !rngesusAlerts; + ConfigHandler.writeBooleanConfig("toggles", "RNGesusAlerts", rngesusAlerts); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Slayer RNGesus alerts has been set to " + TheMod.SECONDARY_COLOUR + rngesusAlerts + TheMod.MAIN_COLOUR + ".")); + break; + case "splitfishing": + splitFishing = !splitFishing; + ConfigHandler.writeBooleanConfig("toggles", "SplitFishing", splitFishing); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Split fishing display has been set to " + TheMod.SECONDARY_COLOUR + splitFishing + TheMod.MAIN_COLOUR + ".")); + break; + case "chatmaddox": + chatMaddoxToggled = !chatMaddoxToggled; + ConfigHandler.writeBooleanConfig("toggles", "ChatMaddox", chatMaddoxToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Click screen to open Maddox menu has been set to " + TheMod.SECONDARY_COLOUR + chatMaddoxToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "spiritbearalerts": + spiritBearAlerts = !spiritBearAlerts; + ConfigHandler.writeBooleanConfig("toggles", "SpiritBearAlerts", spiritBearAlerts); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Spirit Bear alerts have been set to " + TheMod.SECONDARY_COLOUR + spiritBearAlerts + TheMod.MAIN_COLOUR + ".")); + break; + case "aotd": + aotdToggled = !aotdToggled; + ConfigHandler.writeBooleanConfig("toggles", "AOTD", aotdToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Block AOTD ability been set to " + TheMod.SECONDARY_COLOUR + aotdToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "lividdagger": + lividDaggerToggled = !lividDaggerToggled; + ConfigHandler.writeBooleanConfig("toggles", "LividDagger", lividDaggerToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Block Livid Dagger ability been set to " + TheMod.SECONDARY_COLOUR + lividDaggerToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "sceptremessages": + sceptreMessages = !sceptreMessages; + ConfigHandler.writeBooleanConfig("toggles", "SceptreMessages", sceptreMessages); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Spirit Sceptre messages have been set to " + TheMod.SECONDARY_COLOUR + sceptreMessages + TheMod.MAIN_COLOUR + ".")); + break; + case "petcolors": + case "petcolours": + petColoursToggled = !petColoursToggled; + ConfigHandler.writeBooleanConfig("toggles", "PetColors", petColoursToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Pet colours have been set to " + TheMod.SECONDARY_COLOUR + petColoursToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "dungeontimer": + dungeonTimerToggled = !dungeonTimerToggled; + ConfigHandler.writeBooleanConfig("toggles", "DungeonTimer", dungeonTimerToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Dungeon timer has been set to " + TheMod.SECONDARY_COLOUR + dungeonTimerToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "golemalerts": + golemAlertToggled = !golemAlertToggled; + ConfigHandler.writeBooleanConfig("toggles", "GolemAlerts", golemAlertToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Golem spawn alerts has been set to " + TheMod.SECONDARY_COLOUR + golemAlertToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "expertiselore": + expertiseLoreToggled = !expertiseLoreToggled; + ConfigHandler.writeBooleanConfig("toggles", "ExpertiseLore", expertiseLoreToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Expertise in lore has been set to " + TheMod.SECONDARY_COLOUR + expertiseLoreToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "skill50display": + skill50DisplayToggled = !skill50DisplayToggled; + ConfigHandler.writeBooleanConfig("toggles", "Skill50Display", skill50DisplayToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Skill 50 display has been set to " + TheMod.SECONDARY_COLOUR + skill50DisplayToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "outlinetext": + outlineTextToggled = !outlineTextToggled; + ConfigHandler.writeBooleanConfig("toggles", "OutlineText", outlineTextToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Outline displayed text has been set to " + TheMod.SECONDARY_COLOUR + outlineTextToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "midasstaffmessages": + midasStaffMessages = !midasStaffMessages; + ConfigHandler.writeBooleanConfig("toggles", "MidasStaffMessages", midasStaffMessages); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Midas Staff messages have been set to " + TheMod.SECONDARY_COLOUR + midasStaffMessages + TheMod.MAIN_COLOUR + ".")); + break; + case "healmessages": + healMessages = !healMessages; + ConfigHandler.writeBooleanConfig("toggles", "HealMessages", healMessages); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Heal messages have been set to " + TheMod.SECONDARY_COLOUR + healMessages + TheMod.MAIN_COLOUR + ".")); + break; + case "caketimer": + cakeTimerToggled = !cakeTimerToggled; + ConfigHandler.writeBooleanConfig("toggles", "CakeTimer", cakeTimerToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Cake timer has been set to " + TheMod.SECONDARY_COLOUR + cakeTimerToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "lividsolver": + lividSolverToggled = !lividSolverToggled; + ConfigHandler.writeBooleanConfig("toggles", "LividSolver", lividSolverToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Livid solver has been set to " + TheMod.SECONDARY_COLOUR + lividSolverToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "threemanpuzzle": + threeManToggled = !threeManToggled; + ConfigHandler.writeBooleanConfig("toggles", "ThreeManPuzzle", threeManToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Three man puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + threeManToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "oruopuzzle": + oruoToggled = !oruoToggled; + ConfigHandler.writeBooleanConfig("toggles", "OruoPuzzle", oruoToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Oruo trivia solver has been set to " + TheMod.SECONDARY_COLOUR + oruoToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "blazepuzzle": + blazeToggled = !blazeToggled; + ConfigHandler.writeBooleanConfig("toggles", "BlazePuzzle", blazeToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Blaze puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + blazeToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "creeperpuzzle": + creeperToggled = !creeperToggled; + ConfigHandler.writeBooleanConfig("creeperpuzzle", "CreeperPuzzle", creeperToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Creeper puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + creeperToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "waterpuzzle": + waterToggled = !waterToggled; + ConfigHandler.writeBooleanConfig("waterpuzzle", "WaterPuzzle", waterToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Water puzzle solver has been set to " + TheMod.SECONDARY_COLOUR + waterToggled + TheMod.MAIN_COLOUR + ".")); + break; + case "list": + player.addChatMessage(new ChatComponentText(TheMod.TYPE_COLOUR + "Guild party notifications: " + TheMod.VALUE_COLOUR + gpartyToggled + "\n" + + TheMod.TYPE_COLOUR + " Coord/Angle display: " + TheMod.VALUE_COLOUR + coordsToggled + "\n" + + TheMod.TYPE_COLOUR + " Golden T6 enchants: " + TheMod.VALUE_COLOUR + goldenToggled + "\n" + + TheMod.TYPE_COLOUR + " Counting total 20% slayer drops: " + TheMod.VALUE_COLOUR + slayerCountTotal + "\n" + + TheMod.TYPE_COLOUR + " Slayer RNGesus alerts: " + TheMod.VALUE_COLOUR + rngesusAlerts + "\n" + + TheMod.TYPE_COLOUR + " Split fishing display: " + TheMod.VALUE_COLOUR + splitFishing + "\n" + + TheMod.TYPE_COLOUR + " Chat Maddox menu: " + TheMod.VALUE_COLOUR + chatMaddoxToggled + "\n" + + TheMod.TYPE_COLOUR + " Spirit Bear alerts: " + TheMod.VALUE_COLOUR + spiritBearAlerts + "\n" + + TheMod.TYPE_COLOUR + " Block AOTD ability: " + TheMod.VALUE_COLOUR + aotdToggled + "\n" + + TheMod.TYPE_COLOUR + " Block Livid Dagger ability: " + TheMod.VALUE_COLOUR + lividDaggerToggled + "\n" + + TheMod.TYPE_COLOUR + " Spirit Sceptre messages: " + TheMod.VALUE_COLOUR + sceptreMessages + "\n" + + TheMod.TYPE_COLOUR + " Pet colours: " + TheMod.VALUE_COLOUR + petColoursToggled + "\n" + + TheMod.TYPE_COLOUR + " Dungeon timer: " + TheMod.VALUE_COLOUR + dungeonTimerToggled + "\n" + + TheMod.TYPE_COLOUR + " Golem spawn alerts: " + TheMod.VALUE_COLOUR + golemAlertToggled + "\n" + + TheMod.TYPE_COLOUR + " Expertise in lore: " + TheMod.VALUE_COLOUR + expertiseLoreToggled + "\n" + + TheMod.TYPE_COLOUR + " Skill 50 display: " + TheMod.VALUE_COLOUR + skill50DisplayToggled + "\n" + + TheMod.TYPE_COLOUR + " Outline displayed text: " + TheMod.VALUE_COLOUR + outlineTextToggled + "\n" + + TheMod.TYPE_COLOUR + " Midas Staff messages: " + TheMod.VALUE_COLOUR + midasStaffMessages + "\n" + + TheMod.TYPE_COLOUR + " Heal messages: " + TheMod.VALUE_COLOUR + healMessages + "\n" + + TheMod.TYPE_COLOUR + " Cake timer: " + TheMod.VALUE_COLOUR + cakeTimerToggled + "\n" + + TheMod.TYPE_COLOUR + " Livid solver: " + TheMod.VALUE_COLOUR + lividSolverToggled + "\n" + + TheMod.TYPE_COLOUR + " Three man puzzle solver: " + TheMod.VALUE_COLOUR + threeManToggled + "\n" + + TheMod.TYPE_COLOUR + " Oruo trivia solver: " + TheMod.VALUE_COLOUR + oruoToggled + "\n" + + TheMod.TYPE_COLOUR + " Blaze puzzle solver: " + TheMod.VALUE_COLOUR + blazeToggled + "\n" + + TheMod.TYPE_COLOUR + " Creeper puzzle solver: " + TheMod.VALUE_COLOUR + creeperToggled + "\n" + + TheMod.TYPE_COLOUR + " Water puzzle solver: " + TheMod.VALUE_COLOUR + waterToggled)); + default: + player.addChatMessage(new ChatComponentText(TheMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0))); } } } diff --git a/src/main/java/me/Danker/gui/DisplayGui.java b/src/main/java/me/Danker/gui/DisplayGui.java index 21bb05e..0a5f805 100644 --- a/src/main/java/me/Danker/gui/DisplayGui.java +++ b/src/main/java/me/Danker/gui/DisplayGui.java @@ -26,6 +26,7 @@ public class DisplayGui extends GuiScreen { private GuiButton fishingWinter; private GuiButton fishingFestival; private GuiButton fishingSpooky; + private GuiButton mythological; private GuiButton catacombsF1; private GuiButton catacombsF2; private GuiButton catacombsF3; @@ -59,13 +60,14 @@ public class DisplayGui extends GuiScreen { fishingWinter = new GuiButton(0, width / 2 - 110, (int) (height * 0.4), 100, 20, "Fishing Winter"); fishingFestival = new GuiButton(0, width / 2 + 10, (int) (height * 0.4), 100, 20, "Fishing Festival"); fishingSpooky = new GuiButton(0, width / 2 + 130, (int) (height * 0.4), 100, 20, "Fishing Spooky"); - catacombsF1 = new GuiButton(0, width / 2 - 205, (int) (height * 0.55), 50, 20, "F1"); - catacombsF2 = new GuiButton(0, width / 2 - 145, (int) (height * 0.55), 50, 20, "F2"); - catacombsF3 = new GuiButton(0, width / 2 - 85, (int) (height * 0.55), 50, 20, "F3"); - catacombsF4 = new GuiButton(0, width / 2 - 25, (int) (height * 0.55), 50, 20, "F4"); - catacombsF5 = new GuiButton(0, width / 2 + 35, (int) (height * 0.55), 50, 20, "F5"); - catacombsF6 = new GuiButton(0, width / 2 + 95, (int) (height * 0.55), 50, 20, "F6"); - catacombsF7 = new GuiButton(0, width / 2 + 155, (int) (height * 0.55), 50, 20, "F7"); + mythological = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), 200, 20, "Mythological"); + catacombsF1 = new GuiButton(0, width / 2 - 205, (int) (height * 0.65), 50, 20, "F1"); + catacombsF2 = new GuiButton(0, width / 2 - 145, (int) (height * 0.65), 50, 20, "F2"); + catacombsF3 = new GuiButton(0, width / 2 - 85, (int) (height * 0.65), 50, 20, "F3"); + catacombsF4 = new GuiButton(0, width / 2 - 25, (int) (height * 0.65), 50, 20, "F4"); + catacombsF5 = new GuiButton(0, width / 2 + 35, (int) (height * 0.65), 50, 20, "F5"); + catacombsF6 = new GuiButton(0, width / 2 + 95, (int) (height * 0.65), 50, 20, "F6"); + catacombsF7 = new GuiButton(0, width / 2 + 155, (int) (height * 0.65), 50, 20, "F7"); this.buttonList.add(showSession); this.buttonList.add(off); @@ -77,6 +79,7 @@ public class DisplayGui extends GuiScreen { this.buttonList.add(fishingWinter); this.buttonList.add(fishingFestival); this.buttonList.add(fishingSpooky); + this.buttonList.add(mythological); this.buttonList.add(catacombsF1); this.buttonList.add(catacombsF2); this.buttonList.add(catacombsF3); @@ -104,7 +107,7 @@ public class DisplayGui extends GuiScreen { String catacombsTitleText = "Catacombs Dungeon"; int catacombsTitleWidth = mc.fontRendererObj.getStringWidth(catacombsTitleText); - new TextRenderer(mc, catacombsTitleText, width / 2 - catacombsTitleWidth / 2, (int) (height * 0.5), 1D); + new TextRenderer(mc, catacombsTitleText, width / 2 - catacombsTitleWidth / 2, (int) (height * 0.6), 1D); super.drawScreen(mouseX, mouseY, partialTicks); } @@ -137,6 +140,8 @@ public class DisplayGui extends GuiScreen { setDisplay("fishing_festival", false); } else if (button == fishingSpooky) { setDisplay("fishing_spooky", false); + } else if (button == mythological) { + setDisplay("mythological", false); } else if (button == catacombsF1) { setDisplay("catacombs_floor_one", false); } else if (button == catacombsF2) { diff --git a/src/main/java/me/Danker/handlers/ConfigHandler.java b/src/main/java/me/Danker/handlers/ConfigHandler.java index b9bc860..8cfc9bf 100644 --- a/src/main/java/me/Danker/handlers/ConfigHandler.java +++ b/src/main/java/me/Danker/handlers/ConfigHandler.java @@ -284,6 +284,18 @@ public class ConfigHandler { if (!hasKey("fishing", "phantomFisher")) writeIntConfig("fishing", "phantomFisher", 0); if (!hasKey("fishing", "grimReaper")) writeIntConfig("fishing", "grimReaper", 0); + // Mythological + if (!hasKey("mythological", "coins")) writeDoubleConfig("mythological", "coins", 0); + if (!hasKey("mythological", "griffinFeather")) writeIntConfig("mythological", "griffinFeather", 0); + if (!hasKey("mythological", "crownOfGreed")) writeIntConfig("mythological", "crownOfGreed", 0); + if (!hasKey("mythological", "washedUpSouvenir")) writeIntConfig("mythological", "washedUpSouvenir", 0); + if (!hasKey("mythological", "minosHunter")) writeIntConfig("mythological", "minosHunter", 0); + if (!hasKey("mythological", "siameseLynx")) writeIntConfig("mythological", "siameseLynx", 0); + if (!hasKey("mythological", "minotaur")) writeIntConfig("mythological", "minotaur", 0); + if (!hasKey("mythological", "gaiaConstruct")) writeIntConfig("mythological", "gaiaConstruct", 0); + if (!hasKey("mythological", "minosChampion")) writeIntConfig("mythological", "minosChampion", 0); + if (!hasKey("mythological", "minosInquisitor")) writeIntConfig("mythological", "minosInquisitor", 0); + // Dungeons if (!hasKey("catacombs", "recombobulator")) writeIntConfig("catacombs", "recombobulator", 0); if (!hasKey("catacombs", "fumingBooks")) writeIntConfig("catacombs", "fumingBooks", 0); @@ -508,6 +520,18 @@ public class ConfigHandler { LootCommand.phantomFishers = getInt("fishing", "phantomFisher"); LootCommand.grimReapers = getInt("fishing", "grimReaper"); + // Mythological + LootCommand.mythCoins = getDouble("mythological", "coins"); + LootCommand.griffinFeathers = getInt("mythological", "griffinFeather"); + LootCommand.crownOfGreeds = getInt("mythological", "crownOfGreed"); + LootCommand.washedUpSouvenirs = getInt("mythological", "washedUpSouvenir"); + LootCommand.minosHunters = getInt("mythological", "minosHunter"); + LootCommand.siameseLynxes = getInt("mythological", "siameseLynx"); + LootCommand.minotaurs = getInt("mythological", "minotaur"); + LootCommand.gaiaConstructs = getInt("mythological", "gaiaConstruct"); + LootCommand.minosChampions = getInt("mythological", "minosChampion"); + LootCommand.minosInquisitors = getInt("mythological", "minosInquisitor"); + // Dungeons LootCommand.recombobulators = getInt("catacombs", "recombobulator"); LootCommand.fumingPotatoBooks = getInt("catacombs", "fumingBooks"); -- cgit From 8b78e680240a20d1b44c03f6bbcbb42b36a02827 Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Wed, 25 Nov 2020 22:55:50 -0500 Subject: Add low health alerts --- README.md | 3 ++- src/main/java/me/Danker/TheMod.java | 15 ++++++++++++++- src/main/java/me/Danker/commands/DHelpCommand.java | 2 +- src/main/java/me/Danker/commands/ToggleCommand.java | 13 ++++++++++--- src/main/java/me/Danker/gui/DankerGui.java | 7 +++++++ src/main/java/me/Danker/handlers/ConfigHandler.java | 2 ++ 6 files changed, 36 insertions(+), 6 deletions(-) (limited to 'src/main/java/me/Danker/gui') diff --git a/README.md b/README.md index ca46bc2..e02bbb8 100644 --- a/README.md +++ b/README.md @@ -33,13 +33,14 @@ Discord Server: https://discord.gg/QsEkNQS - Show total skill xp instead of progress to next level - Show time until century cakes run out - Mythological event (Diana) tracker +- Low health alert in dungeons - API commands - Update checker ## Commands - /dhelp - Returns this message in-game. - /dsm - Opens the GUI for Danker's Skyblock Mod. -- /toggle - Toggles features. /toggle list returns values of every toggle. +- /toggle - Toggles features. /toggle list returns values of every toggle. - /setkey - Sets API key. - /getkey - Returns key set with /setkey and copies it to your clipboard. - /loot [winter/spooky/f(1-7)/session] - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead. diff --git a/src/main/java/me/Danker/TheMod.java b/src/main/java/me/Danker/TheMod.java index 7c821fd..55ec20e 100644 --- a/src/main/java/me/Danker/TheMod.java +++ b/src/main/java/me/Danker/TheMod.java @@ -2519,7 +2519,7 @@ public class TheMod // Checks 5 times per second if (tickAmount % 4 == 0) { - if (ToggleCommand.blazeToggled && Utils.inDungeons && world != null) { + if (ToggleCommand.blazeToggled && Utils.inDungeons && world != null) { List entities = world.getLoadedEntityList(); int highestHealth = 0; highestBlaze = null; @@ -2563,6 +2563,19 @@ public class TheMod } } + // Checks 10 times per second + if (tickAmount % 2 == 0) { + if (ToggleCommand.lowHealthNotifyToggled && Utils.inDungeons && world != null) { + List scoreboard = ScoreboardHandler.getSidebarLines(); + for (String score : scoreboard) { + if (score.endsWith("❤") && score.matches(".*§c\\d.*")) { + Utils.createTitle(EnumChatFormatting.RED + "LOW HEALTH!", 1); + break; + } + } + } + } + if (titleTimer >= 0) { if (titleTimer == 0) { showTitle = false; diff --git a/src/main/java/me/Danker/commands/DHelpCommand.java b/src/main/java/me/Danker/commands/DHelpCommand.java index e900c57..9d9bb51 100644 --- a/src/main/java/me/Danker/commands/DHelpCommand.java +++ b/src/main/java/me/Danker/commands/DHelpCommand.java @@ -34,7 +34,7 @@ public class DHelpCommand extends CommandBase { EnumChatFormatting.GOLD + " Commands, " + EnumChatFormatting.GREEN + " Keybinds.\n" + EnumChatFormatting.GOLD + " /dhelp" + EnumChatFormatting.AQUA + " - Returns this message.\n" + EnumChatFormatting.GOLD + " /dsm" + EnumChatFormatting.AQUA + " - Opens the GUI for Danker's Skyblock Mod.\n" + - EnumChatFormatting.GOLD + " /toggle " + EnumChatFormatting.AQUA + " - Toggles features. /toggle list returns values of every toggle.\n" + + EnumChatFormatting.GOLD + " /toggle " + EnumChatFormatting.AQUA + " - Toggles features. /toggle list returns values of every toggle.\n" + EnumChatFormatting.GOLD + " /setkey " + EnumChatFormatting.AQUA + " - Sets API key.\n" + EnumChatFormatting.GOLD + " /getkey" + EnumChatFormatting.AQUA + " - Returns key set with /setkey and copies it to your clipboard.\n" + EnumChatFormatting.GOLD + " /loot [winter/festival/spooky/f(1-7)/session]" + EnumChatFormatting.AQUA + " - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead.\n" + diff --git a/src/main/java/me/Danker/commands/ToggleCommand.java b/src/main/java/me/Danker/commands/ToggleCommand.java index 0aba64b..6e85d58 100644 --- a/src/main/java/me/Danker/commands/ToggleCommand.java +++ b/src/main/java/me/Danker/commands/ToggleCommand.java @@ -33,6 +33,7 @@ public class ToggleCommand extends CommandBase implements ICommand { public static boolean midasStaffMessages; public static boolean healMessages; public static boolean cakeTimerToggled; + public static boolean lowHealthNotifyToggled; public static boolean lividSolverToggled; // Puzzle Solvers public static boolean threeManToggled; @@ -50,7 +51,7 @@ public class ToggleCommand extends CommandBase implements ICommand { public String getCommandUsage(ICommandSender arg0) { return "/" + getCommandName() + " "; } @@ -66,8 +67,8 @@ public class ToggleCommand extends CommandBase implements ICommand { "splitfishing", "chatmaddox", "spiritbearalerts", "aotd", "lividdagger", "sceptremessages", "petcolors", "dungeontimer", "golemalerts", "expertiselore", "skill50display", "outlinetext", "midasstaffmessages", - "healmessages", "caketimer", "lividsolver", "threemanpuzzle", "oruopuzzle", - "blazepuzzle", "creeperpuzzle", "waterpuzzle", "list"); + "healmessages", "caketimer", "lowhealthnotify", "lividsolver", "threemanpuzzle", + "oruopuzzle", "blazepuzzle", "creeperpuzzle", "waterpuzzle", "list"); } return null; } @@ -183,6 +184,11 @@ public class ToggleCommand extends CommandBase implements ICommand { ConfigHandler.writeBooleanConfig("toggles", "CakeTimer", cakeTimerToggled); player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Cake timer has been set to " + TheMod.SECONDARY_COLOUR + cakeTimerToggled + TheMod.MAIN_COLOUR + ".")); break; + case "lowhealthnotify": + lowHealthNotifyToggled = !lowHealthNotifyToggled; + ConfigHandler.writeBooleanConfig("toggles", "LowHealthNotify", lowHealthNotifyToggled); + player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Low health notify has been set to " + TheMod.SECONDARY_COLOUR + lowHealthNotifyToggled + TheMod.MAIN_COLOUR + ".")); + break; case "lividsolver": lividSolverToggled = !lividSolverToggled; ConfigHandler.writeBooleanConfig("toggles", "LividSolver", lividSolverToggled); @@ -234,6 +240,7 @@ public class ToggleCommand extends CommandBase implements ICommand { TheMod.TYPE_COLOUR + " Midas Staff messages: " + TheMod.VALUE_COLOUR + midasStaffMessages + "\n" + TheMod.TYPE_COLOUR + " Heal messages: " + TheMod.VALUE_COLOUR + healMessages + "\n" + TheMod.TYPE_COLOUR + " Cake timer: " + TheMod.VALUE_COLOUR + cakeTimerToggled + "\n" + + TheMod.TYPE_COLOUR + " Low health notify: " + TheMod.VALUE_COLOUR + lowHealthNotifyToggled + "\n" + TheMod.TYPE_COLOUR + " Livid solver: " + TheMod.VALUE_COLOUR + lividSolverToggled + "\n" + TheMod.TYPE_COLOUR + " Three man puzzle solver: " + TheMod.VALUE_COLOUR + threeManToggled + "\n" + TheMod.TYPE_COLOUR + " Oruo trivia solver: " + TheMod.VALUE_COLOUR + oruoToggled + "\n" + diff --git a/src/main/java/me/Danker/gui/DankerGui.java b/src/main/java/me/Danker/gui/DankerGui.java index 205dc8b..f086e25 100644 --- a/src/main/java/me/Danker/gui/DankerGui.java +++ b/src/main/java/me/Danker/gui/DankerGui.java @@ -49,6 +49,7 @@ public class DankerGui extends GuiScreen { private GuiButton midasStaffMessages; private GuiButton healMessages; private GuiButton cakeTimer; + private GuiButton lowHealthNotify; private GuiButton lividSolver; public DankerGui(int page) { @@ -104,6 +105,7 @@ public class DankerGui extends GuiScreen { lividSolver = new GuiButton(0, width / 2 - 100, (int) (height * 0.2), "Find Correct Livid: " + Utils.getColouredBoolean(ToggleCommand.lividSolverToggled)); golemAlerts = new GuiButton(0, width / 2 - 100, (int) (height * 0.3), "Alert When Golem Spawns: " + Utils.getColouredBoolean(ToggleCommand.golemAlertToggled)); rngesusAlert = new GuiButton(0, width / 2 - 100, (int) (height * 0.4), "RNGesus Alerts: " + Utils.getColouredBoolean(ToggleCommand.rngesusAlerts)); + lowHealthNotify = new GuiButton(0, width / 2 - 100, (int) (height * 0.5), "Low Health Notifications: " + Utils.getColouredBoolean(ToggleCommand.lowHealthNotifyToggled)); if (page == 1) { this.buttonList.add(changeDisplay); @@ -139,6 +141,7 @@ public class DankerGui extends GuiScreen { this.buttonList.add(lividSolver); this.buttonList.add(golemAlerts); this.buttonList.add(rngesusAlert); + this.buttonList.add(lowHealthNotify); this.buttonList.add(backPage); } @@ -268,6 +271,10 @@ public class DankerGui extends GuiScreen { ToggleCommand.healMessages = !ToggleCommand.healMessages; ConfigHandler.writeBooleanConfig("toggles", "HealMessages", ToggleCommand.healMessages); healMessages.displayString = "Heal Messages: " + Utils.getColouredBoolean(ToggleCommand.healMessages); + } else if (button == lowHealthNotify) { + ToggleCommand.lowHealthNotifyToggled = !ToggleCommand.lowHealthNotifyToggled; + ConfigHandler.writeBooleanConfig("toggles", "LowHealthNotify", ToggleCommand.lowHealthNotifyToggled); + lowHealthNotify.displayString = "Low Health Notifications: " + Utils.getColouredBoolean(ToggleCommand.lowHealthNotifyToggled); } } diff --git a/src/main/java/me/Danker/handlers/ConfigHandler.java b/src/main/java/me/Danker/handlers/ConfigHandler.java index 8cfc9bf..c5ede0c 100644 --- a/src/main/java/me/Danker/handlers/ConfigHandler.java +++ b/src/main/java/me/Danker/handlers/ConfigHandler.java @@ -193,6 +193,7 @@ public class ConfigHandler { if (!hasKey("toggles", "MidasStaffMessages")) writeBooleanConfig("toggles", "MidasStaffMessages", true); if (!hasKey("toggles", "HealMessages")) writeBooleanConfig("toggles", "HealMessages", true); if (!hasKey("toggles", "CakeTimer")) writeBooleanConfig("toggles", "CakeTimer", false); + if (!hasKey("toggles", "LowHealthNotify")) writeBooleanConfig("toggles", "LowHealthNotify", false); if (!hasKey("toggles", "LividSolver")) writeBooleanConfig("toggles", "LividSolver", false); // Puzzle Solvers if (!hasKey("toggles", "ThreeManPuzzle")) writeBooleanConfig("toggles", "ThreeManPuzzle", false); @@ -425,6 +426,7 @@ public class ConfigHandler { ToggleCommand.midasStaffMessages = getBoolean("toggles", "MidasStaffMessages"); ToggleCommand.healMessages = getBoolean("toggles", "HealMessages"); ToggleCommand.cakeTimerToggled = getBoolean("toggles", "CakeTimer"); + ToggleCommand.lowHealthNotifyToggled = getBoolean("toggles", "LowHealthNotify"); ToggleCommand.lividSolverToggled = getBoolean("toggles", "LividSolver"); // Puzzle Solvers ToggleCommand.threeManToggled = getBoolean("toggles", "ThreeManPuzzle"); -- cgit