aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormartimavocado <39881008+martimavocado@users.noreply.github.com>2024-06-01 10:56:39 +0100
committerGitHub <noreply@github.com>2024-06-01 11:56:39 +0200
commit861892b7353f32bad70fa1a9248d8c717e813a53 (patch)
tree5ef645c330dbdd76e44985c7234136d500aac8fc /src
parenta5af0b8e09d46d445c610d5eaf90b81739652a47 (diff)
downloadskyhanni-861892b7353f32bad70fa1a9248d8c717e813a53.tar.gz
skyhanni-861892b7353f32bad70fa1a9248d8c717e813a53.tar.bz2
skyhanni-861892b7353f32bad70fa1a9248d8c717e813a53.zip
Improvement: Move all SkyMall message hiding to the same toggle (#1971)
Diffstat (limited to 'src')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/chat/ChatFilter.kt10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/chat/ChatFilter.kt b/src/main/java/at/hannibal2/skyhanni/features/chat/ChatFilter.kt
index 15f3135e9..1b4ae762c 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/chat/ChatFilter.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/chat/ChatFilter.kt
@@ -266,12 +266,15 @@ class ChatFilter {
"§6§lGOOD CATCH! §r§bYou found a §r§fLight Bait§r§b.",
"§6§lGOOD CATCH! §r§bYou found a §r§aHot Bait§r§b.",
"§6§lGOOD CATCH! §r§bYou found a §r§fSpooky Bait§r§b.",
- "§bNew day! §r§eYour §r§2Sky Mall §r§ebuff changed!",
- "§8§oYou can disable this messaging by toggling Sky Mall in your /hotm!",
"§e[NPC] Jacob§f: §rMy contest has started!",
"§eObtain a §r§6Booster Cookie §r§efrom the community shop in the hub!",
)
+ private val skymallMessages = listOf(
+ "§bNew day! §r§eYour §r§2Sky Mall §r§ebuff changed!",
+ "§8§oYou can disable this messaging by toggling Sky Mall in your /hotm!",
+ )
+
/**
* REGEX-TEST: §e[NPC] Jacob§f: §rYour §9Anita's Talisman §fis giving you §6+25☘ Carrot Fortune §fduring the contest!
*/
@@ -443,6 +446,7 @@ class ChatFilter {
"powder_mining" to powderMiningMessages,
"fire_sale" to fireSaleMessages,
"event" to eventMessage,
+ "skymall" to skymallMessages,
)
private val messagesContainsMap: Map<String, List<String>> = mapOf(
"lobby" to lobbyMessagesContains,
@@ -484,7 +488,7 @@ class ChatFilter {
config.factoryUpgrade && message.isPresent("factory_upgrade") -> "factory_upgrade"
config.sacrifice && message.isPresent("sacrifice") -> "sacrifice"
generalConfig.hideJacob && !GardenAPI.inGarden() && anitaFortunePattern.matches(message) -> "jacob_event"
- generalConfig.hideSkyMall && !LorenzUtils.inMiningIsland() && skymallPerkPattern.matches(message) -> "skymall"
+ generalConfig.hideSkyMall && !LorenzUtils.inMiningIsland() && (skymallPerkPattern.matches(message) || message.isPresent("skymall")) -> "skymall"
dungeonConfig.rareDrops && message.isPresent("rare_drops") -> "rare_drops"
dungeonConfig.soloClass && DungeonAPI.inDungeon() && message.isPresent("solo_class") -> "solo_class"
dungeonConfig.soloStats && DungeonAPI.inDungeon() && message.isPresent("solo_stats") -> "solo_stats"