Module:Abilities/card: Difference between revisionsGive feedback
Gammaton32 (talk | contribs) added list of scaling attributes (will add function later) |
Gammaton32 (talk | contribs) added scaling function |
||
| Line 21: | Line 21: | ||
["power_increase"] = { class = "boon", icon = "[[File:Boon scaling.png|link=Boon|{{{icon_size|25px}}}]]" }, | ["power_increase"] = { class = "boon", icon = "[[File:Boon scaling.png|link=Boon|{{{icon_size|25px}}}]]" }, | ||
} | } | ||
-- List of get scaling attribute | |||
function p.get_scalar(frame) | |||
local args = frame.args | |||
local scaling = args[1] -- first parameter | |||
local attribute = args[2] -- second parameter | |||
local scaling = scalingTypes[scaling] | |||
if scaling then | |||
return scaling[attribute] or "" | |||
else | |||
return "{{Tooltip|?|Missing scaling type in Module:Abilities/card}}" | |||
end | |||
return "" | |||
end | |||
function get_hero_key(hero_name) | function get_hero_key(hero_name) | ||