From f90096bad0e0210cfba8bc1fe1113ecb296aa6da Mon Sep 17 00:00:00 2001 From: Empa <42304516+ItsEmpa@users.noreply.github.com> Date: Fri, 5 Apr 2024 18:44:48 +0200 Subject: Fix: Not showing MP when no power (#1366) --- src/main/java/at/hannibal2/skyhanni/data/MaxwellAPI.kt | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/main/java/at/hannibal2') diff --git a/src/main/java/at/hannibal2/skyhanni/data/MaxwellAPI.kt b/src/main/java/at/hannibal2/skyhanni/data/MaxwellAPI.kt index 414540ea5..85b0e8ec7 100644 --- a/src/main/java/at/hannibal2/skyhanni/data/MaxwellAPI.kt +++ b/src/main/java/at/hannibal2/skyhanni/data/MaxwellAPI.kt @@ -100,6 +100,10 @@ object MaxwellAPI { "gui.selectedpower", "§aPower is selected!" ) + private val noPowerSelectedPattern by group.pattern( + "gui.noselectedpower", + "(?:§.)*Visit Maxwell in the Hub to learn" + ) private val accessoryBagStack by group.pattern( "stack.accessorybag", "§.Accessory Bag" @@ -242,6 +246,8 @@ object MaxwellAPI { return } + if (noPowerSelectedPattern.matches(line)) currentPower = getPowerByNameOrNull("No Power") + inventoryMPPattern.matchMatcher(line) { // MagicalPower is boosted in catacombs if (IslandType.CATACOMBS.isInIsland()) return@matchMatcher -- cgit