Difference between revisions of "Related"
Stratonian (talk | contribs) m (formatting) |
Stratonian (talk | contribs) m |
||
(20 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
− | <includeonly | + | <includeonly>{{#if:{{{notext|}}}||<!-- only display below text if 'notext' isn't used --> |
− | |||
==Related== | ==Related== | ||
− | The following can affect (or are affected by) a character's {{ | + | The following can affect (or are affected by) a character's {{sc|{{ambiguate|{{{2}}}}}}}. |
}} | }} | ||
{{#arraydefine:categories|{{{1}}}}}<!-- split comma-separated list into array | {{#arraydefine:categories|{{{1}}}}}<!-- split comma-separated list into array | ||
Line 11: | Line 10: | ||
==={{#var:category}}=== | ==={{#var:category}}=== | ||
}} | }} | ||
− | {{#switch:{{#var:category}}<!-- | + | {{#vardefine:result<!-- define result |
+ | -->|{{#switch:{{#var:category}}<!-- switch the table used based upon the category | ||
-->|Skills=<!-- Category:Skills | -->|Skills=<!-- Category:Skills | ||
-->{{#ask: [[Category:{{#var:category}}]]<!-- get pages in corresponding category | -->{{#ask: [[Category:{{#var:category}}]]<!-- get pages in corresponding category | ||
-->{{#ifeq:{{{2|}}}|{{{2}}}<!-- if second parameter exists | -->{{#ifeq:{{{2|}}}|{{{2}}}<!-- if second parameter exists | ||
− | -->|[[Has stat::{{# | + | -->|[[Has stat::?;?;{{#replace:{{sc|{{{2}}}}}| |_}}]]}}<!-- only get pages with corresponding stat --> |
− | | ?Has icon | + | |?Has icon |
− | | ?Has skill name | + | |?Has skill name |
− | | ?Has cast time | + | |?Has cast time |
− | | ?Has range | + | |?Has range |
− | | ?Has cost | + | |?Has cost |
− | | ?Has cost type | + | |?Has cost type |
− | | ?Has cooldown | + | |?Has cooldown |
− | | ?Is for hero | + | |?Is for hero |
− | | ?Has mastery | + | |?Has mastery |
− | | ?Has skill order | + | |?Has skill order |
− | | sort=Has skill order | + | |sort=Has skill order |
− | | order=asc | + | |order=asc |
− | | format=template | + | |format=template |
− | | template= | + | |introtemplate=Skill table header |
− | | | + | |template=Skill table body |
− | | | + | |outrotemplate=Table footer |
+ | |link=none | ||
}} | }} | ||
|Passive Talents=<!-- Category:Passive talents | |Passive Talents=<!-- Category:Passive talents | ||
-->{{#ask: [[Category:{{#var:category}}]]<!-- get pages in corresponding category | -->{{#ask: [[Category:{{#var:category}}]]<!-- get pages in corresponding category | ||
-->{{#ifeq:{{{2|}}}|{{{2}}}<!-- if second parameter exists | -->{{#ifeq:{{{2|}}}|{{{2}}}<!-- if second parameter exists | ||
− | -->|[[Has stat::{{# | + | -->|[[Has stat::?;?;{{#replace:{{sc|{{{2}}}}}| |_}}]]}}<!-- only get pages with corresponding stat --> |
− | | ?Has | + | |?Has icon |
− | | ?Has | + | |?Has branch |
− | | ?Has | + | |?Has tier |
− | | format=template | + | |format=template |
− | | template= | + | |introtemplate=Talent table header |
− | | | + | |template=Talent table body |
− | | | + | |outrotemplate=Table footer |
+ | |link=none | ||
}} | }} | ||
|#default={{error|Invalid category. Check documentation.}}<!-- invalid category error | |#default={{error|Invalid category. Check documentation.}}<!-- invalid category error | ||
− | -->}}}}</includeonly><noinclude>{{{{PAGENAME}}/Documentation}}</noinclude> | + | -->}}}} |
+ | {{#if:{{#var:result}}|{{#var:result}}|'''No {{#var:category}}.'''}}}}</includeonly><noinclude>{{{{PAGENAME}}/Documentation}}</noinclude> |
Latest revision as of 21:03, 1 June 2024
Description[edit]
Displays a stylized list of all pages in the specified categories that contain the specified Stat.
Usage[edit]
{{Related|<category/categories>|<stat>|<notext=notext>}}
Parameters[edit]
notext: Whether or not to include descriptor text.
- Optional.
- Notes: If not set, the following text will display:
==Related== The following can affect (or are affected by) a character's {{{2}}}.
[For each category, a stylized list and accompanying subheading will display.]
Errors[edit]
Invalid category. Check documentation.