Module:HeroData: Difference between revisionsGive feedback
m role playstyle name wep name wep desc |
m only call lang if not nil |
||
| Line 109: | Line 109: | ||
template_args["name"] = lang_module.search_string(hero_name) | template_args["name"] = lang_module.search_string(hero_name) | ||
local wep_name = | local wep_name = hero_data["WeaponName"] | ||
if (wep_name ~= nil) then template_args["weapon_name"] = wep_name end | if (wep_name ~= nil) then template_args["weapon_name"] = lang_module.get_string(wep_name) end | ||
local wep_desc = | local wep_desc = hero_data["WeaponDescription"] | ||
if (wep_desc ~= nil) then template_args["weapon_description"] = wep_desc end | if (wep_desc ~= nil) then template_args["weapon_description"] = lang_module.get_string(wep_desc) end | ||
local role = | local role = hero_data["Role"] | ||
if (role ~= nil) then template_args["role"] = role end | if (role ~= nil) then template_args["role"] = lang_module.get_string(role) end | ||
local playstyle = | local playstyle = hero_data["Playstyle"] | ||
if (playstyle ~= nil) then template_args["playstyle"] = playstyle end | if (playstyle ~= nil) then template_args["playstyle"] = lang_module.get_string(playstyle) end | ||
-- Iterate attribute categories | -- Iterate attribute categories | ||