Module:HeroDataArrays: Difference between revisionsGive feedback
Gammaton32 (talk | contribs) changed PI to boon |
Gammaton32 (talk | contribs) bullet damage |
||
| Line 199: | Line 199: | ||
end | end | ||
z = z.."|}" | z = z.."|}" | ||
return z | |||
end | |||
p.heroBulletDamageTable = function(frame) | |||
-- Pull data | |||
heroBulletDamageData = heroDataArray({"Name", "BulletDamage", "LevelScaling>BulletDamage"}) | |||
-- Input table will be called a, output wikitable will be called z | |||
-- From a to z, haha get it | |||
z = "{| class=\"wikitable sortable mw-collapsible\" style=\"text-align:center\" \n".. | |||
"|+ Hero Base Bullet Damage Stats \n".. | |||
"! Hero !! Starting !! Added per Boon !! At Max Boon \n" | |||
-- Iterate over heroes adding a new row to the wikitable for each | |||
for i,a in pairs(heroBulletDamageData) do | |||
z = z.. | |||
"|- \n".. | |||
"| style=\"text-align:left;\" | ".. | |||
frame:expandTemplate{title="PageRef", args={a["Name"]}}.. | |||
" || "..a["BulletDamage"].." || +"..a["LevelScaling>BulletDamage"].." || ".. | |||
tostring(roundValue(tonumber(a["BulletDamage"])+tonumber(a["LevelScaling>BulletDamage"])*14)).." \n" | |||
end | |||
-- Cap it off | |||
z = z.."|}" | |||
return z | return z | ||
end | end | ||
return p | return p | ||