aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/features
diff options
context:
space:
mode:
authoralexia <me@alexia.lol>2023-12-23 02:33:51 +0100
committerGitHub <noreply@github.com>2023-12-23 02:33:51 +0100
commit19b6353591788bf0c34915da1f5e0dbcde72985b (patch)
treee1db5d7c93cb8fe152c8a56e50333dbd6abb4875 /src/main/java/at/hannibal2/skyhanni/features
parentfc063242252fb6de383262a5921888ff7247867b (diff)
downloadskyhanni-19b6353591788bf0c34915da1f5e0dbcde72985b.tar.gz
skyhanni-19b6353591788bf0c34915da1f5e0dbcde72985b.tar.bz2
skyhanni-19b6353591788bf0c34915da1f5e0dbcde72985b.zip
Add Harvest Harbinger and Pest Repellent non-god effects (#817)
Added Harvest Harbinger and Pest Repellent non-god effects. #817
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])