diff options
author | bowser0000 <bowser0000@gmail.com> | 2021-04-18 17:49:02 -0400 |
---|---|---|
committer | bowser0000 <bowser0000@gmail.com> | 2021-04-18 17:49:02 -0400 |
commit | 6c870810d6798bd9e445f2586455311d1a817976 (patch) | |
tree | d0bfa76f4f54417094aee6305e12203773a5e7e5 /src/main/java/me/Danker/utils/Utils.java | |
parent | 5360b5ceb83feab156f1e70460b842ba7721544b (diff) | |
download | SkyblockMod-6c870810d6798bd9e445f2586455311d1a817976.tar.gz SkyblockMod-6c870810d6798bd9e445f2586455311d1a817976.tar.bz2 SkyblockMod-6c870810d6798bd9e445f2586455311d1a817976.zip |
Add highlighting Skeleton Masters
Diffstat (limited to 'src/main/java/me/Danker/utils/Utils.java')
-rw-r--r-- | src/main/java/me/Danker/utils/Utils.java | 23 |
1 files changed, 14 insertions, 9 deletions
diff --git a/src/main/java/me/Danker/utils/Utils.java b/src/main/java/me/Danker/utils/Utils.java index 1a24c69..160fc0a 100644 --- a/src/main/java/me/Danker/utils/Utils.java +++ b/src/main/java/me/Danker/utils/Utils.java @@ -145,17 +145,22 @@ public class Utils { } public static void checkForDungeons() { - if (inSkyblock) { - List<String> scoreboard = ScoreboardHandler.getSidebarLines(); - for (String s : scoreboard) { - String sCleaned = ScoreboardHandler.cleanSB(s); - if (sCleaned.contains("The Catacombs")) { - inDungeons = true; - return; - } + if (inSkyblock) { + if (isInScoreboard("The Catacombs")) { + inDungeons = true; + return; } } - inDungeons = false; + inDungeons = false; + } + + public static boolean isInScoreboard(String text) { + List<String> scoreboard = ScoreboardHandler.getSidebarLines(); + for (String s : scoreboard) { + String sCleaned = ScoreboardHandler.cleanSB(s); + if (sCleaned.contains(text)) return true; + } + return false; } public static String capitalizeString(String string) { |