Anonymous

Module:Items: Difference between revisions

From Melvor Idle
Changed Bonuses -> Modifiers in infobox, added color coding
(Added p.hasCombatStats)
(Changed Bonuses -> Modifiers in infobox, added color coding)
Line 313: Line 313:
     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, true))
     end
     end
     result = result.."\r\n|-\r\n|'''Bonuses:'''\r\n"..table.concat(modArray, "<br/>")
     result = result.."\r\n|-\r\n|'''Modifiers:'''\r\n"..table.concat(modArray, "<br/>")
   end
   end
   return result
   return result