diff options
author | bowser0000 <bowser0000@gmail.com> | 2021-07-31 19:58:02 -0400 |
---|---|---|
committer | bowser0000 <bowser0000@gmail.com> | 2021-07-31 19:58:02 -0400 |
commit | a49b673bd9badcb7c4c02539f53c39c5b52c1b32 (patch) | |
tree | 649d076f99fe34d45fec19e86a36b9c5e8a120c1 /src/main/java/me/Danker/utils/Utils.java | |
parent | 342c6c8c6096db1e3e0e2ea4363ba34764f1121b (diff) | |
download | SkyblockMod-a49b673bd9badcb7c4c02539f53c39c5b52c1b32.tar.gz SkyblockMod-a49b673bd9badcb7c4c02539f53c39c5b52c1b32.tar.bz2 SkyblockMod-a49b673bd9badcb7c4c02539f53c39c5b52c1b32.zip |
Add custom music to every area
Hub, island, farming islands, gold mine, deep caverns, dwarven mines, crystal hollows, blazing fortress, end, park
Diffstat (limited to 'src/main/java/me/Danker/utils/Utils.java')
-rw-r--r-- | src/main/java/me/Danker/utils/Utils.java | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/main/java/me/Danker/utils/Utils.java b/src/main/java/me/Danker/utils/Utils.java index dd6eed5..c1e76d7 100644 --- a/src/main/java/me/Danker/utils/Utils.java +++ b/src/main/java/me/Danker/utils/Utils.java @@ -40,7 +40,7 @@ public class Utils { public static boolean inSkyblock = false; public static boolean inDungeons = false; - public static boolean inCrystalHollows = false; + public static String tabLocation = ""; 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, @@ -170,18 +170,19 @@ public class Utils { inDungeons = false; } - public static void checkForCrystalHollows() { - if (inSkyblock) { + public static void checkTabLocation() { + if (inSkyblock) { Collection<NetworkPlayerInfo> players = Minecraft.getMinecraft().getNetHandler().getPlayerInfoMap(); for (NetworkPlayerInfo player : players) { if (player == null || player.getDisplayName() == null) continue; - if (player.getDisplayName().getUnformattedText().contains("Crystal Hollows")) { - inCrystalHollows = true; + String text = player.getDisplayName().getUnformattedText(); + if (text.startsWith("Area: ")) { + tabLocation = text.substring(text.indexOf(":") + 2); return; } } } - inCrystalHollows = false; + tabLocation = ""; } public static boolean isInScoreboard(String text) { |