Difference between revisions of "Module:OTable"

Jump to navigation Jump to search
m
no edit summary
m
m
 
(2 intermediate revisions by the same user not shown)
Line 49: Line 49:
local buildingType = c.type
local buildingType = c.type
local influence = ''
local influence = ''
if c.influence then
          if c.influence then
          local influenceKeys = {}
          local influenceKeys = {}
          for k in pairs(c.influence) do
          for k in pairs(c.influence) do
          if k ~= 'perEach splendour' then
            if k ~= 'bsplendour' and k ~= 'tier' then -- Exclude 'bsplendour' and 'tier'... for now
            table.insert(influenceKeys, k)
            table.insert(influenceKeys, k)
            end
           end
           end
          end
          local lastKey = influenceKeys[#influenceKeys]
          local lastKey = influenceKeys[#influenceKeys]
          local itemCount = #influenceKeys
          local itemCount = #influenceKeys
       
 
          for k, v in pairs(c.influence) do
          for k, v in pairs(c.influence) do
            if k ~= 'bsplendour' and k ~= 'tier' then
          if k ~= 'perEach splendour' then
            influence = influence .. i.icon(k, v, nil, k, 'en')
            influence = influence .. i.icon(k, v, nil, k, 'en')
            if k ~= lastKey and itemCount > 1 then
            if k ~= lastKey and itemCount > 1 then
              influence = influence .. '<br />'
            influence = influence .. '<br />'
            end
             end
             end
           end
           end
           end
           end
        end
          local unlocks = influence
        local unlocks = influence
local production = ''
local production = ''
606

edits

Navigation menu