Template:Map variants: Difference between revisions
Jump to navigation
Jump to search
>AnSq (default to PAGENAME) |
>AnSq (maps won't show on their own pages. Added heading options) |
||
Line 1: | Line 1: | ||
<includeonly> | <includeonly>{{#vardefine:one | {{#sub:{{{1|{{SUBPAGENAME}} }}}|0|{{#pos:{{{1|{{SUBPAGENAME}} }}}|Map}} }} | ||
{{#vardefine:one | {{#sub:{{{1|{{ | |||
{{#vardefine:war | {{#if:{{{war|}}} |{{{war}}} |{{#var:one}} }} }} | }}{{#vardefine:war | {{#if:{{{war|}}} |{{{war}}} |{{#var:one}} }} | ||
{{#vardefine:atlas | {{#if:{{{atlas|}}} |{{{atlas}}} |{{#var:one}} }} }} | }}{{#vardefine:atlas | {{#if:{{{atlas|}}} |{{{atlas}}} |{{#var:one}} }} | ||
{{#vardefine:awakening | {{#if:{{{awakening|}}} |{{{awakening}}} |{{#var:one}} }} }} | }}{{#vardefine:awakening | {{#if:{{{awakening|}}} |{{{awakening}}} |{{#var:one}} }} | ||
{{#vardefine:original | {{#if:{{{original|}}} |{{{original}}} |{{#var:one | }}{{#vardefine:original | {{#if:{{{original|}}} |{{{original}}} |{{#var:one}} }} | ||
}}{{#vardefine:show_all | {{{show_all|0}}} | |||
{{#vardefine: | |||
{{#if:{{#var:war_exists}} |* {{il|page={{#var:war}} Map (War for the Atlas) |name={{#var:war}} Map (War for the Atlas)}} |* There is no {{#var:war}} Map in the ''War for the Atlas'' map series}} | }}{{#vardefine:war_exists | {{#if:{{#cargo_query:table = maps |where = maps._pageName='{{#var:war}} Map (War for the Atlas)' |default=}} | 1 | 0}} | ||
{{# | }}{{#vardefine:atlas_exists | {{#if:{{#cargo_query:table = maps |where = maps._pageName='{{#var:atlas}} Map (Atlas of Worlds)' |default=}} | 1 | 0}} | ||
{{# | }}{{#vardefine:atlas_shaped_exists | {{#if:{{#cargo_query:table = maps |where = maps._pageName='Shaped {{#var:atlas}} Map (Atlas of Worlds)' |default=}} | 1 | 0}} | ||
{{# | }}{{#vardefine:awakening_exists | {{#if:{{#cargo_query:table = maps |where = maps._pageName='{{#var:awakening}} Map (The Awakening)' |default=}} | 1 | 0}} | ||
{{# | }}{{#vardefine:original_exists | {{#if:{{#cargo_query:table = maps |where = maps._pageName='{{#var:original}} Map (Original)' |default=}} | 1 | 0}} | ||
<noinclude>{{documentation}}</noinclude> | |||
}}{{#vardefine:onpage_war | {{#ifeq:{{SUBPAGENAME}} | {{#var:war}} Map (War for the Atlas) | 1 | 0}} | |||
}}{{#vardefine:onpage_atlas | {{#ifeq:{{SUBPAGENAME}} | {{#var:war}} Map (Atlas of Worlds) | 1 | 0}} | |||
}}{{#vardefine:onpage_atlas_shaped | {{#ifeq:{{SUBPAGENAME}} | Shaped {{#var:war}} Map (Atlas of Worlds) | 1 | 0}} | |||
}}{{#vardefine:onpage_awakening | {{#ifeq:{{SUBPAGENAME}} | {{#var:war}} Map (The Awakening) | 1 | 0}} | |||
}}{{#vardefine:onpage_original | {{#ifeq:{{SUBPAGENAME}} | {{#var:war}} Map (Original) | 1 | 0}} | |||
}}{{#vardefine:show_war | {{#expr: not {{#var:onpage_war}} or {{#var:show_all}} }} | |||
}}{{#vardefine:show_atlas | {{#expr: not {{#var:onpage_atlas}} or {{#var:show_all}} }} | |||
}}{{#vardefine:show_atlas_shaped | {{#expr: not {{#var:onpage_atlas_shaped}} or {{#var:show_all}} }} | |||
}}{{#vardefine:show_awakening | {{#expr: not {{#var:onpage_awakening}} or {{#var:show_all}} }} | |||
}}{{#vardefine:show_original | {{#expr: not {{#var:onpage_original}} or {{#var:show_all}} }} | |||
}}{{#ifexpr:not {{{hide_heading|0}}} | == {{{heading|Other Versions}}} == | |||
|}}{{#ifexpr: {{#var:show_war}} | {{#ifexpr:{{#var:war_exists}} | * {{il|page={{#var:war}} Map (War for the Atlas) |name={{#var:war}} Map (War for the Atlas)}} |* There is no {{#var:war}} Map in the ''War for the Atlas'' map series | |||
}} |}}{{#ifexpr:{{#var:show_atlas}} | {{#ifexpr:{{#var:atlas_exists}} | * {{il|page={{#var:atlas}} Map (Atlas of Worlds) |name={{#var:atlas}} Map (Atlas of Worlds)}} |* There is no {{#var:atlas}} Map in the ''Atlas of Worlds'' map series | |||
}} |}}{{#ifexpr:{{#var:show_atlas_shaped}} | {{#ifexpr:{{#var:atlas_shaped_exists}} | * {{il|page=Shaped {{#var:atlas}} Map (Atlas of Worlds) |name=Shaped {{#var:atlas}} Map (Atlas of Worlds)}} | |||
|}}|}}{{#ifexpr:{{#var:show_awakening}} | {{#ifexpr:{{#var:awakening_exists}} | * {{il|page={{#var:awakening}} Map (The Awakening) |name={{#var:awakening}} Map (The Awakening)}} |* There is no {{#var:awakening}} Map in ''The Awakening'' map series | |||
}} |}}{{#ifexpr:{{#var:show_original}} | {{#ifexpr:{{#var:original_exists}} | * {{il|page={{#var:original}} Map (Original) |name={{#var:original}} Map (Original)}} |* There is no {{#var:original}} Map in the ''Original'' map series | |||
}} |}}</includeonly><noinclude>{{documentation}}</noinclude> |
Revision as of 10:48, 16 January 2018
This template displays a table of map variants that share the same name. The maps are listed in order of which series they belong to, from the most recent to the oldest.
Usage
Use this template on a map page to create a section listing its variants.
Parameters
Use one of the following parameters to specify how to query for map variants. If both are omitted, the current page name is used.
Parameter | Description |
---|---|
1 , item_name
|
Get variants of the map with this name. Use this parameter or |page= , not both.
|
page
|
Get variants of the map on this page. Use this parameter or |item_name= , not both.
|
Example
{{Map variants|item_name=Cursed Crypt Map}}
Other Versions
- There is no Map variants Map in the War for the Atlas map series
- There is no Map variants Map in the Atlas of Worlds map series
- There is no Map variants Map in The Awakening map series
- There is no Map variants Map in the Original map series
The above documentation is transcluded from Template:Map variants/doc.
Editors can experiment in this template's sandbox and testcases pages.
Please add categories to the /doc subpage. Subpages of this template.
Editors can experiment in this template's sandbox and testcases pages.
Please add categories to the /doc subpage. Subpages of this template.