aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/features
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/features')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/misc/NonGodPotEffectDisplay.kt19
1 files changed, 18 insertions, 1 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 af52945d6..b95f68885 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/misc/NonGodPotEffectDisplay.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/misc/NonGodPotEffectDisplay.kt
@@ -57,6 +57,11 @@ class NonGodPotEffectDisplay {
DEEP_TERROR("§4Deepterror", true),
GREAT_SPOOK("§fGreat Spook I", inventoryItemName = "§fGreat Spook Potion"),
+
+ HARVEST_HARBINGER("§6Harvest Harbinger V"),
+
+ PEST_REPELLENT("§6Pest Repellent I§r"),
+ PEST_REPELLENT_MAX("§6Pest Repellent II"),
;
}
@@ -92,6 +97,18 @@ class NonGodPotEffectDisplay {
update()
}
+ if (event.message == "§a§lBUFF! §fYou have gained §r§6Harvest Harbinger V§r§f! Press TAB or type /effects to view your active effects!") {
+ effectDuration[NonGodPotEffect.HARVEST_HARBINGER] = Timer(25.minutes)
+ update()
+ }
+
+ if (event.message == "§a§lYUM! §r§6Pests §r§7will now spawn §r§a2x §r§7less while you break crops for the next §r§a60m§r§7!") {
+ effectDuration[NonGodPotEffect.PEST_REPELLENT] = Timer(1.hours)
+ }
+
+ if (event.message == "§a§lYUM! §r§6Pests §r§7will now spawn §r§a4x §r§7less while you break crops for the next §r§a60m§r§7!") {
+ effectDuration[NonGodPotEffect.PEST_REPELLENT_MAX] = Timer(1.hours)
+ }
if (event.message == "§e[NPC] §6King Yolkar§f: §rThese eggs will help me stomach my pain.") {
effectDuration[NonGodPotEffect.GOBLIN] = Timer(20.minutes)
@@ -197,7 +214,7 @@ class NonGodPotEffectDisplay {
for (line in lines) {
for (effect in NonGodPotEffect.entries) {
val tabListName = effect.tabListName
- if (line.startsWith(tabListName)) {
+ if ("$line§r".startsWith(tabListName)) {
val string = line.substring(tabListName.length)
try {
val duration = TimeUtils.getMillis(string.split("§f")[1])