606
edits
m |
m |
||
| Line 241: | Line 241: | ||
local costData = {} | local costData = {} | ||
for resource, amount in pairs(buildingData.costs) do | for resource, amount in pairs(buildingData.costs) do | ||
local resourceIcon = i.icon(resource, nil, nil, | local labelText = com.firstUpper({resource}) | ||
if resource == 'gold coins' then | |||
labelText = 'Build Cost' -- PLS RENAME?? | |||
end | |||
local resourceIcon = i.icon(resource, nil, nil, labelText, 'en') | |||
table.insert(costData, {label = resourceIcon, value = amount}) | table.insert(costData, {label = resourceIcon, value = amount}) | ||
end | end | ||
-- Add 'bsplendour' to running costs if it exists | -- Add 'bsplendour' to running costs if it exists | ||
if buildingData.influence['bsplendour'] then | if buildingData.influence['bsplendour'] then | ||
| Line 250: | Line 254: | ||
table.insert(costData, {label = resourceIcon, value = buildingData.influence['bsplendour']}) | table.insert(costData, {label = resourceIcon, value = buildingData.influence['bsplendour']}) | ||
end | end | ||
if #costData > 0 then | if #costData > 0 then | ||
addSection(infobox, costData, 'Economic Impact', 2) | addSection(infobox, costData, 'Economic Impact', 2) | ||
edits