fix(learner): guard HasQuestReferences against flat-number entries on Area 52

Some Area 52 quest records store qData[2][3] as a flat number instead of
a table-of-tables. The inner loop's entry[1] index then crashes with
'attempt to index local entry (a number value)'. Normalize with a
type check before comparing.
This commit is contained in:
Xurkon
2026-06-08 21:36:10 -05:00
parent 011cdb58a9
commit 6a4f715b76
+2 -1
View File
@@ -2212,7 +2212,8 @@ local function HasQuestReferences(itemId)
end
if qData[2] and qData[2][3] then
for _, entry in ipairs(qData[2][3]) do
if entry[1] == itemId then
local entryId = type(entry) == "table" and entry[1] or entry
if entryId == itemId then
return true
end
end