diff options
author | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-03-03 22:57:51 +0100 |
---|---|---|
committer | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-03-03 22:57:51 +0100 |
commit | a04330a2c37bd3b12ee50281bfe9ae6008f3f65b (patch) | |
tree | 7695b7eb0fe5ae6e9254f924f4f456c02e320192 /src/main | |
parent | dc66fe1509bde7dc3d7c786ff6fdb624c9150f8c (diff) | |
download | skyhanni-a04330a2c37bd3b12ee50281bfe9ae6008f3f65b.tar.gz skyhanni-a04330a2c37bd3b12ee50281bfe9ae6008f3f65b.tar.bz2 skyhanni-a04330a2c37bd3b12ee50281bfe9ae6008f3f65b.zip |
Fixed bingo goal completed chat message does not auto update the bingo card.
Diffstat (limited to 'src/main')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt b/src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt index eef8ec213..f88ec4b59 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/bingo/BingoCardDisplay.kt @@ -28,6 +28,7 @@ class BingoCardDisplay { private var tick = 0 private val display = mutableListOf<String>() private val config get() = SkyHanniMod.feature.bingo + private val goalCompletePattern = Pattern.compile("§6§lBINGO GOAL COMPLETE! §r§e(.*)") init { update() @@ -174,18 +175,9 @@ class BingoCardDisplay { if (!LorenzUtils.isBingoProfile) return if (!config.cardDisplay) return - val message = event.message - //§6§lBINGO GOAL COMPLETE! §r§eRaw Salmon Collector - val pattern = Pattern.compile("§6§lBINGO GOAL COMPLETE! §r§e(.*)") - - val matcher = pattern.matcher(message) - + val matcher = goalCompletePattern.matcher(event.message) if (matcher.matches()) { - val name = matcher.group(0) - println("name: '$name'") - for (goal in personalGoals) { - println("goal: '" + goal.displayName + "'") - } + val name = matcher.group(1) personalGoals.filter { it.displayName == name } .forEach { it.done = true |