Anonymous

Module:Items: Difference between revisions

From Melvor Idle
Adjusted p.getModifierText calls to reflect formatting changes
m (typo fix)
(Adjusted p.getModifierText calls to reflect formatting changes)
Line 187: Line 187:
   if asString then
   if asString then
     if skill ~= nil then
     if skill ~= nil then
       return Constants.getModifierText(modifier, {skill, result})
       return Constants._getModifierText(modifier, {skill, result})
     else
     else
       return Constants.getModifierText(modifier, result)
       return Constants._getModifierText(modifier, result)
     end
     end
   else
   else
Line 294: Line 294:
     local modArray = {}
     local modArray = {}
     for bonus, value in Shared.skpairs(item.modifiers) do
     for bonus, value in Shared.skpairs(item.modifiers) do
       table.insert(modArray, Constants.getModifierText(bonus, value, false))
       table.insert(modArray, Constants._getModifierText(bonus, value, false))
     end
     end
     result = result.."\r\n|-\r\n|'''Bonuses:'''\r\n"..table.concat(modArray, "<br/>")
     result = result.."\r\n|-\r\n|'''Bonuses:'''\r\n"..table.concat(modArray, "<br/>")