diff --git a/CHANGELOG.md b/CHANGELOG.md index d0a9d09..1298ec0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,19 @@ # Changelog +## [Unreleased] + +### Bug Fixes + +- **[Fix — Tooltip NPC/Object Type Guard]** Resolved a crash in `QuestieTooltips` when hovering over NPC or object tooltip keys (`m_`, `o_`) where `learnedNpc[10]` or `learnedObj[10]` was unexpectedly a string instead of a table. + - **Root Cause**: `InsertMissingQuestIds` in the WotLKDB corrections files writes directly to `QuestieDB.questData[questId]` but `questData` is stored as a loadable Lua string on Ascension. When code later tried to index into that string as a table, it threw `attempt to index field 'questData' (a string value)`. + - **Fix**: Added `if type(objList) ~= "table" then break end` guard in both `m_/NPC` and `o_/object` iteration paths in `Tooltip.lua` before iterating `learnedNpc[10]` / `learnedObj[10]`. +- **[Fix — InsertMissingQuestIds String Guard]** Added `if type(QuestieDB.questData) ~= "table" then return end` guard at the start of `InsertMissingQuestIds()` in both `tbcQuestFixes.lua` and `wotlkQuestFixes.lua`. Prevents the function from writing to `questData` while it is still an uncompiled string during early loader initialization. +- **[Fix — Sunstrider Isle Arrow / Zone Override]** Resolved the quest arrow not appearing on Sunstrider Isle (Ascension's starting zone) when the world map is closed. + - **Root Cause**: `C_Map.GetBestMapForUnit("player")` returns `946` (ghost/loading map uiMapId) instead of `1241` (Sunstrider Isle's real uiMapId) when the world map is closed. `ZoneDB:GetAreaIdByUiMapId(946)` had no override, causing `GetCurrentZoneId()` to return `946` instead of `3430` (Sunstrider Isle's areaId). This broke target zone filtering in `_CollectObjective` and caused `HBD:GetWorldCoordinatesFromZone` to return `0,0` (no world coord data for map 946). + - **Fix — zoneDB.lua**: Added `[946] = 3430` to `UiMapIdOverrides` so `GetAreaIdByUiMapId(946)` resolves to the real Sunstrider Isle areaId even when the game returns the ghost map uiMapId. Also added `[1241] = 3430` to handle the case where `GetBestMapForUnit` returns the correct Sunstrider Isle uiMapId directly. + - **Fix — QuestieArrow.lua**: Updated `UpdateNearestTargets` fallback chain to use `QuestiePlayer:GetCurrentUiMapId()` (backed by `C_Map.GetBestMapForUnit`) for player position. When that returns an invalid/ghost map (946/947/0), it falls back to a `ZoneDB` lookup via the actual `zoneId`. This ensures the arrow gets real world coordinates via `C_Map.GetPlayerMapPosition` + `HBD:GetWorldCoordinatesFromZone` regardless of map open/closed state. + - **Debug Output**: Added per-frame debug output (respecting `debugArrow` profile setting) showing `frameShown`, `target.title`, player coordinates, and uiMapId values for troubleshooting. + ## v1.6.1 (2026-05-04) ### Bug Fixes diff --git a/README.md b/README.md index be6fd70..44b19ac 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ Questie-X Logo -![Version](https://img.shields.io/badge/Questie--X-v1.6.0-blue.svg?style=for-the-badge) +![Version](https://img.shields.io/badge/Questie--X-v1.6.2-blue.svg?style=for-the-badge) [![Downloads](https://img.shields.io/github/downloads/Xurkon/Questie-X/total?style=for-the-badge&color=e67e22)](https://github.com/Xurkon/Questie-X/releases) [![Documentation](https://img.shields.io/badge/Documentation-View%20Docs-58a6ff?style=for-the-badge)](https://xurkon.github.io/Questie-X/) [![Patreon](https://img.shields.io/badge/Patreon-F96854?style=for-the-badge&logo=patreon&logoColor=white)](https://www.patreon.com/Xurkon) @@ -211,6 +211,7 @@ If your server uses non-standard map data, enable **Options → Advanced → Use - Fixed `attempt to concatenate nil` error when a quest starter or finisher has no name in the database. - Added support for `killcredit` and `spell` objective types in `MapIconTooltip`. - Tooltip now displays if an NPC drops an item that starts a quest. +- Fixed tooltip crash when hovering over NPC/object keys (`m_`, `o_`) where `learnedNpc[10]` or `learnedObj[10]` is unexpectedly a string instead of a table. Added type guard before iterating the objective list array. ### Quest Arrow @@ -218,6 +219,7 @@ If your server uses non-standard map data, enable **Options → Advanced → Use - Fixed arrow pointing to previously completed objective locations instead of the current finisher. - Fixed nil error in `_CollectObjective` when processing incomplete quests. - Fixed arrow direction for quests that require speaking to an NPC as a prerequisite step. +- **Sunstrider Isle (Ascension starting zone)**: Resolved arrow not appearing when the world map is closed. `C_Map.GetBestMapForUnit("player")` returns a ghost/loading map uiMapId (946) instead of Sunstrider Isle's real uiMapId (1241) with the map closed. Added `UiMapIdOverrides` entries for both 946 and 1241 mapping to Sunstrider Isle's areaId (3430). Updated the arrow's `UpdateNearestTargets` fallback to use `ZoneDB` lookups when the ghost map is detected, ensuring the arrow gets real world coordinates regardless of map state. ### Nameplates diff --git a/docs/changelog.html b/docs/changelog.html index b198945..4e8fd2f 100644 --- a/docs/changelog.html +++ b/docs/changelog.html @@ -176,6 +176,27 @@
+

