Commit Graph

331 Commits

Author SHA1 Message Date
Xurkon a525813f12 fix(learner): restore learned spawns under native uiMapId, not areaId
Follow-up to da5546f: the previous restore read the POST-migration data[7]
keys and ran them through NormalizeSpawnZoneKey. On Sunstrider that round-
tripped uiMapId 1241 -> parent areaId 3430 -> Eversong map 1941, placing
learner pins in the wrong (NE) corner of the map.

Now snapshot each NPC's [7] spawns in their NATIVE uiMapId space BEFORE the
uiMapId->areaId migration runs, and restore from that snapshot with no key
conversion. This keys the override exactly like the live _MergeSpawnEvidence
kill path (e.g. 1241 for Sunstrider), so pins render on the correct map and
HBD isSameZoneSpace handles Eversong<->Sunstrider visibility. Still gated by
IsAscensionProtected. Regression test extended to assert spawns land on 1241
and NOT 1941/3430/3431.
2026-06-08 17:36:35 -05:00
Xurkon 6634074096 docs(learner): add regression-guard note at NPC spawn [7] strip
Document why stripping [7] in InjectLearnedData is only safe because the
guarded restore block below re-merges saved spawns (normalized to uiMapId).
Prevents re-introducing bug 7ce0cdc (learner quests losing pins on /reload
until the mob is re-killed).
2026-06-08 16:56:50 -05:00
Xurkon da5546fde0 fix(learner): restore persisted NPC spawns into override on load
InjectLearnedData stripped each learned NPC's spawn field [7] when injecting
into npcDataOverrides (CopyWithoutField(data,7) / k~=7), deferring to
_MergeSpawnEvidence. That promoter only runs on live kill evidence, so spawns
learned in a prior session never returned to the queryable DB on /reload, and
a freshly accepted quest (8325 -> Mana Wyrm 15274 on Sunstrider) had no pins
until the mob was re-killed.

