Шаблон:Skill list by property — различия между версиями

Материал из Guild Wars 2 wiki
Перейти к: навигация, поиск
Строка 1: Строка 1:
<includeonly><!--
+
<includeonly>{{#vardefine:last_profession|}}{{#vardefine:slbp cnt|{{#expr:{{#var:slbp cnt|0}}+1}}}}<!-- purge last profession from previous template call, define unique id variable
  
 
-->{{#vardefine: smw-empty-query-warning|{{#ifeq: {{{warning|true}}}|false|<!-- no warning -->|{{#if: {{NAMESPACE}}||[[Category:Pages with empty semantic mediawiki query results]]}}}}}}<!--
 
-->{{#vardefine: smw-empty-query-warning|{{#ifeq: {{{warning|true}}}|false|<!-- no warning -->|{{#if: {{NAMESPACE}}||[[Category:Pages with empty semantic mediawiki query results]]}}}}}}<!--
Строка 24: Строка 24:
 
  | {{#switch: {{ucfirst:{{{1|}}}}} | Profession mechanic = ?Is for weapon | Pet = ?Is for pet | Profession = ?Is for weapon}} <!-- 9 -->
 
  | {{#switch: {{ucfirst:{{{1|}}}}} | Profession mechanic = ?Is for weapon | Pet = ?Is for pet | Profession = ?Is for weapon}} <!-- 9 -->
 
  | format = template
 
  | format = template
  | template = Skill list by property result format{{!}}suffix={{{suffix|type}}}
+
  | template = Skill list by property result format{{!}}suffix={{{suffix|type}}}{{!}}context={{ucfirst:{{{1|}}}}}
  | intro = {{{intro|}}}
+
  | intro = {{{intro|}}}{{#if: {{{heading|}}}|<nowiki/>
 +
<div id="{{{id|skilllist}}}"><{{{heading level|h3}}} class="filter-plain {{#var_final: p-{{ucfirst:{{{1|}}}}}-{{#var:slbp cnt}} }} f-{{ucfirst:{{{1|}}}}}">{{{heading|}}}</{{{heading level|h3}}}></div>}}<ul id="{{{id|skilllist}}}" style="margin-top:0em;">
 +
| outro = </ul>
 
  | link = none
 
  | link = none
 
  | sort = {{#switch: {{ucfirst:{{{1|}}}}}
 
  | sort = {{#switch: {{ucfirst:{{{1|}}}}}
Строка 132: Строка 134:
 
;intro
 
;intro
 
: Optional. Intro text.
 
: Optional. Intro text.
 +
;heading
 +
: Optional. Intro heading. This will internally set filter classes for {{tl|related skills filter}}.
 +
;heading level
 +
: Optional. Intro heading level, defaults to h3.
 
;default
 
;default
 
: Optional. Default text.
 
: Optional. Default text.

Версия 02:30, 11 марта 2022

Description

This template returns a list of skills of a certain semantic mediawiki skill property, e.g. ground-targeting: [[Is ground targeted::Y]]. Format using {{Skill list by property result format}}.

Related templates
Usage Skill templates Trait templates Description
Section {{Related skills}} {{Related traits}} These templates list all related skills/traits based on {{skill fact}} and on the {{trait infobox}} improves parameters. They create subsection headings automatically.
Subsection {{Skill list}} {{Trait list}} These templates list all related skills of a certain context (e.g. weapon, utility)/traits based on {{skill fact}}
{{Skill list by property}} {{Trait list by property}} These templates list all related skills/traits based on a smw query, e.g. based on the {{trait infobox}} improves parameters.
Inline {{Trait list entry}} This template displays the profession icon, trait icon, trait, trait line and trait description.

Usage

{{Skill list by property|Weapon|<query>}}
{{Skill list by property|Bundle|<query>}}
{{Skill list by property|Transform|<query>}}
{{Skill list by property|Healing|<query>}}
{{Skill list by property|Utility|<query>}}
{{Skill list by property|Elite|<query>}}
{{Skill list by property|Profession mechanic|<query>}}
{{Skill list by property|Pet|<query>}}
{{Skill list by property|Downed|<query>}}
{{Skill list by property|Drowning|<query>}}
{{Skill list by property|Trait|<query>}}
{{Skill list by property|Racial|<query>}}
{{Skill list by property|Common|<query>}}
{{Skill list by property|Profession|<query>}}
{{Skill list by property|Monster|<query>}}

Copy-and-paste code

=== [[Weapon]] skills ===
{{Skill list by property|Weapon}}
=== [[Bundle]] skills ===
{{Skill list by property|Bundle}}
=== [[Transform]] skills ===
{{Skill list by property|Transform}}
=== [[Healing skill]]s ===
{{Skill list by property|Healing}}
=== [[Utility skill]]s ===
{{Skill list by property|Utility}}
=== [[Elite skill]]s ===
{{Skill list by property|Elite}}
=== [[Profession mechanic]] skills ===
{{Skill list by property|Profession mechanic}}
=== [[List of pet skills|Pet]] skills ===
{{Skill list by property|Pet}}
=== [[List of downed skills|Downed]] skills ===
{{Skill list by property|Downed}}
=== [[List of drowning skills|Drowning]] skills ===
{{Skill list by property|Drowning}}
=== [[List of trait skills|Trait]] skills ===
{{Skill list by property|Trait}}
=== [[Racial skill]]s ===
{{Skill list by property|Racial}}
=== Common skills ===
{{Skill list by property|Common}}

Parameters

1 (unnamed parameter)
Required. Skill context: "Weapon", "Bundle", "Transform", "Healing", "Utility", "Elite", "Profession mechanic", "Pet", "Downed", "Drowning", "Trait".
Additional option, by skill supertype: "Profession" (displays all profession skills without specifing any skill context), "Racial", "Common" and "Monster".
2 (unnamed parameter)
Required. Query to select the skills.
suffix
Optional. Either "type" (default, weapon or skill type), "none", "description" or "trait" (matching {{trait list}}, trait parent and description).
intro
Optional. Intro text.
heading
Optional. Intro heading. This will internally set filter classes for {{related skills filter}}.
heading level
Optional. Intro heading level, defaults to h3.
default
Optional. Default text.

Example

{{Skill list by property|Weapon|[[Is ground targeted::Y]]}}