Template:RegionalNPCs: Difference between revisions
From IdleOn MMO Wiki
(Created page with "<noinclude> <!-- ### Cargo Declare ### --> {{#cargo_declare:_table=NPCs |MapLocation=String |QuestCount=Integer |NPCType=String }} </noinclude> <!-- ### Carge Store ### --> <includeonly> {{Npctable/head|{{{title}}}}} {{#cargo_query:tables=NPCs |fields=_pageName=%PAGE%,MapLocation=location,QuestCount=noquest |where=(MapLocation IN ({{{areas}}})) AND (NPCType IN ({{{npctypes}}})) |format=template |template=Npc/row |named args=yes }} |} </includeonly> <!-- ### Usage...") |
mNo edit summary |
||
(13 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
< | <includeonly>=={{{region|Region Name}}}== | ||
{{ | |||
{{#cargo_query:tables=NPCs | {{#cargo_query:tables=NPCs | ||
|fields=_pageName=%PAGE%,MapLocation=location,QuestCount=noquest | |fields=_pageName=%PAGE%,MapLocation=location,QuestCount=noquest | ||
|where=(MapLocation | |where=({{#if:{{{areas|}}}|{{#arraymap:{{{areas|Blunder Hills}}}|,|x|MapLocation LIKE "%x%"|\sOR\s}}| World="{{{region|Blunder Hills}}}"}}) | ||
AND (NPCType IN ({{#arraymap:{{{npctypes|NPC}}}|,|x|"x"}})) | |||
|format=template | |format=template | ||
|template=Npc/row | |template=Npc/row | ||
|named args=yes | |named args=yes | ||
}} | |intro={{Npctable/head|{{{region|Region/Section Title}}}}} | ||
|} | |outro={{!}}} | ||
</includeonly> | }}</includeonly><noinclude> | ||
<!-- ### Usage --> | |||
Renders name, icon, location and amount of quests as taken from the "NPCs" Cargo table, filtered by certain parameters listed below. | |||
Notes: Both Areas and NPC types have to be separated by comma and '''no''' quotation marks should be used in any parameter. | |||
Usage: | Usage: | ||
{{ | <pre> | ||
| | {{RegionalNPCs | ||
|areas=example,example | |region=example | ||
|npctypes=example,example ("NPC" | |areas=example,example (If ommited, defaults to the region parameter. Used for checking whole worlds as the region.) | ||
|npctypes=example,example (If ommited, defaults to just "NPC") | |||
}} | }} | ||
</pre> | </pre> | ||
[[Category:Table templates]] | [[Category:Table templates]] | ||
</noinclude> | </noinclude> |
Latest revision as of 17:33, 18 May 2023
Renders name, icon, location and amount of quests as taken from the "NPCs" Cargo table, filtered by certain parameters listed below.
Notes: Both Areas and NPC types have to be separated by comma and no quotation marks should be used in any parameter.
Usage:
{{RegionalNPCs |region=example |areas=example,example (If ommited, defaults to the region parameter. Used for checking whole worlds as the region.) |npctypes=example,example (If ommited, defaults to just "NPC") }}