v1.6.3-unreleased: Sunstrider zone fixes, QuestieLearner icon preservation, migration, and Busted test suite

Code changes (13 files, +916/-171):
- ZoneDB integration: GetZoneId() converts uiMapId→areaId via ZoneDB reverse lookup
- MIN_CONFIDENCE_PINS reduced to 1 for Ascension (incomplete NPC DBs)
- QuestieLearner icon preservation: objective Icon passed to RegisterObjectiveTooltip
- InjectLearnedData zone migration: converts old uiMapId spawn keys to areaId
- areaId passed through all LearnNPC call sites (OnMouseoverUnit, OnQuestDetail,
  OnQuestComplete, OnQuestAccepted, OnQuestTurnedIn, OnGossipShow)
- Compat/Compat.lua: C_Map.GetPlayerMapPosition UiMapData support
- Compat/HBD.lua: Sunstrider mapData aliases and fallback loading
- Sunstrider arrow fix (QuestieArrow.lua), resolved pin rendering (QuestieMap.lua)
- _MergeOverride helper for string/numeric key compatibility
- Northshire Valley UiMapData registration

Testing infrastructure:
- .busted config pointing to tests/ directory
- Tests/wow_api_mock.lua: WoW API mocks (ZoneDB, C_Map, QuestLogCache, etc.)
- Tests/QuestieLearner_spec.lua: 12 tests covering coordinate scaling, spell cast
  learning, zone migration (NPC/objects), icon preservation, settings defaults,
  and LearnNPC spawn zone tracking
- selene.toml + wow_classic.yml: linter configuration

Documentation:
- Makefile with test/lint/ci targets
- sunstrider-coordinate-collection.md: coordinate data reference
- sunstrider-pin-fix.md: root cause analysis and fix documentation
This commit is contained in:
Xurkon
2026-05-16 07:32:47 -05:00
parent 306fb2ac89
commit bf6ecaedbe
22 changed files with 2218 additions and 179 deletions
+28 -1
View File
@@ -111,6 +111,21 @@ end
---@return table<{x: number, y: number}>, number | nil
function QuestieCoords.GetPlayerMapPosition()
-- If the world map is open, use the map currently being displayed instead of
-- GetBestMapForUnit("player"). On legacy clients our compat shim may call
-- SetMapToCurrentZone()/SetMapByID() while resolving the player's map, which
-- fights the open world map and causes the title/coordinate text to flicker.
if WorldMapFrame and WorldMapFrame:IsVisible() then
local currentMapId = WorldMapFrame:GetMapID()
if currentMapId and GetPlayerMapPosition then
local pos = GetPlayerMapPosition(currentMapId, "player")
if pos and pos.x and pos.y then
pos.uiMapID = currentMapId
return pos, currentMapId
end
end
end
local mapID = GetBestMapForUnit("player")
if (not mapID) then
return nil, nil
@@ -142,7 +157,19 @@ function QuestieCoords:ResetMinimapText()
end
function QuestieCoords:ResetMapText()
GetMapTitleText():SetText(WORLD_MAP);
local mapTitleText = GetMapTitleText()
if not mapTitleText then return end
local currentMapId = WorldMapFrame and WorldMapFrame.GetMapID and WorldMapFrame:GetMapID()
if currentMapId then
local info = C_Map.GetMapInfo(currentMapId)
if info and info.name then
mapTitleText:SetText(info.name)
return
end
end
mapTitleText:SetText(WORLD_MAP);
end
function QuestieCoords:ResetMiniWorldMapText()