Module:Skills: Difference between revisions

getMasteryUnlockTable, getMasteryCheckpointTable: Fix SkillData lookup
(getFiremakingTable: Fix reference to non-existent attribute)
(getMasteryUnlockTable, getMasteryCheckpointTable: Fix SkillData lookup)
Line 233: Line 233:
end
end


local unlockTable = SkillData[skillID].masteryLevelUnlocks
local _, localSkillID = GameData.getLocalID(skillID)
local unlockTable = SkillData[localSkillID].masteryLevelUnlocks
if unlockTable == nil then
if unlockTable == nil then
return 'ERROR: Failed to find Mastery Unlock data for '..skillName
return 'ERROR: Failed to find Mastery Unlock data for '..skillName
Line 254: Line 255:
end
end


local checkpoints = SkillData[skillID].masteryCheckpoints
local _, localSkillID = GameData.getLocalID(skillID)
local checkpoints = SkillData[localSkillID].masteryCheckpoints
if checkpoints == nil then
if checkpoints == nil then
return 'ERROR: Failed to find Mastery Unlock data for '..skillName
return 'ERROR: Failed to find Mastery Unlock data for '..skillName