Module:ShipInfobox: Difference between revisions

Content deleted Content added
No edit summary
No edit summary
Line 52:
 
function Infobox.Internals( field, vars )
local matroska = nil
--▼
local output = {}
if not isempty(field.S1) then
table.insert(output, field.S1 .. 'x Size 1 ' ..
lang:plural( u, 'Compartment', 'Compartments'))
matroska = true
▲ --end
if not isempty(field.S2) then
if (matroska) then table.insert(output, '<br />') end
table.insert(output, field.S2 .. 'x Size 2 ' ..
lang:plural( u, 'Compartment', 'Compartments'))
matroska = true
▲ end
if not isempty(field.S3) then
if (matroska) then table.insert(output, '<br />') end
table.insert(output, field.S3 .. 'x Size 3 ' ..
lang:plural( u, 'Compartment', 'Compartments'))
matroska = true
end
if not isempty(field.S4) then
if (matroska) then table.insert(output, '<br />') end
table.insert(output, field.S4 .. 'x Size 4 ' ..
lang:plural( u, 'Compartment', 'Compartments'))
matroska = true
end
if not isempty(field.S5) then
if (matroska) then table.insert(output, '<br />') end
table.insert(output, field.S5 .. 'x Size 5 ' ..
lang:plural( u, 'Compartment', 'Compartments'))
matroska = true
end
if not isempty(field.S6) then
if (matroska) then table.insert(output, '<br />') end
table.insert(output, field.S6 .. 'x Size 6 ' ..
lang:plural( u, 'Compartment', 'Compartments'))
matroska = true
end
if not isempty(field.S7) then
if (matroska) then table.insert(output, '<br />') end
table.insert(output, field.S7 .. 'x Size 7 ' ..
lang:plural( u, 'Compartment', 'Compartments'))
matroska = true
end
if not isempty(field.S8) then
if (matroska) then table.insert(output, '<br />') end
table.insert(output, field.S8 .. 'x Size 8 ' ..
lang:plural( u, 'Compartment', 'Compartments'))
matroska = true
end
if not isempty(field.Reserved) then
if (matroska) then table.insert(output, '<br />') end
table.insert(output, field.Reserved)
end
end
 
Line 66 ⟶ 117:
matroska = true
end
if not isempty(field.S) then
if (matroska) then table.insert(output, '<br />') end
table.insert(output, field.S .. 'x Small ' .. hplabel)
matroska = true
end
if not isempty(field.M) then
if (matroska) then table.insert(output, '<br />') end
table.insert(output, field.M .. 'x Medium ' .. hplabel)
matroska = true
end
if not isempty(field.L) then
if (matroska) then table.insert(output, '<br />') end
table.insert(output, field.L .. 'x Large ' .. hplabel)
matroska = true
end
if not isempty(field.H) then
if (matroska) then table.insert(output, '<br />') end
table.insert(output, field.H .. 'x Huge ' .. hplabel)