From f214832fb6f315d59d876267f71e9e9f0a6082fd Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Wed, 20 Apr 2022 22:52:26 -0400 Subject: Add blaze slayer support + tracker --- .../me/Danker/commands/BlockSlayerCommand.java | 10 ++- .../java/me/Danker/commands/DisplayCommand.java | 13 +++- src/main/java/me/Danker/commands/LootCommand.java | 89 +++++++++++++++++++++- .../java/me/Danker/commands/ResetLootCommand.java | 39 +++++++++- .../me/Danker/commands/SkyblockPlayersCommand.java | 19 ++--- .../java/me/Danker/commands/SlayerCommand.java | 10 ++- .../java/me/Danker/commands/WeightCommand.java | 2 + 7 files changed, 156 insertions(+), 26 deletions(-) (limited to 'src/main/java/me/Danker/commands') diff --git a/src/main/java/me/Danker/commands/BlockSlayerCommand.java b/src/main/java/me/Danker/commands/BlockSlayerCommand.java index 9f51be6..37047c9 100644 --- a/src/main/java/me/Danker/commands/BlockSlayerCommand.java +++ b/src/main/java/me/Danker/commands/BlockSlayerCommand.java @@ -21,7 +21,7 @@ public class BlockSlayerCommand extends CommandBase { @Override public String getCommandUsage(ICommandSender arg0) { - return "/" + getCommandName() + " <1/2/3/4/5>"; + return "/" + getCommandName() + " <1/2/3/4/5>"; } public static String usage(ICommandSender arg0) { @@ -36,7 +36,7 @@ public class BlockSlayerCommand extends CommandBase { @Override public List addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) { if (args.length == 1) { - return getListOfStringsMatchingLastWord(args, "zombie", "spider", "wolf", "enderman"); + return getListOfStringsMatchingLastWord(args, "zombie", "spider", "wolf", "enderman", "blaze"); } else if (args.length == 2) { return getListOfStringsMatchingLastWord(args, "1", "2", "3", "4", "5"); } @@ -62,6 +62,12 @@ public class BlockSlayerCommand extends CommandBase { case "wolf": BlockWrongSlayer.onlySlayerName = "Sven Packmaster"; break; + case "enderman": + BlockWrongSlayer.onlySlayerName = "Voidgloom Seraph"; + break; + case "blaze": + BlockWrongSlayer.onlySlayerName = "Inferno Demonlord"; + break; case "off": BlockWrongSlayer.onlySlayerName = ""; BlockWrongSlayer.onlySlayerNumber = ""; diff --git a/src/main/java/me/Danker/commands/DisplayCommand.java b/src/main/java/me/Danker/commands/DisplayCommand.java index 3db6853..174258d 100644 --- a/src/main/java/me/Danker/commands/DisplayCommand.java +++ b/src/main/java/me/Danker/commands/DisplayCommand.java @@ -21,7 +21,7 @@ public class DisplayCommand extends CommandBase { @Override public String getCommandUsage(ICommandSender arg0) { - return "/" + getCommandName() + " [winter/festival/spooky/ch/session/f(1-7)/mm]"; + return "/" + getCommandName() + " [winter/festival/spooky/ch/session/f(1-7)/mm]"; } public static String usage(ICommandSender arg0) { @@ -36,7 +36,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", "enderman", "fishing", "catacombs", "mythological", "ghost", "auto", "off"); + return getListOfStringsMatchingLastWord(args, "wolf", "spider", "zombie", "enderman", "blaze", "fishing", "catacombs", "mythological", "ghost", "auto", "off"); } else if (args.length == 2 && args[0].equalsIgnoreCase("fishing")) { return getListOfStringsMatchingLastWord(args, "winter", "festival", "spooky", "ch", "session"); } else if (args.length == 2 && args[0].equalsIgnoreCase("catacombs")) { @@ -89,6 +89,13 @@ public class DisplayCommand extends CommandBase { LootDisplay.display = "enderman"; } break; + case "blaze": + if (showSession) { + LootDisplay.display = "blaze_session"; + } else { + LootDisplay.display = "blaze"; + } + break; case "fishing": if (arg1.length > 1) { switch (arg1[1].toLowerCase()) { @@ -213,7 +220,7 @@ public class DisplayCommand extends CommandBase { LootDisplay.display = "catacombs_master"; } default: - player.addChatMessage(new ChatComponentText(DankersSkyblockMod.ERROR_COLOUR + "Usage: /display catacombs ")); + player.addChatMessage(new ChatComponentText(DankersSkyblockMod.ERROR_COLOUR + "Usage: /display catacombs ")); return; } break; diff --git a/src/main/java/me/Danker/commands/LootCommand.java b/src/main/java/me/Danker/commands/LootCommand.java index 5edc5f4..5d91573 100644 --- a/src/main/java/me/Danker/commands/LootCommand.java +++ b/src/main/java/me/Danker/commands/LootCommand.java @@ -24,7 +24,7 @@ public class LootCommand extends CommandBase { @Override public String getCommandUsage(ICommandSender arg0) { - return "/" + getCommandName() + " [winter/festival/spooky/ch/f(1-7)/mm/session]"; + return "/" + getCommandName() + " [winter/festival/spooky/ch/f(1-7)/mm/session]"; } public static String usage(ICommandSender arg0) { @@ -39,7 +39,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", "enderman", "fishing", "catacombs", "mythological"); + return getListOfStringsMatchingLastWord(args, "wolf", "spider", "zombie", "enderman", "blaze", "fishing", "catacombs", "mythological"); } else if (args.length == 2 && args[0].equalsIgnoreCase("fishing")) { return getListOfStringsMatchingLastWord(args, "winter", "festival", "spooky", "ch", "session"); } else if (args.length == 2 && args[0].equalsIgnoreCase("catacombs")) { @@ -64,9 +64,8 @@ public class LootCommand extends CommandBase { String bossesBetween; String drop20; NumberFormat nf = NumberFormat.getIntegerInstance(Locale.US); - boolean showSession = false; - if (arg1[arg1.length - 1].equalsIgnoreCase("session")) showSession = true; + boolean showSession = arg1[arg1.length - 1].equalsIgnoreCase("session"); switch (arg1[0].toLowerCase()) { case "wolf": @@ -363,6 +362,88 @@ public class LootCommand extends CommandBase { EnumChatFormatting.AQUA + " Bosses Since RNG: " + bossesBetween + "\n" + EnumChatFormatting.DARK_PURPLE + EnumChatFormatting.BOLD + " -------------------")); break; + case "blaze": + if (showSession) { + if (BlazeTracker.timeSession == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(BlazeTracker.timeSession, timeNow); + } + if (BlazeTracker.bossesSession == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(BlazeTracker.bossesSession); + } + + player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " Blaze Loot Summary (Current Session):\n" + + EnumChatFormatting.GOLD + " Demonlords Killed: " + nf.format(BlazeTracker.demonlordsSession) + "\n" + + EnumChatFormatting.GRAY + " Derelict Ashes: " + nf.format(BlazeTracker.derelictAshesSession) + "\n" + + EnumChatFormatting.RED + " Lavatear Runes: " + nf.format(BlazeTracker.lavatearRunesSession) + "\n" + + EnumChatFormatting.AQUA + " Splash Potions: " + nf.format(BlazeTracker.splashPotionsSession) + "\n" + + EnumChatFormatting.DARK_RED + " Magma Arrows: " + nf.format(BlazeTracker.magmaArrowsSession) + "\n" + + EnumChatFormatting.DARK_AQUA + " Mana Disintegrators: " + nf.format(BlazeTracker.manaDisintegratorsSession) + "\n" + + EnumChatFormatting.LIGHT_PURPLE + " Scorched Books: " + nf.format(BlazeTracker.scorchedBooksSession) + "\n" + + EnumChatFormatting.WHITE + " Kelvin Inverters: " + nf.format(BlazeTracker.kelvinInvertersSession) + "\n" + + EnumChatFormatting.BLUE + " Blaze Rod Distillates: " + nf.format(BlazeTracker.blazeRodDistillatesSession) + "\n" + + EnumChatFormatting.BLUE + " Glowstone Distillates: " + nf.format(BlazeTracker.glowstoneDistillatesSession) + "\n" + + EnumChatFormatting.BLUE + " Magma Cream Distillates: " + nf.format(BlazeTracker.magmaCreamDistillatesSession) + "\n" + + EnumChatFormatting.BLUE + " Nether Wart Distillates: " + nf.format(BlazeTracker.netherWartDistillatesSession) + "\n" + + EnumChatFormatting.BLUE + " Gabagool Distillates: " + nf.format(BlazeTracker.gabagoolDistillatesSession) + "\n" + + EnumChatFormatting.RED + " Scorched Power Crystals: " + nf.format(BlazeTracker.scorchedPowerCrystalsSession) + "\n" + + EnumChatFormatting.RED + " Fire Aspect Books: " + nf.format(BlazeTracker.fireAspectBooksSession) + "\n" + + EnumChatFormatting.GOLD + " Fiery Burst Runes: " + nf.format(BlazeTracker.fieryBurstRunesSession) + "\n" + + EnumChatFormatting.WHITE + " Opal Gems: " + nf.format(BlazeTracker.opalGemsSession) + "\n" + + EnumChatFormatting.RED + " Archfiend Dice: " + nf.format(BlazeTracker.archfiendDiceSession) + "\n" + + EnumChatFormatting.LIGHT_PURPLE + " Duplex Books: " + nf.format(BlazeTracker.duplexBooksSession) + "\n" + + EnumChatFormatting.GOLD + " High Class Archfiend Dice: " + nf.format(BlazeTracker.highClassArchfiendDiceSession) + "\n" + + EnumChatFormatting.GOLD + " Engineering Plans: " + nf.format(BlazeTracker.engineeringPlansSession) + "\n" + + EnumChatFormatting.GOLD + " Subzero Inverters: " + nf.format(BlazeTracker.subzeroInvertersSession) + "\n" + + EnumChatFormatting.AQUA + " Time Since RNG: " + timeBetween + "\n" + + EnumChatFormatting.AQUA + " Bosses Since RNG: " + bossesBetween + "\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " -------------------")); + return; + } + + if (BlazeTracker.time == -1) { + timeBetween = "Never"; + } else { + timeBetween = Utils.getTimeBetween(BlazeTracker.time, timeNow); + } + if (BlazeTracker.bosses == -1) { + bossesBetween = "Never"; + } else { + bossesBetween = nf.format(BlazeTracker.bosses); + } + + player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "" + EnumChatFormatting.BOLD + "-------------------\n" + + EnumChatFormatting.DARK_RED + EnumChatFormatting.BOLD + " Blaze Loot Summary:\n" + + EnumChatFormatting.GOLD + " Demonlords Killed: " + nf.format(BlazeTracker.demonlords) + "\n" + + EnumChatFormatting.GRAY + " Derelict Ashes: " + nf.format(BlazeTracker.derelictAshes) + "\n" + + EnumChatFormatting.RED + " Lavatear Runes: " + nf.format(BlazeTracker.lavatearRunes) + "\n" + + EnumChatFormatting.AQUA + " Splash Potions: " + nf.format(BlazeTracker.splashPotions) + "\n" + + EnumChatFormatting.DARK_RED + " Magma Arrows: " + nf.format(BlazeTracker.magmaArrows) + "\n" + + EnumChatFormatting.DARK_AQUA + " Mana Disintegrators: " + nf.format(BlazeTracker.manaDisintegrators) + "\n" + + EnumChatFormatting.LIGHT_PURPLE + " Scorched Books: " + nf.format(BlazeTracker.scorchedBooks) + "\n" + + EnumChatFormatting.WHITE + " Kelvin Inverters: " + nf.format(BlazeTracker.kelvinInverters) + "\n" + + EnumChatFormatting.BLUE + " Blaze Rod Distillates: " + nf.format(BlazeTracker.blazeRodDistillates) + "\n" + + EnumChatFormatting.BLUE + " Glowstone Distillates: " + nf.format(BlazeTracker.glowstoneDistillates) + "\n" + + EnumChatFormatting.BLUE + " Magma Cream Distillates: " + nf.format(BlazeTracker.magmaCreamDistillates) + "\n" + + EnumChatFormatting.BLUE + " Nether Wart Distillates: " + nf.format(BlazeTracker.netherWartDistillates) + "\n" + + EnumChatFormatting.BLUE + " Gabagool Distillates: " + nf.format(BlazeTracker.gabagoolDistillates) + "\n" + + EnumChatFormatting.RED + " Scorched Power Crystals: " + nf.format(BlazeTracker.scorchedPowerCrystals) + "\n" + + EnumChatFormatting.RED + " Fire Aspect Books: " + nf.format(BlazeTracker.fireAspectBooks) + "\n" + + EnumChatFormatting.GOLD + " Fiery Burst Runes: " + nf.format(BlazeTracker.fieryBurstRunes) + "\n" + + EnumChatFormatting.WHITE + " Opal Gems: " + nf.format(BlazeTracker.opalGems) + "\n" + + EnumChatFormatting.RED + " Archfiend Dice: " + nf.format(BlazeTracker.archfiendDice) + "\n" + + EnumChatFormatting.LIGHT_PURPLE + " Duplex Books: " + nf.format(BlazeTracker.duplexBooks) + "\n" + + EnumChatFormatting.GOLD + " High Class Archfiend Dice: " + nf.format(BlazeTracker.highClassArchfiendDice) + "\n" + + EnumChatFormatting.GOLD + " Engineering Plans: " + nf.format(BlazeTracker.engineeringPlans) + "\n" + + EnumChatFormatting.GOLD + " Subzero Inverters: " + nf.format(BlazeTracker.subzeroInverters) + "\n" + + EnumChatFormatting.AQUA + " Time Since RNG: " + timeBetween + "\n" + + EnumChatFormatting.AQUA + " Bosses Since RNG: " + bossesBetween + "\n" + + EnumChatFormatting.RED + EnumChatFormatting.BOLD + " -------------------")); + break; case "fishing": if (arg1.length > 1) { if (arg1[1].equalsIgnoreCase("winter")) { diff --git a/src/main/java/me/Danker/commands/ResetLootCommand.java b/src/main/java/me/Danker/commands/ResetLootCommand.java index f1d2828..d3294b2 100644 --- a/src/main/java/me/Danker/commands/ResetLootCommand.java +++ b/src/main/java/me/Danker/commands/ResetLootCommand.java @@ -25,7 +25,7 @@ public class ResetLootCommand extends CommandBase { @Override public String getCommandUsage(ICommandSender arg0) { - return "/" + getCommandName() + ""; + return "/" + getCommandName() + ""; } public static String usage(ICommandSender arg0) { @@ -44,7 +44,7 @@ public class ResetLootCommand extends CommandBase { if (confirmReset) { return getListOfStringsMatchingLastWord(args, "confirm", "cancel"); } else { - return getListOfStringsMatchingLastWord(args, "zombie", "spider", "wolf", "enderman", "fishing", "mythological", "catacombs"); + return getListOfStringsMatchingLastWord(args, "zombie", "spider", "wolf", "enderman", "blaze", "fishing", "mythological", "catacombs"); } } @@ -53,7 +53,7 @@ public class ResetLootCommand extends CommandBase { final EntityPlayer player = (EntityPlayer) arg0; if (arg1.length == 0) { - player.addChatMessage(new ChatComponentText(DankersSkyblockMod.ERROR_COLOUR + "Usage: /resetloot ")); + player.addChatMessage(new ChatComponentText(DankersSkyblockMod.ERROR_COLOUR + "Usage: /resetloot ")); return; } @@ -75,6 +75,9 @@ public class ResetLootCommand extends CommandBase { case "enderman": resetEnderman(); break; + case "blaze": + resetBlaze(); + break; case "fishing": resetFishing(); break; @@ -102,6 +105,7 @@ public class ResetLootCommand extends CommandBase { case "spider": case "wolf": case "enderman": + case "blaze": case "fishing": case "mythological": case "catacombs": @@ -201,6 +205,35 @@ public class ResetLootCommand extends CommandBase { ConfigHandler.deleteCategory("enderman"); ConfigHandler.reloadConfig(); } + + static void resetBlaze() { + BlazeTracker.demonlordsSession = 0; + BlazeTracker.derelictAshesSession = 0; + BlazeTracker.lavatearRunesSession = 0; + BlazeTracker.splashPotionsSession = 0; + BlazeTracker.magmaArrowsSession = 0; + BlazeTracker.manaDisintegratorsSession = 0; + BlazeTracker.scorchedBooksSession = 0; + BlazeTracker.kelvinInvertersSession = 0; + BlazeTracker.blazeRodDistillatesSession = 0; + BlazeTracker.glowstoneDistillatesSession = 0; + BlazeTracker.magmaCreamDistillatesSession = 0; + BlazeTracker.netherWartDistillatesSession = 0; + BlazeTracker.gabagoolDistillatesSession = 0; + BlazeTracker.scorchedPowerCrystalsSession = 0; + BlazeTracker.fireAspectBooksSession = 0; + BlazeTracker.fieryBurstRunesSession = 0; + BlazeTracker.opalGemsSession = 0; + BlazeTracker.archfiendDiceSession = 0; + BlazeTracker.duplexBooksSession = 0; + BlazeTracker.highClassArchfiendDiceSession = 0; + BlazeTracker.engineeringPlansSession = 0; + BlazeTracker.subzeroInvertersSession = 0; + BlazeTracker.timeSession = 0; + BlazeTracker.bossesSession = 0; + ConfigHandler.deleteCategory("blaze"); + ConfigHandler.reloadConfig(); + } static void resetFishing() { FishingTracker.seaCreaturesSession = 0; diff --git a/src/main/java/me/Danker/commands/SkyblockPlayersCommand.java b/src/main/java/me/Danker/commands/SkyblockPlayersCommand.java index 0923b57..37e89c5 100644 --- a/src/main/java/me/Danker/commands/SkyblockPlayersCommand.java +++ b/src/main/java/me/Danker/commands/SkyblockPlayersCommand.java @@ -70,15 +70,14 @@ public class SkyblockPlayersCommand extends CommandBase { int skyblockTotalPlayers = 0; // players int privateIsland = 0; // dynamic int hub = 0; // hub - int barn = 0; // farming_1 - int mushroomDesert = 0; // farming_2 + int farmingIslands = 0; // farming_1 int park = 0; // foraging_1 int goldMine = 0; // mining_1 int deepCaverns = 0; // mining_2 int dwarvenMines = 0; // mining_3 int crystalHollows = 0; // crystal_hollows int spidersDen = 0; // combat_1 - int blazingFortress = 0; // combat_2 + int crimsonIsle = 0; // crimson_isle int end = 0; // combat_3 int dungeonsHub = 0; // dungeon_hub int dungeons = 0; // dungeon @@ -94,10 +93,7 @@ public class SkyblockPlayersCommand extends CommandBase { hub = skyblockPlayers.get("hub").getAsInt(); } if (skyblockPlayers.has("farming_1")) { - barn = skyblockPlayers.get("farming_1").getAsInt(); - } - if (skyblockPlayers.has("farming_2")) { - mushroomDesert = skyblockPlayers.get("farming_2").getAsInt(); + farmingIslands = skyblockPlayers.get("farming_1").getAsInt(); } if (skyblockPlayers.has("foraging_1")) { park = skyblockPlayers.get("foraging_1").getAsInt(); @@ -117,8 +113,8 @@ public class SkyblockPlayersCommand extends CommandBase { if (skyblockPlayers.has("combat_1")) { spidersDen = skyblockPlayers.get("combat_1").getAsInt(); } - if (skyblockPlayers.has("combat_2")) { - blazingFortress = skyblockPlayers.get("combat_2").getAsInt(); + if (skyblockPlayers.has("crimson_isle")) { + crimsonIsle = skyblockPlayers.get("crimson_isle").getAsInt(); } if (skyblockPlayers.has("combat_3")) { end = skyblockPlayers.get("combat_3").getAsInt(); @@ -143,15 +139,14 @@ public class SkyblockPlayersCommand extends CommandBase { DankersSkyblockMod.TYPE_COLOUR + " Skyblock: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(skyblockTotalPlayers) + " / " + Utils.getPercentage(skyblockTotalPlayers, totalPlayers) + "%\n" + DankersSkyblockMod.TYPE_COLOUR + " Private Island: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(privateIsland) + " / " + Utils.getPercentage(privateIsland, skyblockTotalPlayers) + "%\n" + DankersSkyblockMod.TYPE_COLOUR + " Hub: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(hub) + " / " + Utils.getPercentage(hub, skyblockTotalPlayers) + "%\n" + - DankersSkyblockMod.TYPE_COLOUR + " Barn: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(barn) + " / " + Utils.getPercentage(barn, skyblockTotalPlayers) + "%\n" + - DankersSkyblockMod.TYPE_COLOUR + " Mushroom Desert: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(mushroomDesert) + " / " + Utils.getPercentage(mushroomDesert, skyblockTotalPlayers) + "%\n" + + DankersSkyblockMod.TYPE_COLOUR + " Farming Islands: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(farmingIslands) + " / " + Utils.getPercentage(farmingIslands, skyblockTotalPlayers) + "%\n" + DankersSkyblockMod.TYPE_COLOUR + " Park: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(park) + " / " + Utils.getPercentage(park, skyblockTotalPlayers) + "%\n" + DankersSkyblockMod.TYPE_COLOUR + " Gold Mine: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(goldMine) + " / " + Utils.getPercentage(goldMine, skyblockTotalPlayers) + "%\n" + DankersSkyblockMod.TYPE_COLOUR + " Deep Caverns: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(deepCaverns) + " / " + Utils.getPercentage(deepCaverns, skyblockTotalPlayers) + "%\n" + DankersSkyblockMod.TYPE_COLOUR + " Dwarven Mines: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(dwarvenMines) + " / " + Utils.getPercentage(dwarvenMines, skyblockTotalPlayers) + "%\n" + DankersSkyblockMod.TYPE_COLOUR + " Crystal Hollows: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(crystalHollows) + " / " + Utils.getPercentage(crystalHollows, skyblockTotalPlayers) + "%\n" + DankersSkyblockMod.TYPE_COLOUR + " Spider's Den: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(spidersDen) + " / " + Utils.getPercentage(spidersDen, skyblockTotalPlayers) + "%\n" + - DankersSkyblockMod.TYPE_COLOUR + " Blazing Fortress: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(blazingFortress) + " / " + Utils.getPercentage(blazingFortress, skyblockTotalPlayers) + "%\n" + + DankersSkyblockMod.TYPE_COLOUR + " Crimson Isle: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(crimsonIsle) + " / " + Utils.getPercentage(crimsonIsle, skyblockTotalPlayers) + "%\n" + DankersSkyblockMod.TYPE_COLOUR + " The End: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(end) + " / " + Utils.getPercentage(end, skyblockTotalPlayers) + "%\n" + DankersSkyblockMod.TYPE_COLOUR + " Dungeons Hub: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(dungeonsHub) + " / " + Utils.getPercentage(dungeonsHub, skyblockTotalPlayers) + "%\n" + DankersSkyblockMod.TYPE_COLOUR + " Dungeons: " + DankersSkyblockMod.VALUE_COLOUR + nf.format(dungeons) + " / " + Utils.getPercentage(dungeons, skyblockTotalPlayers) + "%\n" + diff --git a/src/main/java/me/Danker/commands/SlayerCommand.java b/src/main/java/me/Danker/commands/SlayerCommand.java index 5444754..8ad87ae 100644 --- a/src/main/java/me/Danker/commands/SlayerCommand.java +++ b/src/main/java/me/Danker/commands/SlayerCommand.java @@ -113,15 +113,21 @@ public class SlayerCommand extends CommandBase { if (slayersObject.get("enderman").getAsJsonObject().has("xp")) { endermanXP = slayersObject.get("enderman").getAsJsonObject().get("xp").getAsInt(); } + // Blaze + int blazeXP = 0; + if (slayersObject.get("blaze").getAsJsonObject().has("xp")) { + blazeXP = slayersObject.get("blaze").getAsJsonObject().get("xp").getAsInt(); + } NumberFormat nf = NumberFormat.getIntegerInstance(Locale.US); player.addChatMessage(new ChatComponentText(DankersSkyblockMod.DELIMITER_COLOUR + "" + EnumChatFormatting.BOLD + "-------------------\n" + - EnumChatFormatting.AQUA + " " + username + "'s Total XP: " + EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + nf.format(zombieXP + spiderXP + wolfXP + endermanXP) + "\n" + + EnumChatFormatting.AQUA + " " + username + "'s Total XP: " + EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + nf.format(zombieXP + spiderXP + wolfXP + endermanXP + blazeXP) + "\n" + DankersSkyblockMod.TYPE_COLOUR + " Zombie XP: " + DankersSkyblockMod.VALUE_COLOUR + EnumChatFormatting.BOLD + nf.format(zombieXP) + "\n" + DankersSkyblockMod.TYPE_COLOUR + " Spider XP: " + DankersSkyblockMod.VALUE_COLOUR + EnumChatFormatting.BOLD + nf.format(spiderXP) + "\n" + DankersSkyblockMod.TYPE_COLOUR + " Wolf XP: " + DankersSkyblockMod.VALUE_COLOUR + EnumChatFormatting.BOLD + nf.format(wolfXP) + "\n" + DankersSkyblockMod.TYPE_COLOUR + " Enderman XP: " + DankersSkyblockMod.VALUE_COLOUR + EnumChatFormatting.BOLD + nf.format(endermanXP) + "\n" + - DankersSkyblockMod.DELIMITER_COLOUR + " " + EnumChatFormatting.BOLD + "-------------------")); + DankersSkyblockMod.TYPE_COLOUR + " Blaze XP: " + DankersSkyblockMod.VALUE_COLOUR + EnumChatFormatting.BOLD + nf.format(blazeXP) + "\n" + + DankersSkyblockMod.DELIMITER_COLOUR + EnumChatFormatting.BOLD + "-------------------")); }).start(); } diff --git a/src/main/java/me/Danker/commands/WeightCommand.java b/src/main/java/me/Danker/commands/WeightCommand.java index b00d881..ade909d 100644 --- a/src/main/java/me/Danker/commands/WeightCommand.java +++ b/src/main/java/me/Danker/commands/WeightCommand.java @@ -63,6 +63,8 @@ public class WeightCommand extends CommandBase { public List addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) { if (args.length == 1) { return Utils.getMatchingPlayers(args[0]); + } else if (args.length == 2) { + return getListOfStringsMatchingLastWord(args, "lily", "farming"); } return null; } -- cgit