From a0f3a1e0207c2bbd87ece1219f6bcf0a54a9bb42 Mon Sep 17 00:00:00 2001 From: Xurkon Date: Mon, 4 May 2026 19:57:43 -0500 Subject: [PATCH] v1.6.1: Fix map icon completion persistence after objective fulfillment - SetObjectivesDirty: Add missing loop to reset isUpdated on SpecialObjectives - PopulateObjective: Add completion guard for objectives without Update fn - Bump version to 1.6.1 across TOC and changelogs --- CHANGELOG.md | 8 ++++++++ Modules/Quest/QuestieQuest.lua | 18 +++++++++++++++++- Questie-X.toc | 2 +- docs/changelog.html | 14 +++++++++++++- 4 files changed, 39 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 81cd1e7..c74fb90 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,13 @@ # Changelog +## v1.6.1 (2026-05-04) + +### Bug Fixes + +- **[Fix — Map Icon Completion]** Resolved a bug where quest objective icons (map pins and minimap markers) persisted on the world map and minimap after objectives were fulfilled, only disappearing after speaking to the quest giver to complete the quest. + - **SpecialObjectives Dirty Flag**: Added a missing loop in `SetObjectivesDirty` to reset `isUpdated = false` on `quest.SpecialObjectives` alongside the existing `quest.Objectives` loop. Previously, special objectives (e.g. demonic runestones, portal-closing mechanics) would skip the `ObjectiveUpdate` early-exit guard because their `isUpdated` flag was never cleared, preventing `objective.Completed` from being set to `true` and leaving map icons on-screen indefinitely. + - **Completion Guard in PopulateObjective**: Added a defensive check in `PopulateObjective` so that objectives without an `Update` function still unload their spawned icons if `objective.Completed` or `quest.isComplete` is already `true` from a prior update cycle. + ## Session 34 (2026-05-02) ### Maintenance diff --git a/Modules/Quest/QuestieQuest.lua b/Modules/Quest/QuestieQuest.lua index 841f669..ccf82f3 100644 --- a/Modules/Quest/QuestieQuest.lua +++ b/Modules/Quest/QuestieQuest.lua @@ -802,6 +802,15 @@ function QuestieQuest:SetObjectivesDirty(questId) objective.isUpdated = false objKey, objective = next(quest.Objectives, objKey) end + -- Also dirty SpecialObjectives (e.g. demonic runestones, portal-closing mechanics). + -- Without this, ObjectiveUpdate's isUpdated early-exit prevents objective.Completed + -- from being set to true, so _UnloadAlreadySpawnedIcons is never reached and icons + -- linger on the map/minimap after the objectives are fulfilled. + local soKey, sObjective = next(quest.SpecialObjectives or {}) + while soKey do + sObjective.isUpdated = false + soKey, sObjective = next(quest.SpecialObjectives, soKey) + end end end @@ -1336,7 +1345,14 @@ function QuestieQuest:PopulateObjective(quest, objectiveIndex, objective, blockI Questie:Debug(Questie.DEBUG_INFO, "[QuestieQuest:PopulateObjective]", objective.Description) if (not objective.Update) then - Questie:Debug(Questie.DEBUG_INFO, "[QuestieQuest:PopulateObjective] - Quest is already updated. --> Exiting!") + -- No Update function means static/pre-populated objective. + -- Still check completion state so icons are removed if this objective was + -- already marked complete from a previous update cycle. + if objective.Completed or quest.isComplete then + Questie:Debug(Questie.DEBUG_INFO, + "[QuestieQuest:PopulateObjective] - No Update fn but objective is complete, unloading icons.") + _UnloadAlreadySpawnedIcons(objective) + end return end diff --git a/Questie-X.toc b/Questie-X.toc index 6740784..73cba8b 100644 --- a/Questie-X.toc +++ b/Questie-X.toc @@ -11,7 +11,7 @@ ## Notes-esES: Ayundante de misión ## Notes-ptBR: Ajudante de missão ## Notes-frFR: Assistant de quête -## Version: 1.6.0 +## Version: 1.6.1 ## OptionalDeps: Ace3, CallbackHandler-1.0, HereBeDragons, LibDataBroker-1.1, LibDBIcon-1.0, LibSharedMedia-3.0, LibStub, LibUIDropDownMenu, Questie-X-WotLKDB, Questie-X-ClassicDB, Questie-X-TBCDB, Questie-X-TurtleDB, Questie-X-AscensionDB, Questie-X-EbonholdDB ## SavedVariables: QuestieConfig, QuestieLearnerDB, QuestieCacheDB, QuestieJourneyDB ## SavedVariablesPerCharacter: QuestieConfigCharacter diff --git a/docs/changelog.html b/docs/changelog.html index 3f14f21..ca10057 100644 --- a/docs/changelog.html +++ b/docs/changelog.html @@ -169,13 +169,25 @@

Questie-X Documentation

Complete history of changes, fixes, and additions.

- Version: v1.6.0 + Version: v1.6.1 ← Back to Documentation
+

v1.6.1 — Map Icon Completion Fix

+ + +
+

v1.6.0 — Map Search & Data Integrity