aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2
diff options
context:
space:
mode:
authorCinshay <106889028+Cinshay@users.noreply.github.com>2023-07-05 10:11:57 +0200
committerGitHub <noreply@github.com>2023-07-05 10:11:57 +0200
commit5033eac191909a335c666207ff691e2724ec4c6f (patch)
treee6fa1412b71df94bf6dc561d1d916b8c412037d5 /src/main/java/at/hannibal2
parenta7aaa59273a096f9950246b4053b0cc3235ca9b6 (diff)
downloadskyhanni-5033eac191909a335c666207ff691e2724ec4c6f.tar.gz
skyhanni-5033eac191909a335c666207ff691e2724ec4c6f.tar.bz2
skyhanni-5033eac191909a335c666207ff691e2724ec4c6f.zip
Fixed Kuudra completions not being detected correctly and added support for T4 and T5 kuudra in the reputation helper (#286)
Diffstat (limited to 'src/main/java/at/hannibal2')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/dailykuudra/DailyKuudraBossHelper.kt13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/dailykuudra/DailyKuudraBossHelper.kt b/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/dailykuudra/DailyKuudraBossHelper.kt
index 3bcf0d5b9..289380a81 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/dailykuudra/DailyKuudraBossHelper.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/nether/reputationhelper/dailykuudra/DailyKuudraBossHelper.kt
@@ -19,7 +19,6 @@ import net.minecraftforge.fml.common.eventhandler.SubscribeEvent
class DailyKuudraBossHelper(private val reputationHelper: CrimsonIsleReputationHelper) {
val kuudraTiers = mutableListOf<KuudraTier>()
- private val pattern = " Kuudra's Hollow \\(T(?<tier>.*)\\)".toPattern()
private var kuudraLocation: LorenzVec? = null
private var allKuudraDone = true
@@ -45,11 +44,11 @@ class DailyKuudraBossHelper(private val reputationHelper: CrimsonIsleReputationH
if (!SkyHanniMod.feature.misc.crimsonIsleReputationHelper) return
val message = event.message
- if (message != " §r§6§lKUUDRA DOWN!") return
+ if (!message.contains("KUUDRA DOWN!") || message.contains(":")) return
for (line in ScoreboardData.sidebarLines) {
- pattern.matchMatcher(line) {
- val tier = group("tier").toInt()
+ if(line.contains("Kuudra's") && line.contains("Hollow") && line.contains("(")){
+ val tier = line.substringAfter("(T").substring(0,1).toInt()
val kuudraTier = getByTier(tier)!!
finished(kuudraTier)
return
@@ -68,10 +67,10 @@ class DailyKuudraBossHelper(private val reputationHelper: CrimsonIsleReputationH
fun render(display: MutableList<List<Any>>) {
val done = kuudraTiers.count { it.doneToday }
display.addAsSingletonList("")
- display.addAsSingletonList("§7Daily Kuudra (§e$done§8/§e3 killed§7)")
- if (done != 2) {
+ display.addAsSingletonList("§7Daily Kuudra (§e$done§8/§e5 killed§7)")
+ if (done < 5) {
for (tier in kuudraTiers) {
- val result = if (tier.doneToday) "§7Done" else "§bTodo"
+ val result = if (tier.doneToday) "§aDone" else "§bTodo"
val displayName = tier.getDisplayName()
val displayItem = tier.displayItem
if (displayItem == null) {