Anonymous

Module:Items: Difference between revisions

From Melvor Idle
_getItemStat: Special handling for category
(_getOtherItemBoxText: Lazy adjustment for Augite special attack descriptions)
(_getItemStat: Special handling for category)
Line 79: Line 79:
elseif StatName == 'hasCombatStats' then
elseif StatName == 'hasCombatStats' then
return tostring(p.hasCombatStats(item) or p._hasLevelRequirements(item))
return tostring(p.hasCombatStats(item) or p._hasLevelRequirements(item))
elseif StatName == 'category' then
-- Some categories have a namespace for some reason, remove it
local _, localID = GameData.getLocalID(result)
return localID
end
end
if result == nil and ZeroIfNil then result = 0 end
if result == nil and ZeroIfNil then result = 0 end