Skip to content

Commit

Permalink
Added "fire sale starting soon" message to fire sale chat hider.
Browse files Browse the repository at this point in the history
  • Loading branch information
hannibal002 committed Dec 8, 2023
1 parent 993253d commit 6aaf8e7
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,8 @@ class ChatFilter {
private val fireSalePatterns = listOf(
"§c♨ §eFire Sales for .* §eare starting soon!".toPattern(),
"§c {3}♨ .* Skin §e\\(.* §eleft\\)§c".toPattern(),
"§c♨ §eVisit the Community Shop in the next §c.* §eto grab yours! §a§l\\[WARP]".toPattern()
"§c♨ §eVisit the Community Shop in the next §c.* §eto grab yours! §a§l\\[WARP]".toPattern(),
"§c♨ §eA Fire Sale for .* §eis starting soon!".toPattern(),
)
private val powderMiningMessages = listOf(
"§aYou uncovered a treasure chest!",
Expand Down Expand Up @@ -431,8 +432,8 @@ class ChatFilter {
*/
private fun String.isPresent(key: String) = this in (messagesMap[key] ?: emptyList()) ||
(patternsMap[key] ?: emptyList()).any { it.matches(this) } ||
(messagesContainsMap[key] ?: emptyList()).any { this.contains(it) } ||
(messagesStartsWithMap[key] ?: emptyList()).any { this.startsWith(it) }
(messagesContainsMap[key] ?: emptyList()).any { this.contains(it) } ||
(messagesStartsWithMap[key] ?: emptyList()).any { this.startsWith(it) }

@SubscribeEvent
fun onConfigFix(event: ConfigUpdaterMigrator.ConfigFixEvent) {
Expand Down

0 comments on commit 6aaf8e7

Please sign in to comment.