Module:Sandbox/Samlovesmath: Difference between revisionsGive feedback
Samlovesmath (talk | contribs) initial layout / data |
Samlovesmath (talk | contribs) mNo edit summary |
||
| Line 32: | Line 32: | ||
["stats_text"] = "#bbffbf", | ["stats_text"] = "#bbffbf", | ||
["stats_back"] = "#12301aA3", | ["stats_back"] = "#12301aA3", | ||
["background_image"] = "Default_select_background.png" | ["background_image"] = "Default_select_background.png" | ||
}, | }, | ||
| Line 237: | Line 237: | ||
["hero_yamato"] = { | ["hero_yamato"] = { | ||
["background_image"] = "Yamato_select_background.png" | ["background_image"] = "Yamato_select_background.png" | ||
} | } | ||
} | } | ||
-- get list of heroes | -- get list of heroes | ||
| Line 252: | Line 249: | ||
return heroList | return heroList | ||
end | end | ||
function p.get_theme_value(heroName, themeVar) | |||
function p. | if infoboxVars[heroName] ~= nil and infoboxVars[heroName][themeVar] ~= nil then | ||
if infoboxVars[heroName] ~= nil and infoboxVars[heroName][ | return infoboxVars[heroName][themeVar] | ||
elseif infoboxVars["default"][themeVar] ~= nil then | |||
return infoboxVars[heroName][ | return infoboxVars["default"][themeVar] | ||
elseif infoboxVars["default"][ | |||
return infoboxVars["default"][ | |||
end | end | ||
end | end | ||
return p | return p | ||