fix: learn credited unit died kills

This commit is contained in:
Xurkon
2026-06-05 21:01:56 -05:00
parent 64d5fb2f10
commit 15023b4a3a
2 changed files with 51 additions and 13 deletions
+5 -3
View File
@@ -3496,14 +3496,16 @@ function QuestieLearner:OnCombatLogEvent(timestamp, eventType, srcGUID, srcName,
end
-- UNIT_DIED fires for nearby mobs killed by other players. Keep it only as
-- short-lived evidence for quest-progress correlation; otherwise bystander
-- kills can churn learner spawn data and redraw active quest pins.
if eventType ~= "PARTY_KILL" then
-- short-lived evidence for quest-progress correlation unless we can prove
-- the kill was credited to us; otherwise bystander kills can churn learner
-- spawn data and redraw active quest pins.
if eventType ~= "PARTY_KILL" and not credited then
return
end
-- Unconditionally map the spawn position for Ascension DB building
self:LearnNPC(npcId, name, nil, nil, nil, nil, px, py, zoneId)
Questie:Debug(Questie.DEBUG_LEARNER, "[QuestieLearner] Combat-log learned NPC:", eventType, npcId, name or "?")
-- Phase 2: store per-GUID spawn evidence for weighted merge
self:_StoreGuidSpawnEvidence(npcId, dstGUID, zoneId, px, py)