Module:Infobox PQ and Dungeon
Jump to navigation
Jump to search
DescriptionTemplate to make a table showing information about a Party Quest or Dungeon-type content. Usage{{#invoke:Infobox PQ and Dungeon|create|parameter1|parameter2|parameter3
Valid parameters:
title PQ / Dungeon icon and name.
image PQ / Dungeon image, for example a screenshot of the gameplay during the PQ or dungeon
level Recommended Level
If a level range is specified, leave the range as X - Y, otherwise leave as <Level+>
Examples: 160 - 179 or 160+
maxlevel Maximum level to enter
Leave as 300 If no maximum level known
members Number of people required to enter
prequest Prequests
Leave blank if not applicable.
entrylimit Number of entries allowed per day
clearlimit Number of clears allowed per day
Leave blank if the same as entryLimit
kmsName Location's name in KoreaMS; leave blank if not applicable
jmsName Location's name in JapanMS; leave blank if not applicable
cmsName Location's name in ChinaMS; leave blank if not applicable
tmsName Location's name in TaiwanMS; leave blank if not applicable
seaName Location's name in MapleSEA; leave blank if not applicable
Example{{Infobox PQ and Dungeon
|name=[[File:MapIcon kentaInDanger.png]] Kenta in Danger
|level=160 - 179
|maxlevel=300
|partySize=2 - 6
|prequest=
|entrylimit=5 entries every day
|clearlimit=
|kmsName=위험에 빠진 켄타 ([https://namu.wiki/w/파티 퀘스트#s-4.9 Kenta in Danger; Wiheom-e ppajin kenta])
|jmsName=
|cmsName=
|tmsName=
|seaName=
}}
{{Infobox PQ and Dungeon
|name=[[File:MapIcon esfera.png]] Esfera Guardian
|level=235+
|maxlevel=300
|partySize=1
|prequest=[[(Esfera) Mirrors in Mirrors|[Esfera] Mirrors in Mirrors]]
|entrylimit=
|clearlimit=3 clears every week
|kmsName=프로텍트 에스페라 ([https://namu.wiki/w/프로텍트%20에스페라 Protect Esfera; Peulotegteu eseupela])
|jmsName=プロテクトエスフェラ (Protect Esfera; Purotekutoesufera)
|cmsName=保护埃斯佩拉 (Protect Esfera; Bǎohù āi sī pèi lā)
|tmsName=保護艾斯佩拉 (Protect Esfera; Bǎohù ài sī pèi lā)
|seaName=Protect Esfera
}}
|
Output:
| Recommended level | 160 - 179 |
|---|---|
| Max level | 300 |
| Party size | 2 - 6 |
| Entry limit | 5 entries every day |
| Name (Other Servers) | |
| KoreaMS | 위험에 빠진 켄타 (퀘스트#s-4.9 Kenta in Danger; Wiheom-e ppajin kenta) |
Output:
| Recommended level | 235+ |
|---|---|
| Max level | 300 |
| Party size | 1 |
| Prequest | [Esfera] Mirrors in Mirrors |
| Clear limit | 3 clears every week |
| Name (Other Servers) | |
| KoreaMS | 프로텍트 에스페라 (Protect Esfera; Peulotegteu eseupela) |
| JapanMS | プロテクトエスフェラ (Protect Esfera; Purotekutoesufera) |
| ChinaMS | 保护埃斯佩拉 (Protect Esfera; Bǎohù āi sī pèi lā) |
| TaiwanMS | 保護艾斯佩拉 (Protect Esfera; Bǎohù ài sī pèi lā) |
| MapleSEA | Protect Esfera |
local p = {}
local infobox = require('Module:Infobox')
function image(input, default)
if input == null or input == '' then
return default
end
if not input:match("gallery") and not input:match("tabber") and not input:match("%[%[File:") then
return "[[File:" .. input .. "]]"
end
if input:match("^File:") then
return "[[" .. input .. "]]"
end
return input
end
function p.main(frame)
local args = frame:getParent().args
local box = infobox.new(args)
box:start()
box:defineParams{
{ name = 'name', default = mw.title.getCurrentTitle().fullText },
{ name = 'image', func = image },
{ name = 'level' },
{ name = 'maxlevel' },
{ name = 'partySize' },
{ name = 'prequest' },
{ name = 'entrylimit' },
{ name = 'clearlimit' },
{ name = 'kmsName' },
{ name = 'jmsName' },
{ name = 'cmsName' },
{ name = 'tmsName' },
{ name = 'seaName' },
}
box:addRow{{ tag = 'argh', content = 'name', colspan = '2' }}
box:addRow{{ tag = 'argd', content = 'image', colspan = '2', class = 'infobox-image' }}
box:addQuickRow('Recommended level', 'level')
box:addQuickRow('Max level', 'maxlevel')
box:addQuickRow('Party size', 'partySize')
box:addQuickRow('Prequest', 'prequest')
box:addQuickRow('Entry limit', 'entrylimit')
box:addQuickRow('Clear limit', 'clearlimit')
-- Regional
if box:checkExists('kmsName', 'jmsName', 'cmsName', 'tmsName', 'seaName') then
box:addRow{{ tag = 'th', content = 'Name (Other Servers)', colspan = '2' }}
box:addQuickRow('KoreaMS', 'kmsName')
box:addQuickRow('JapanMS', 'jmsName')
box:addQuickRow('ChinaMS', 'cmsName')
box:addQuickRow('TaiwanMS', 'tmsName')
box:addQuickRow('MapleSEA', 'seaName')
end
return box:tostring()
end
return p