From 4289e8a2148555e06fcef695a8d89d386067264e Mon Sep 17 00:00:00 2001 From: hannibal2 <24389977+hannibal00212@users.noreply.github.com> Date: Sun, 1 Oct 2023 15:08:53 +0200 Subject: Fixed auto slayer warning showing wrongly --- .../at/hannibal2/skyhanni/features/slayer/SlayerQuestWarning.kt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/main/java/at/hannibal2/skyhanni/features/slayer/SlayerQuestWarning.kt b/src/main/java/at/hannibal2/skyhanni/features/slayer/SlayerQuestWarning.kt index 1bd05208d..9fd8c5887 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/slayer/SlayerQuestWarning.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/slayer/SlayerQuestWarning.kt @@ -23,6 +23,7 @@ class SlayerQuestWarning { private var lastWarning = 0L private var currentReason = "" private var dirtySidebar = false + private var hasAutoSlayer = false private var activeSlayer: SlayerType? = null //TODO add check if player has clicked on an item, before mobs around you gets damage @@ -39,6 +40,7 @@ class SlayerQuestWarning { } if (message == " §r§5§lSLAYER QUEST STARTED!") { needSlayerQuest = false + hasAutoSlayer = true dirtySidebar = true } @@ -106,7 +108,10 @@ class SlayerQuestWarning { dirtySidebar = false if (slayerQuest && !needSlayerQuest) { if (bossSlain) { - needNewQuest("You have no Auto-Slayer active!") + if (!hasAutoSlayer) { + needNewQuest("You have no Auto-Slayer active!") + hasAutoSlayer = false + } } else if (slayBoss) { needNewQuest("You probably switched the server during an active boss and now hypixel doesn't know what to do.") } -- cgit