Module:MonsterVariantsTable: Difference between revisions
Jump to navigation
Jump to search
Content added Content deleted
Californ1a (talk | contribs) m (cleanup) |
Californ1a (talk | contribs) m (separate unlock profession) |
||
Line 1: | Line 1: | ||
require('Module:Mw.html extension') |
|||
local editbutton = require('Module:Edit button') |
local editbutton = require('Module:Edit button') |
||
local p = {} |
local p = {} |
||
Line 22: | Line 23: | ||
'?Name = name', |
'?Name = name', |
||
'?= page', |
'?= page', |
||
'?Unlock_level = |
'?Unlock_level = unlock_lvl', |
||
'?Unlock profession # = unlock_profession', |
|||
'?Profession_Level_A = combat', |
'?Profession_Level_A = combat', |
||
'?Profession A # = profession', |
'?Profession A # = profession', |
||
Line 61: | Line 63: | ||
table.sort(data, function(a, b) |
table.sort(data, function(a, b) |
||
-- Determine combat values |
-- Determine combat values |
||
local combatA = a.combat or a. |
local combatA = a.combat or a.unlock_lvl or math.huge |
||
local combatB = b.combat or b. |
local combatB = b.combat or b.unlock_lvl or math.huge |
||
-- Sort in ascending order |
-- Sort in ascending order |
||
return combatA < combatB |
return combatA < combatB |
||
Line 79: | Line 81: | ||
:done() |
:done() |
||
:tag('td') |
:tag('td') |
||
:IF(entry.unlock_lvl == 'N/A') |
|||
⚫ | |||
:addClass('table-na') |
|||
:wikitext('N/A') |
|||
:ELSE() |
|||
⚫ | |||
:END() |
|||
:done() |
:done() |
||
:tag('td') |
:tag('td') |