[Unreleased] — Sunstrider Isle Arrow, Tooltip Guard, QuestData String Safety

+
    +
  • [Fix — Tooltip NPC/Object Type Guard] Resolved a crash in QuestieTooltips when hovering over NPC or object tooltip keys (m_<id>, o_<id>) where learnedNpc[10] or learnedObj[10] was unexpectedly a string instead of a table. +
      +
    • Root Cause: InsertMissingQuestIds in the WotLKDB corrections files writes directly to QuestieDB.questData[questId] but questData is stored as a loadable Lua string on Ascension. When code later tried to index into that string as a table, it threw attempt to index field 'questData' (a string value).
    • +
    • Fix: Added if type(objList) ~= "table" then break end guard in both m_/NPC and o_/object iteration paths in Tooltip.lua before iterating learnedNpc[10] / learnedObj[10].
    • +
    +
  • +
  • [Fix — InsertMissingQuestIds String Guard] Added if type(QuestieDB.questData) ~= "table" then return end guard at the start of InsertMissingQuestIds() in both tbcQuestFixes.lua and wotlkQuestFixes.lua. Prevents the function from writing to questData while it is still an uncompiled string during early loader initialization.
  • +
  • [Fix — Sunstrider Isle Arrow / Zone Override] Resolved the quest arrow not appearing on Sunstrider Isle (Ascension's starting zone) when the world map is closed. +
      +
    • Root Cause: C_Map.GetBestMapForUnit("player") returns 946 (ghost/loading map uiMapId) instead of 1241 (Sunstrider Isle's real uiMapId) when the world map is closed. ZoneDB:GetAreaIdByUiMapId(946) had no override, causing GetCurrentZoneId() to return 946 instead of 3430 (Sunstrider Isle's areaId). This broke target zone filtering in _CollectObjective and caused HBD:GetWorldCoordinatesFromZone to return 0,0 (no world coord data for map 946).
    • +
    • Fix — zoneDB.lua: Added [946] = 3430 and [1241] = 3430 to UiMapIdOverrides so GetAreaIdByUiMapId always resolves to the real Sunstrider Isle areaId regardless of which ghost or real uiMapId the game returns.
    • +
    • Fix — QuestieArrow.lua: Updated UpdateNearestTargets fallback chain to use QuestiePlayer:GetCurrentUiMapId() for player position. When that returns an invalid/ghost map (946/947/0), it falls back to a ZoneDB lookup via the actual zoneId. Ensures the arrow gets real world coordinates via C_Map.GetPlayerMapPosition + HBD:GetWorldCoordinatesFromZone regardless of map open/closed state.
    • +
    • Debug Output: Added per-frame debug output (respecting debugArrow profile setting) showing frameShown, target.title, player coordinates, and uiMapId values.
    • +
    +
  • +
+ +
+

v1.6.1 — Map Icon Completion Fix

  • [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. diff --git a/docs/index.html b/docs/index.html index 1f576f6..587c875 100644 --- a/docs/index.html +++ b/docs/index.html @@ -210,7 +210,7 @@ Questie-X Logo

    A universal WoW quest-helper with a plugin architecture for any private server.

    - Version: v1.6.0 + Version: v1.6.2 View Changelog