aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/features
diff options
context:
space:
mode:
authorhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-08-23 11:08:20 +0200
committerhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-08-23 11:08:20 +0200
commitccc8cc8b112b48dd6b5d14db33690f4d86c91b9b (patch)
tree5c33d6d11f61183a7e1da4a1613d5435044fe131 /src/main/java/at/hannibal2/skyhanni/features
parentf29d472c4fa93e51207df7c17c350cb032d72417 (diff)
downloadskyhanni-ccc8cc8b112b48dd6b5d14db33690f4d86c91b9b.tar.gz
skyhanni-ccc8cc8b112b48dd6b5d14db33690f4d86c91b9b.tar.bz2
skyhanni-ccc8cc8b112b48dd6b5d14db33690f4d86c91b9b.zip
Fixed anita upgrade detection from inventory
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/features')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/garden/fortuneguide/CaptureFarmingGear.kt8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/garden/fortuneguide/CaptureFarmingGear.kt b/src/main/java/at/hannibal2/skyhanni/features/garden/fortuneguide/CaptureFarmingGear.kt
index 4558174a5..e44071f3e 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/garden/fortuneguide/CaptureFarmingGear.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/garden/fortuneguide/CaptureFarmingGear.kt
@@ -28,7 +28,7 @@ class CaptureFarmingGear {
private val farmingLevelUpPattern = "SKILL LEVEL UP Farming .*➜(?<level>.*)".toPattern()
private val fortuneUpgradePattern = "You claimed the Garden Farming Fortune (?<level>.*) upgrade!".toPattern()
private val anitaBuffPattern = "You tiered up the Extra Farming Drops upgrade to [+](?<level>.*)%!".toPattern()
- private val anitaMenuPattern = "You have: [+](?<level>.*)%".toPattern()
+ private val anitaMenuPattern = "§7You have: §6\\+(?<level>.*)☘ Farming Fortune".toPattern()
private val lotusUpgradePattern = "Lotus (?<piece>.*) upgraded to [+].*☘!".toPattern()
private val petLevelUpPattern = "Your (?<pet>.*) leveled up to level .*!".toPattern()
@@ -174,11 +174,11 @@ class CaptureFarmingGear {
if (event.inventoryName.contains("Anita")) {
var level = -1
for ((_, item) in event.inventoryItems) {
- if (item.displayName.contains("Extra Farming Drops")) {
+ if (item.displayName.contains("Extra Farming Fortune")) {
level = 0
for (line in item.getLore()) {
- anitaMenuPattern.matchMatcher(line.removeColor()) {
- level = group("level").toInt() / 2
+ anitaMenuPattern.matchMatcher(line) {
+ level = group("level").toInt() / 4
}
}
}