From 768d6e80131ade55edfeba769f7cdb0d24fd2ae3 Mon Sep 17 00:00:00 2001 From: martimavocado <39881008+martimavocado@users.noreply.github.com> Date: Tue, 19 Mar 2024 08:40:52 +0000 Subject: Fix: Party Finder "Mark Missing Class" highlighting too much (#1211) --- .../hannibal2/skyhanni/features/dungeon/DungeonFinderFeatures.kt | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'src/main/java/at/hannibal2/skyhanni') diff --git a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonFinderFeatures.kt b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonFinderFeatures.kt index 7037743ef..d8948d664 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonFinderFeatures.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/dungeon/DungeonFinderFeatures.kt @@ -149,6 +149,8 @@ class DungeonFinderFeatures { val chestName = InventoryUtils.openInventoryName() if (chestName != "Party Finder") return + val allowedSlots = (10..34).filter { it !in listOf(17, 18, 26, 27) } + if (event.slot.slotNumber !in allowedSlots) return val stack = event.itemStack @@ -165,9 +167,14 @@ class DungeonFinderFeatures { } if (!config.showMissingClasses) return if (stack.getLore().firstOrNull()?.removeColor()?.startsWith("Dungeon:") == false) return - if (classNames.contains(selectedClass)) selectedClass = "§a${selectedClass}§7" + var uncoloredSelectedClass = "" + if (classNames.contains(selectedClass)) { + uncoloredSelectedClass = selectedClass + selectedClass = "§a${selectedClass}§7" + } event.toolTip.add("") event.toolTip.add("§cMissing: §7" + classNames.createCommaSeparatedList()) + if (uncoloredSelectedClass.isNotEmpty()) selectedClass = uncoloredSelectedClass } @SubscribeEvent -- cgit