572
edits
No edit summary |
No edit summary |
||
Line 336: | Line 336: | ||
table.insert(ret, '\r\n|-\r\n| <b>Building ID:</b> '..building.id) | table.insert(ret, '\r\n|-\r\n| <b>Building ID:</b> '..building.id) | ||
local tier = p._GetTierRequirements(building.tier) | local tier = p._GetTierRequirements(building.tier) | ||
table.insert(ret, '\r\n|-\r\n| <b>Tier '..building.tier..'</b><ul><li>'..Icons._SkillReq('Township', tier.level, false)..'</li><li>'..tier.population.. | table.insert(ret, '\r\n|-\r\n| <b>Tier '..building.tier..'</b><ul><li>'..Icons._SkillReq('Township', tier.level, false)..'</li><li>'..tier.population..p.GetTownshipStatIcon('Population')..'</li></ul>') | ||
table.insert(ret, '\r\n|}') | table.insert(ret, '\r\n|}') | ||
return table.concat(ret) | return table.concat(ret) | ||
end | end | ||
-- Todo - integrate into Icons.Icon? | |||
function p.GetTownshipStatIcon(stat) | |||
return '<span style="display:inline-block" class="township-colortoggle">[[File:'..stat..'_(township).svg|25x25px|link='..stat..']]</span>' | |||
end | |||
-- Testing | |||
p.GameData = GameData | p.GameData = GameData | ||
p.Icons = Icons | |||
p.Township = Township | p.Township = Township | ||
return p | return p |
edits