Module:Cosmetic items: Difference between revisions
No edit summary |
mNo edit summary |
||
| Line 1: | Line 1: | ||
local p = {} | local p = {} | ||
local parse = function(args, sourcesTable, tableHeader, tableExtras, versionText) | local parse = function(args, sourcesTable, tableHeader, tableExtras, versionText, versionDefault) | ||
local sFormat = string.format | local sFormat = string.format | ||
| Line 36: | Line 36: | ||
tConcat(extras, "||"), | tConcat(extras, "||"), | ||
sourcesById[id] ~= nil and sources[sourcesById[id]].name or "''To be added''", | sourcesById[id] ~= nil and sources[sourcesById[id]].name or "''To be added''", | ||
args[sFormat("introduced %i", i)] ~= "" and sFormat(versionText, frame.args[sFormat("introduced %i", i)], frame.args[sFormat("introduced %i", i)]) or | args[sFormat("introduced %i", i)] ~= "" and sFormat(versionText, frame.args[sFormat("introduced %i", i)], frame.args[sFormat("introduced %i", i)]) or versionDefault, | ||
args[sFormat("notes %i", i)] | args[sFormat("notes %i", i)] | ||
) | ) | ||
| Line 53: | Line 53: | ||
!class='unsortable'|Icon!!Text!!Unlock method(s)!!Introduced!!class='unsortable'|Notes]], | !class='unsortable'|Icon!!Text!!Unlock method(s)!!Introduced!!class='unsortable'|Notes]], | ||
{}, | {}, | ||
"[[Bloons TD 6 v%s|Version %s]]" | "[[Bloons TD 6 v%s|Version %s]]", | ||
"''To be added''" | |||
) | ) | ||
end | end | ||
| Line 64: | Line 65: | ||
!class='unsortable'|Icon!!Text!!Unlock method(s)!!Introduced!!class='unsortable'|Notes]], | !class='unsortable'|Icon!!Text!!Unlock method(s)!!Introduced!!class='unsortable'|Notes]], | ||
{}, | {}, | ||
"[[Bloons TD 6 v%s|Version %s]]" | "[[Bloons TD 6 v%s|Version %s]]", | ||
"''To be added''" | |||
) | ) | ||
end | end | ||
| Line 75: | Line 77: | ||
!class='unsortable'|Icon!!Text!!Unlock method(s)!!Introduced!!class='unsortable'|Notes]], | !class='unsortable'|Icon!!Text!!Unlock method(s)!!Introduced!!class='unsortable'|Notes]], | ||
{}, | {}, | ||
"[[Bloons TD Battles 2 v%s|Version %s]]" | "[[Bloons TD Battles 2 v%s|Version %s]]", | ||
"Launch" | |||
) | ) | ||
end | end | ||
| Line 86: | Line 89: | ||
!class='unsortable'|Icon!!Text!!Tower!!Unlock method(s)!!Introduced!!class='unsortable'|Notes]], | !class='unsortable'|Icon!!Text!!Tower!!Unlock method(s)!!Introduced!!class='unsortable'|Notes]], | ||
{"tower %i"}, | {"tower %i"}, | ||
"[[Bloons TD Battles 2 v%s|Version %s]]" | "[[Bloons TD Battles 2 v%s|Version %s]]", | ||
"Launch" | |||
) | ) | ||
end | end | ||
return p | return p | ||