diff options
-rw-r--r-- | README.md | 4 | ||||
-rw-r--r-- | me/Danker/TheMod.java | 71 | ||||
-rw-r--r-- | me/Danker/commands/DHelpCommand.java | 2 | ||||
-rw-r--r-- | me/Danker/commands/LootCommand.java | 49 | ||||
-rw-r--r-- | me/Danker/commands/ResetLootCommand.java | 3 | ||||
-rw-r--r-- | me/Danker/commands/ToggleCommand.java | 17 | ||||
-rw-r--r-- | me/Danker/handlers/ConfigHandler.java | 8 |
7 files changed, 122 insertions, 32 deletions
@@ -12,7 +12,7 @@ QOL changes that enhances your Hypixel Skyblock experience. Created to add featu ## Commands - /dhelp - Returns this message in-game. -- /toggle <gparty/coords/golden/list> - Toggles features. /toggle list returns values of every toggle. +- /toggle <gparty/coords/golden/slayercount/list> - Toggles features. /toggle list returns values of every toggle. - /setkey <key> - Sets API key. - /getkey - Returns key set with /setkey. - /loot <zombie/spider/wolf/fishing> [winter/session] - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead. @@ -31,5 +31,5 @@ QOL changes that enhances your Hypixel Skyblock experience. Created to add featu - 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. -- An incorrect API key will result in an HTTP error code of 402. +- An incorrect API key will result in an HTTP error code of 403. - Importing fishing uses your sea creature kills, which may not always be exactly correct (e.x. someone else kills your sea creature). diff --git a/me/Danker/TheMod.java b/me/Danker/TheMod.java index bd58713..0d1c138 100644 --- a/me/Danker/TheMod.java +++ b/me/Danker/TheMod.java @@ -196,7 +196,7 @@ public class TheMod boolean spiderRNG = false; boolean zombieRNG = false; // T6 books - if (message.contains("VERY RARE DROP! (Enchanted Book)")) { + if (message.contains("VERY RARE DROP! (Enchanted Book)") || message.contains("CRAZY RARE DROP! (Enchanted Book)")) { // Loop through scoreboard to see what boss you're doing List<String> scoreboard = ScoreboardHandler.getSidebarLines(); for (String s : scoreboard) { @@ -227,6 +227,11 @@ public class TheMod cf.writeIntConfig("wolf", "svens", lc.wolfSvens); cf.writeIntConfig("wolf", "bossRNG", lc.wolfBosses); } + if (message.contains("RARE DROP! (Hamster Wheel)")) { + lc.wolfWheelsDrops++; + lc.wolfWheelsDropsSession++; + cf.writeIntConfig("wolf", "wheelDrops", lc.wolfWheelsDrops); + } // Removing the unicode here *should* fix rune drops not counting if (message.contains("VERY RARE DROP! (") && message.contains(" Spirit Rune I)")) { lc.wolfSpirits++; @@ -272,6 +277,11 @@ public class TheMod cf.writeIntConfig("spider", "tarantulas", lc.spiderTarantulas); cf.writeIntConfig("spider", "bossRNG", lc.spiderBosses); } + if (message.contains("RARE DROP! (Toxic Arrow Poison)")) { + lc.spiderTAPDrops++; + lc.spiderTAPDropsSession++; + cf.writeIntConfig("spider", "tapDrops", lc.spiderTAPDrops); + } if (message.contains("VERY RARE DROP! (") && message.contains(" Bite Rune I)")) { lc.spiderBites++; lc.spiderBitesSession++; @@ -282,12 +292,6 @@ public class TheMod lc.spiderCatalystsSession++; cf.writeIntConfig("spider", "catalyst", lc.spiderCatalysts); } - // T3 Spider Book Drop - if (message.contains("CRAZY RARE DROP! (Enchanted Book)")) { - lc.spiderBooks++; - lc.spiderBooksSession++; - cf.writeIntConfig("spider", "book", lc.spiderBooks); - } if (message.contains("CRAZY RARE DROP! (Fly Swatter)")) { spiderRNG = true; lc.spiderSwatters++; @@ -320,8 +324,11 @@ public class TheMod cf.writeIntConfig("zombie", "revs", lc.zombieRevs); cf.writeIntConfig("wolf", "bossRNG", lc.zombieBosses); } - // I couldn't find a pic of someone getting this drop, so I'm assuming this - // works + if (message.contains("RARE DROP! (Foul Flesh)")) { + lc.zombieFoulFleshDrops++; + lc.zombieFoulFleshDropsSession++; + cf.writeIntConfig("zombie", "foulFleshDrops", lc.zombieFoulFleshDrops); + } if (message.contains("VERY RARE DROP! (Revenant Catalyst)")) { lc.zombieRevCatas++; lc.zombieRevCatasSession++; @@ -617,6 +624,7 @@ public class TheMod if (event.type != RenderGameOverlayEvent.ElementType.EXPERIENCE) return; final ToggleCommand tc = new ToggleCommand(); final MoveCommand moc = new MoveCommand(); + final DisplayCommand ds = new DisplayCommand(); if (tc.coordsToggled) { EntityPlayer player = Minecraft.getMinecraft().thePlayer; @@ -630,14 +638,13 @@ public class TheMod new TextRenderer(Minecraft.getMinecraft(), coordText, moc.coordsXY[0], moc.coordsXY[1], Integer.parseInt("FFFFFF", 16)); } - final DisplayCommand ds = new DisplayCommand(); - if (!ds.display.equals("off")) { final LootCommand lc = new LootCommand(); String dropsText = ""; String countText = ""; String timeBetween = "Never"; String bossesBetween = "Never"; + String drop20; double timeNow = System.currentTimeMillis() / 1000; NumberFormat nf = NumberFormat.getIntegerInstance(Locale.US); @@ -652,6 +659,11 @@ public class TheMod } else { bossesBetween = nf.format(lc.wolfBosses); } + if (tc.slayerCountTotal) { + drop20 = nf.format(lc.wolfWheels); + } else { + drop20 = nf.format(lc.wolfWheelsDrops) + " times"; + } dropsText = EnumChatFormatting.GOLD + "Svens Killed:\n" + EnumChatFormatting.GREEN + "Wolf Teeth:\n" + @@ -666,7 +678,7 @@ public class TheMod EnumChatFormatting.AQUA + "Bosses Since RNG:"; countText = EnumChatFormatting.GOLD + nf.format(lc.wolfSvens) + "\n" + EnumChatFormatting.GREEN + nf.format(lc.wolfTeeth) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.wolfWheels) + "\n" + + EnumChatFormatting.BLUE + drop20 + "\n" + EnumChatFormatting.AQUA + lc.wolfSpirits + "\n" + EnumChatFormatting.WHITE + lc.wolfBooks + "\n" + EnumChatFormatting.DARK_RED + lc.wolfEggs + "\n" + @@ -686,6 +698,11 @@ public class TheMod } else { bossesBetween = nf.format(lc.wolfBossesSession); } + if (tc.slayerCountTotal) { + drop20 = nf.format(lc.wolfWheelsSession); + } else { + drop20 = nf.format(lc.wolfWheelsDropsSession) + " times"; + } dropsText = EnumChatFormatting.GOLD + "Svens Killed:\n" + EnumChatFormatting.GREEN + "Wolf Teeth:\n" + @@ -700,7 +717,7 @@ public class TheMod EnumChatFormatting.AQUA + "Bosses Since RNG:"; countText = EnumChatFormatting.GOLD + nf.format(lc.wolfSvensSession) + "\n" + EnumChatFormatting.GREEN + nf.format(lc.wolfTeethSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.wolfWheelsSession) + "\n" + + EnumChatFormatting.BLUE + drop20 + "\n" + EnumChatFormatting.AQUA + lc.wolfSpiritsSession + "\n" + EnumChatFormatting.WHITE + lc.wolfBooksSession + "\n" + EnumChatFormatting.DARK_RED + lc.wolfEggsSession + "\n" + @@ -720,6 +737,11 @@ public class TheMod } else { bossesBetween = nf.format(lc.spiderBosses); } + if (tc.slayerCountTotal) { + drop20 = nf.format(lc.spiderTAP); + } else { + drop20 = nf.format(lc.spiderTAPDrops) + " times"; + } dropsText = EnumChatFormatting.GOLD + "Tarantulas Killed:\n" + EnumChatFormatting.GREEN + "Tarantula Webs:\n" + @@ -734,7 +756,7 @@ public class TheMod EnumChatFormatting.AQUA + "Bosses Since RNG:"; countText = EnumChatFormatting.GOLD + nf.format(lc.spiderTarantulas) + "\n" + EnumChatFormatting.GREEN + nf.format(lc.spiderWebs) + "\n" + - EnumChatFormatting.DARK_GREEN + nf.format(lc.spiderTAP) + "\n" + + EnumChatFormatting.DARK_GREEN + drop20 + "\n" + EnumChatFormatting.DARK_GRAY + lc.spiderBites + "\n" + EnumChatFormatting.WHITE + lc.spiderBooks + "\n" + EnumChatFormatting.AQUA + lc.spiderCatalysts + "\n" + @@ -754,6 +776,11 @@ public class TheMod } else { bossesBetween = nf.format(lc.spiderBossesSession); } + if (tc.slayerCountTotal) { + drop20 = nf.format(lc.spiderTAPSession); + } else { + drop20 = nf.format(lc.spiderTAPDropsSession) + " times"; + } dropsText = EnumChatFormatting.GOLD + "Tarantulas Killed:\n" + EnumChatFormatting.GREEN + "Tarantula Webs:\n" + @@ -768,7 +795,7 @@ public class TheMod EnumChatFormatting.AQUA + "Bosses Since RNG:"; countText = EnumChatFormatting.GOLD + nf.format(lc.spiderTarantulasSession) + "\n" + EnumChatFormatting.GREEN + nf.format(lc.spiderWebsSession) + "\n" + - EnumChatFormatting.DARK_GREEN + nf.format(lc.spiderTAPSession) + "\n" + + EnumChatFormatting.DARK_GREEN + drop20 + "\n" + EnumChatFormatting.DARK_GRAY + lc.spiderBitesSession + "\n" + EnumChatFormatting.WHITE + lc.spiderBooksSession + "\n" + EnumChatFormatting.AQUA + lc.spiderCatalystsSession + "\n" + @@ -788,6 +815,11 @@ public class TheMod } else { bossesBetween = nf.format(lc.zombieBosses); } + if (tc.slayerCountTotal) { + drop20 = nf.format(lc.zombieFoulFlesh); + } else { + drop20 = nf.format(lc.zombieFoulFleshDrops) + " times"; + } dropsText = EnumChatFormatting.GOLD + "Revs Killed:\n" + EnumChatFormatting.GREEN + "Revenant Flesh:\n" + @@ -803,7 +835,7 @@ public class TheMod EnumChatFormatting.AQUA + "Bosses Since RNG:"; countText = EnumChatFormatting.GOLD + nf.format(lc.zombieRevs) + "\n" + EnumChatFormatting.GREEN + nf.format(lc.zombieRevFlesh) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.zombieFoulFlesh) + "\n" + + EnumChatFormatting.BLUE + drop20 + "\n" + EnumChatFormatting.DARK_GREEN + lc.zombiePestilences + "\n" + EnumChatFormatting.WHITE + lc.zombieBooks + "\n" + EnumChatFormatting.AQUA + lc.zombieUndeadCatas + "\n" + @@ -824,6 +856,11 @@ public class TheMod } else { bossesBetween = nf.format(lc.zombieBossesSession); } + if (tc.slayerCountTotal) { + drop20 = nf.format(lc.zombieFoulFleshSession); + } else { + drop20 = nf.format(lc.zombieFoulFleshDropsSession) + " times"; + } dropsText = EnumChatFormatting.GOLD + "Revs Killed:\n" + EnumChatFormatting.GREEN + "Revenant Flesh:\n" + @@ -839,7 +876,7 @@ public class TheMod EnumChatFormatting.AQUA + "Bosses Since RNG:"; countText = EnumChatFormatting.GOLD + nf.format(lc.zombieRevsSession) + "\n" + EnumChatFormatting.GREEN + nf.format(lc.zombieRevFleshSession) + "\n" + - EnumChatFormatting.BLUE + nf.format(lc.zombieFoulFleshSession) + "\n" + + EnumChatFormatting.BLUE + drop20 + "\n" + EnumChatFormatting.DARK_GREEN + lc.zombiePestilencesSession + "\n" + EnumChatFormatting.WHITE + lc.zombieBooksSession + "\n" + EnumChatFormatting.AQUA + lc.zombieUndeadCatasSession + "\n" + diff --git a/me/Danker/commands/DHelpCommand.java b/me/Danker/commands/DHelpCommand.java index 4958858..1e2d4aa 100644 --- a/me/Danker/commands/DHelpCommand.java +++ b/me/Danker/commands/DHelpCommand.java @@ -32,7 +32,7 @@ public class DHelpCommand extends CommandBase { player.addChatMessage(new ChatComponentText("\n" + EnumChatFormatting.GOLD + " " + TheMod.MODID + " Version " + TheMod.VERSION + "\n" + EnumChatFormatting.AQUA + " <> = Mandatory parameter. [] = Optional parameter.\n" + EnumChatFormatting.GOLD + " /dhelp" + EnumChatFormatting.AQUA + " - Returns this message.\n" + - EnumChatFormatting.GOLD + " /toggle <gparty/coords/golden/list>" + EnumChatFormatting.AQUA + " - Toggles features. /toggle list returns values of every toggle.\n" + + EnumChatFormatting.GOLD + " /toggle <gparty/coords/golden/slayercount/list>" + EnumChatFormatting.AQUA + " - Toggles features. /toggle list returns values of every toggle.\n" + EnumChatFormatting.GOLD + " /setkey <key>" + EnumChatFormatting.AQUA + " - Sets API key.\n" + EnumChatFormatting.GOLD + " /getkey" + EnumChatFormatting.AQUA + " - Returns key set with /setkey.\n" + EnumChatFormatting.GOLD + " /loot <zombie/spider/wolf/fishing> [winter/session]" + EnumChatFormatting.AQUA + " - Returns loot received from slayer quests or fishing stats. /loot fishing winter returns winter sea creatures instead.\n" + diff --git a/me/Danker/commands/LootCommand.java b/me/Danker/commands/LootCommand.java index c3a0e9b..d64e9d9 100644 --- a/me/Danker/commands/LootCommand.java +++ b/me/Danker/commands/LootCommand.java @@ -17,6 +17,7 @@ public class LootCommand extends CommandBase { public static int wolfSvens; public static int wolfTeeth; public static int wolfWheels; + public static int wolfWheelsDrops; public static int wolfSpirits; public static int wolfBooks; public static int wolfEggs; @@ -29,6 +30,7 @@ public class LootCommand extends CommandBase { public static int spiderTarantulas; public static int spiderWebs; public static int spiderTAP; + public static int spiderTAPDrops; public static int spiderBites; public static int spiderCatalysts; public static int spiderBooks; @@ -41,6 +43,7 @@ public class LootCommand extends CommandBase { public static int zombieRevs; public static int zombieRevFlesh; public static int zombieFoulFlesh; + public static int zombieFoulFleshDrops; public static int zombiePestilences; public static int zombieUndeadCatas; public static int zombieBooks; @@ -83,6 +86,7 @@ public class LootCommand extends CommandBase { public static int wolfSvensSession = 0; public static int wolfTeethSession = 0; public static int wolfWheelsSession = 0; + public static int wolfWheelsDropsSession = 0; public static int wolfSpiritsSession = 0; public static int wolfBooksSession = 0; public static int wolfEggsSession = 0; @@ -95,6 +99,7 @@ public class LootCommand extends CommandBase { public static int spiderTarantulasSession = 0; public static int spiderWebsSession = 0; public static int spiderTAPSession = 0; + public static int spiderTAPDropsSession = 0; public static int spiderBitesSession = 0; public static int spiderCatalystsSession = 0; public static int spiderBooksSession = 0; @@ -107,6 +112,7 @@ public class LootCommand extends CommandBase { public static int zombieRevsSession = 0; public static int zombieRevFleshSession = 0; public static int zombieFoulFleshSession = 0; + public static int zombieFoulFleshDropsSession = 0; public static int zombiePestilencesSession = 0; public static int zombieUndeadCatasSession = 0; public static int zombieBooksSession = 0; @@ -212,6 +218,7 @@ public class LootCommand extends CommandBase { double timeNow = System.currentTimeMillis() / 1000; String timeBetween; String bossesBetween; + String drop20; NumberFormat nf = NumberFormat.getIntegerInstance(Locale.US); boolean showSession = false; @@ -237,12 +244,17 @@ public class LootCommand extends CommandBase { } 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: " + nf.format(wolfWheelsSession) + "\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" + @@ -265,12 +277,17 @@ public class LootCommand extends CommandBase { } 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: " + nf.format(wolfWheels) + "\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" + @@ -292,12 +309,17 @@ public class LootCommand extends CommandBase { } 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: " + nf.format(spiderTAPSession) + "\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" + @@ -320,12 +342,17 @@ public class LootCommand extends CommandBase { } 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: " + nf.format(spiderTAP) + "\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" + @@ -347,12 +374,17 @@ public class LootCommand extends CommandBase { } 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: " + nf.format(zombieFoulFleshSession) + "\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" + @@ -376,12 +408,17 @@ public class LootCommand extends CommandBase { } 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: " + nf.format(zombieFoulFlesh) + "\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" + diff --git a/me/Danker/commands/ResetLootCommand.java b/me/Danker/commands/ResetLootCommand.java index 01e8b11..1afc204 100644 --- a/me/Danker/commands/ResetLootCommand.java +++ b/me/Danker/commands/ResetLootCommand.java @@ -94,6 +94,7 @@ public class ResetLootCommand extends CommandBase { lc.zombieRevsSession = 0; lc.zombieRevFleshSession = 0; lc.zombieFoulFleshSession = 0; + lc.zombieFoulFleshDropsSession = 0; lc.zombiePestilencesSession = 0; lc.zombieUndeadCatasSession = 0; lc.zombieBooksSession = 0; @@ -114,6 +115,7 @@ public class ResetLootCommand extends CommandBase { lc.spiderTarantulasSession = 0; lc.spiderWebsSession = 0; lc.spiderTAPSession = 0; + lc.spiderTAPDropsSession = 0; lc.spiderBitesSession = 0; lc.spiderCatalystsSession = 0; lc.spiderBooksSession = 0; @@ -132,6 +134,7 @@ public class ResetLootCommand extends CommandBase { lc.wolfSvensSession = 0; lc.wolfTeethSession = 0; lc.wolfWheelsSession = 0; + lc.wolfWheelsDropsSession = 0; lc.wolfSpiritsSession = 0; lc.wolfBooksSession = 0; lc.wolfEggsSession = 0; diff --git a/me/Danker/commands/ToggleCommand.java b/me/Danker/commands/ToggleCommand.java index 218378f..793dc40 100644 --- a/me/Danker/commands/ToggleCommand.java +++ b/me/Danker/commands/ToggleCommand.java @@ -16,7 +16,8 @@ public class ToggleCommand extends CommandBase implements ICommand { public static boolean gpartyToggled; public static boolean coordsToggled; public static boolean goldenToggled; - + public static boolean slayerCountTotal; + @Override public String getCommandName() { return "toggle"; @@ -24,7 +25,7 @@ public class ToggleCommand extends CommandBase implements ICommand { @Override public String getCommandUsage(ICommandSender arg0) { - return getCommandName() + " <gparty/coords/golden/list>"; + return getCommandName() + " <gparty/coords/golden/slayercount/list>"; } @Override @@ -35,7 +36,7 @@ public class ToggleCommand extends CommandBase implements ICommand { @Override public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) { if (args.length == 1) { - return getListOfStringsMatchingLastWord(args, "gparty", "coords", "golden", "list"); + return getListOfStringsMatchingLastWord(args, "gparty", "coords", "golden", "slayercount", "list"); } return null; } @@ -46,7 +47,7 @@ public class ToggleCommand extends CommandBase implements ICommand { final ConfigHandler cf = new ConfigHandler(); if (arg1.length == 0) { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "Usage: /toggle <gparty/coords/golden/list>")); + player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "Usage: /toggle <gparty/coords/golden/slayercount/list>")); return; } @@ -62,12 +63,16 @@ public class ToggleCommand extends CommandBase implements ICommand { goldenToggled = !goldenToggled; cf.writeBooleanConfig("toggles", "Golden", goldenToggled); player.addChatMessage(new ChatComponentText(EnumChatFormatting.GREEN + "Golden T6 enchants has been set to " + EnumChatFormatting.DARK_GREEN + goldenToggled + EnumChatFormatting.GREEN + ".")); + } else if (arg1[0].equalsIgnoreCase("slayercount")) { + slayerCountTotal = !slayerCountTotal; + player.addChatMessage(new ChatComponentText(EnumChatFormatting.GREEN + "Counting total 20% slayer drops has been set to " + EnumChatFormatting.DARK_GREEN + slayerCountTotal + EnumChatFormatting.GREEN + ".")); } 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)); + EnumChatFormatting.GREEN + " Golden T6 enchants: " + EnumChatFormatting.DARK_GREEN + goldenToggled + "\n" + + EnumChatFormatting.GREEN + " Counting total 20% slayer drops: " + EnumChatFormatting.DARK_GREEN + slayerCountTotal)); } else { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "Usage: /toggle <gparty/coords/golden/list>")); + player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "Usage: /toggle <gparty/coords/golden/slayercount/list>")); } } } diff --git a/me/Danker/handlers/ConfigHandler.java b/me/Danker/handlers/ConfigHandler.java index 0426fba..64b97e4 100644 --- a/me/Danker/handlers/ConfigHandler.java +++ b/me/Danker/handlers/ConfigHandler.java @@ -171,12 +171,14 @@ public class ConfigHandler { if (!hasKey("toggles", "GParty")) writeBooleanConfig("toggles", "GParty", false); if (!hasKey("toggles", "Coords")) writeBooleanConfig("toggles", "Coords", false); if (!hasKey("toggles", "Golden")) writeBooleanConfig("toggles", "Golden", false); + if (!hasKey("toggles", "SlayerCount")) writeBooleanConfig("toggles", "SlayerCount", true); if (!hasKey("api", "APIKey")) writeStringConfig("api", "APIKey", ""); // Wolf Loot if (!hasKey("wolf", "svens")) writeIntConfig("wolf", "svens", 0); if (!hasKey("wolf", "teeth")) writeIntConfig("wolf", "teeth", 0); if (!hasKey("wolf", "wheel")) writeIntConfig("wolf", "wheel", 0); + if (!hasKey("wolf", "wheelDrops")) writeIntConfig("wolf", "wheelDrops", 0); if (!hasKey("wolf", "spirit")) writeIntConfig("wolf", "spirit", 0); if (!hasKey("wolf", "book")) writeIntConfig("wolf", "book", 0); if (!hasKey("wolf", "egg")) writeIntConfig("wolf", "egg", 0); @@ -189,6 +191,7 @@ public class ConfigHandler { if (!hasKey("spider", "tarantulas")) writeIntConfig("spider", "tarantulas", 0); if (!hasKey("spider", "web")) writeIntConfig("spider", "web", 0); if (!hasKey("spider", "tap")) writeIntConfig("spider", "tap", 0); + if (!hasKey("spider", "tapDrops")) writeIntConfig("spider", "tapDrops", 0); if (!hasKey("spider", "bite")) writeIntConfig("spider", "bite", 0); if (!hasKey("spider", "catalyst")) writeIntConfig("spider", "catalyst", 0); if (!hasKey("spider", "book")) writeIntConfig("spider", "book", 0); @@ -201,6 +204,7 @@ public class ConfigHandler { if (!hasKey("zombie", "revs")) writeIntConfig("zombie", "revs", 0); if (!hasKey("zombie", "revFlesh")) writeIntConfig("zombie", "revFlesh", 0); if (!hasKey("zombie", "foulFlesh")) writeIntConfig("zombie", "foulFlesh", 0); + if (!hasKey("zombie", "foulFleshDrops")) writeIntConfig("zombie", "foulFleshDrops", 0); if (!hasKey("zombie", "pestilence")) writeIntConfig("zombie", "pestilence", 0); if (!hasKey("zombie", "undeadCatalyst")) writeIntConfig("zombie", "undeadCatalyst", 0); if (!hasKey("zombie", "book")) writeIntConfig("zombie", "book", 0); @@ -251,12 +255,14 @@ public class ConfigHandler { tf.gpartyToggled = getBoolean("toggles", "GParty"); tf.coordsToggled = getBoolean("toggles", "Coords"); tf.goldenToggled = getBoolean("toggles", "Golden"); + tf.slayerCountTotal = getBoolean("toggles", "SlayerCount"); 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"); @@ -269,6 +275,7 @@ public class ConfigHandler { 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"); @@ -281,6 +288,7 @@ public class ConfigHandler { 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"); |