Fix Questionable ignoring level check for next MSQ during load screens, thus potentia...
authorLiza Carvelli <liza@carvel.li>
Sun, 9 Mar 2025 21:41:54 +0000 (22:41 +0100)
committerLiza Carvelli <liza@carvel.li>
Sun, 9 Mar 2025 21:41:54 +0000 (22:41 +0100)
Questionable/Functions/QuestFunctions.cs

index fc906e0..f0a41ec 100644 (file)
@@ -291,10 +291,14 @@ internal sealed unsafe class QuestFunctions
         else if (!IsReadyToAcceptQuest(currentQuest))
             return default;
 
+        var currentLevel = _clientState.LocalPlayer?.Level;
+
+        // are we in a loading screen?
+        if (currentLevel == null)
+            return default;
+
         // if we're not at a high enough level to continue, we also ignore it
-        var currentLevel = _clientState.LocalPlayer?.Level ?? 0;
-        if (currentLevel != 0 &&
-            _questRegistry.TryGetQuest(currentQuest, out Quest? quest)
+        if (_questRegistry.TryGetQuest(currentQuest, out Quest? quest)
             && quest.Info.Level > currentLevel)
             return default;