diff options
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/features/misc/NonGodPotEffectDisplay.kt | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/misc/NonGodPotEffectDisplay.kt b/src/main/java/at/hannibal2/skyhanni/features/misc/NonGodPotEffectDisplay.kt index 6549efaa9..fabff46ba 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/misc/NonGodPotEffectDisplay.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/misc/NonGodPotEffectDisplay.kt @@ -182,9 +182,13 @@ class NonGodPotEffectDisplay { for (line in lines) { for (effect in NonGodPotEffect.values()) { if (line.startsWith(effect.displayName)) { - val duration = TimeUtils.getMillis(line.split("§f")[1]) - effectDuration[effect] = System.currentTimeMillis() + duration - update() + try { + val duration = TimeUtils.getMillis(line.split("§f")[1]) + effectDuration[effect] = System.currentTimeMillis() + duration + update() + } catch (e: IndexOutOfBoundsException) { + LorenzUtils.debug("Error while reading non god pot effects from tab list! line: '$line'") + } } } patternEffectsCount.matchMatcher(line) { |