Re-merge the saved [7] spawns into the override at injection time, normalized
to the canonical uiMapId via NormalizeSpawnZoneKey (so an areaId left by the
uiMapId->areaId migration, e.g. 3431/3430, maps back to 1241 for the renderer/
HBD), deep-merged with InsertIfNewBucket, and gated by IsAscensionProtected so
curated AscensionDB coords are never overwritten (always restored in learner
mode; in auto mode only non-curated NPCs). Regression from 7ce0cdc.
2026-06-08 16:51:58 -05:00
Xurkon 700445c248 fix(options): use {} not { ... } for tab tables
Five Options files seeded their tab tables with { ... } instead of {}.
At chunk scope WoW passes ... = (addonName, addonTable), so each table
got two stray junk entries instead of being empty; { ... } is also a
strict Lua 5.0 parse error. Fixed QuestieOptions.tabs and the Arrow,
General, Keybinds, and Tracker tab tables. Cherry-picked from
phase2-lua50-sweep (the only version-independent fix in that branch).
2026-06-08 16:24:46 -05:00
Xurkon d92ae93870 fix(learner): seed objective pins on accept; handle monster objectives
OnQuestAccepted now seeds objective pins directly from the SavedVariables
learner payload (objIndex) on accept in learner mode, instead of waiting
for quest-log text sync — so quests like 8325 spawn pins immediately when
the objective mapping already exists. The accept-time ID lookup is widened
from killcredit to also cover monster objectives, and falls back to
objData.Id when no IdList is present.
2026-06-08 08:00:15 -05:00
Xurkon acc829ebba feat(tooltip): add data-source attribution line to tooltips
Objective tooltips (Tooltip.lua) and world-map icon tooltips
(MapIconTooltip.lua) now append a greyed-out 'Source:' line listing the
data origin: Static DB or Learner per the active data-source mode, plus
Comms when remote player data exists for the key. Also corrects an
internal QuestieDB:GetQuest colon call to the dot form QuestieDB.GetQuest.
2026-06-08 07:59:24 -05:00
Xurkon 79e877f4c9 feat(tooltip): always show Item ID and surface item-starts-quest line
AddItemDataToTooltip no longer gates the Item ID line on the item having
a registered quest-objective tooltip, so the ID shows for every item hover
when enabled (matching NPC/Object behavior). Switched to self:AddDoubleLine
so the line lands on the frame that fired OnTooltipSetItem (e.g. ItemRefTooltip
for chat links). Also surfaces a 'Drops a quest !' line with the colored quest
title when the item has a non-zero startQuest and the player lacks the quest,
read from QueryItemSingle at hover time.
2026-06-08 07:58:58 -05:00
Xurkon dc30858504 chore: untrack Tests/ and stray Modules spec file (dev-only)
Tests are for local dev only. .gitignore already excludes Tests/ and
Modules/*_spec.lua from new adds, but the files were still tracked from
prior commits. Untrack them with --cached so the working copies stay
on disk for development but no longer ship in the live repo.
2026-06-07 08:50:20 -05:00
Xurkon 78aefa4af8 perf: skip TestGameCache wait on clustering-only redraws
- SmoothReset now accepts { skipCacheTest = true } to short-circuit the game cache wait and draw-queue drain
- ClusterRedraw passes the flag so icon-cluster and dense-pin-clustering sliders redraw immediately
- QuestieOptionsAdvanced wires the spawn-pin-dedup-radius slider directly to ClusterRedraw instead of the delayed SmoothReset path
2026-06-07 08:42:40 -05:00
Xurkon 5b576911d7 fix: tooltip flicker, learner quest field mapping, secondary tooltip style
- QuestieLib.GetColoredQuestName now nil-guards QuestieDB.GetQuest() before reading .isComplete
- TooltipHandler.AddItemDataToTooltip re-keyed on itemId only (was firing on every ElvUI refresh)
- Removed unconditional ResizeTooltip call from item tooltip path (caused first-hover pop)
- OnQuestDetail no longer writes objectives text to data[6] or quest body to data[17] or zoneId to data[8]
- OnQuestAccepted documents why requiredLevel/requiredRaces/requiredClasses are intentionally not captured
- Reused logIdx from data build pass instead of redeclaring it for the objective scan
- Secondary learner tooltip now matches GameTooltip style with or without ElvUI (defers to ElvUI when loaded, replicates its Transparent template otherwise)
- Combined-tooltip learner stats now framed by invisible spacer lines for visual separation
2026-06-07 08:38:12 -05:00
Xurkon f5d8e24810 fix: speed up slider redraws 2026-06-06 14:33:35 -05:00
Xurkon 1ca426ee9f feat: expand learner tooltip controls 2026-06-06 14:30:07 -05:00
Xurkon 1f3de0e02e feat: add learner tooltip controls 2026-06-06 13:59:31 -05:00
Xurkon 2cb129ae4b feat: add debug message throttle 2026-06-06 13:44:49 -05:00
Xurkon 84fefc1c20 fix: validate quest turn in learning 2026-06-06 13:16:51 -05:00
Xurkon 1d58e3fc79 fix: suppress nonfatal errors by default 2026-06-06 12:51:52 -05:00
Xurkon a1c6a181fc fix: refresh learner settings live 2026-06-06 12:19:23 -05:00
Xurkon dd630fd1e9 fix: allow learner clustering on sunstrider 2026-06-06 12:03:29 -05:00
Xurkon 287751a071 fix: let learner turn-ins drive arrow spawns 2026-06-06 11:48:11 -05:00
Xurkon 4e95418594 fix: gate object learning to quest-related data 2026-06-06 10:35:46 -05:00
Xurkon ccdfa525cf fix: gate learner item learning to quest items 2026-06-06 10:21:36 -05:00
Xurkon ada40add8b fix: invalidate caches after learner updates 2026-06-06 10:07:28 -05:00
Xurkon b0f2088ab7 fix: prefer loot source for item drops 2026-06-06 09:44:51 -05:00
Xurkon 36668338f5 fix: restore learner questgiver and item drop learning 2026-06-06 07:56:29 -05:00
Xurkon cccfa1e81b fix: preserve explicit learner spawn data 2026-06-06 07:44:17 -05:00
Xurkon 5326b16583 feat: add arrow5 bundled arrow style 2026-06-06 07:32:31 -05:00
Xurkon adb99c68c1 feat: heal learned npc coordinates from repeated kills 2026-06-06 07:21:03 -05:00
Xurkon 85d4a7a1e4 fix: suppress duplicate combat log npc learns 2026-06-06 07:15:05 -05:00
Xurkon 3f105e5782 fix: harden learner compatibility shims 2026-06-06 07:03:16 -05:00
Xurkon bed1e31a2f fix: quiet learner debug and harden vanilla guids 2026-06-06 07:00:30 -05:00
Xurkon 8c593a1cfd fix: correct learner npc and item learning ids 2026-06-06 06:53:38 -05:00
Xurkon 82b5aa86dd fix: harden learner quest accept resolution 2026-06-06 06:38:47 -05:00
Xurkon 6597d20b7d feat: refine learner data source and pin rendering 2026-06-06 00:04:50 -05:00
Xurkon 6f4bd69d00 fix: draw pins from immediate learner kill evidence 2026-06-05 22:27:27 -05:00
Xurkon c6e118165f fix: dedupe unavailable quest draw logs 2026-06-05 22:22:55 -05:00
Xurkon b75d624938 fix: guard unavailable quest draw thread 2026-06-05 22:19:44 -05:00
Xurkon 94707e1b93 fix: make learner db reads self-sustaining 2026-06-05 21:46:16 -05:00
Xurkon 5e3d1b4fd3 fix: learn object quest objectives 2026-06-05 21:32:10 -05:00
Xurkon ec82d66a9e fix: make learner-only mode static-free 2026-06-05 21:26:27 -05:00
Xurkon dbcf572e55 fix: let learner draw single spawn pins 2026-06-05 21:24:38 -05:00
Xurkon 0f20ea8aad fix: learn more combat kills 2026-06-05 21:22:14 -05:00
Xurkon 11b78cf3ce fix: route learner diagnostics to learner debug 2026-06-05 21:12:13 -05:00
Xurkon cf16e7e95b feat: show runtime learner mode in database tab 2026-06-05 21:09:10 -05:00
Xurkon 80ad1d49b0 fix: reduce quest 8325 fallback spam 2026-06-05 21:07:57 -05:00
Xurkon e40e9bc1b3 fix: show selected learner data source mode 2026-06-05 21:06:08 -05:00
Xurkon 15023b4a3a fix: learn credited unit died kills 2026-06-05 21:01:56 -05:00
Xurkon 64d5fb2f10 fix: keep learner mode live 2026-06-05 20:51:42 -05:00
Xurkon 9d02c8a231 fix: fully clear learned data buckets 2026-06-05 20:37:34 -05:00
Xurkon 3eda8d01ed fix: force learner on when base db is missing 2026-06-05 20:23:29 -05:00
Xurkon a0409eef8c feat: add learner/static data source mode 2026-06-05 20:15:26 -05:00