2,875
edits
(Add table creation (still empty)) |
m (Fill more of table) |
||
Line 12: | Line 12: | ||
local ValueSuffix = 'value' | local ValueSuffix = 'value' | ||
local SkillPrefix = 'skillExp' | local SkillPrefix = 'skillExp' | ||
-- Determines the order of Icons | |||
local DLCParams = { | local DLCParams = { | ||
toth = 'melvorTotH', | |||
aod = 'melvorAoD', | aod = 'melvorAoD', | ||
ita = 'melvorItA' | ita = 'melvorItA' | ||
} | } | ||
Line 136: | Line 138: | ||
:tag("td") | :tag("td") | ||
:attr("colspan", 2) | :attr("colspan", 2) | ||
:wikitext( | :wikitext('dlcIcon') | ||
:wikitext(args['guideName'] or '{{{guideName}}}') | |||
:tag("tr") | :tag("tr") | ||
:tag("th") | :tag("th") | ||
Line 186: | Line 189: | ||
end | end | ||
--- Returns the parsed result of the | --- Returns the parsed result of the dlcParam. | ||
-- @param | -- @param dlcParam (string) A string separated by , listing the DLCs required for the MMG | ||
-- @return (table) A table | -- @return (table) A table containing the items of provided DLCs | ||
function p. | function p.getDLCIcons(dlcParam) | ||
if type( | if type(dlcParam) ~= 'string' then return {} end | ||
local dlcs = {} | local dlcs = {} | ||
for _, arg in pairs(shared.splitString(dlcArgs, ',')) do | for _, arg in pairs(shared.splitString(dlcArgs, ',')) do | ||
for dlc, | for dlc, icon in pairs(DLCParams) do | ||
if shared.compareString(dlc, arg, true) then | if shared.compareString(dlc, arg, true) then | ||
table.insert(dlcs, | table.insert(dlcs, icon) | ||
end | end | ||
end | end |
edits