Шаблон:Slot skill table row format — различия между версиями

Материал из Guild Wars 2 wiki
Перейти к: навигация, поиск
Строка 1: Строка 1:
<includeonly>|- class="{{lc:{{{5|}}}}} {{{class|}}}"
+
<includeonly>{{#ifeq: {{{5|}}}{{{include tool belt|false}}}|Engineertrue|{{#ifeq: {{{18|}}}|{{#var:last_sort}}||{{Slot skill table row/toolbelt|skill={{#var:last_sort}}}}}}}}<!--
| <span style="vertical-align:middle;">{{#switch: {{#if: {{{chain|}}}|{{lc:{{{chain|}}}}}|{{#if: <!-- tool belts may have more than one skill type-->{{#pos:{{lc:{{{6|}}}}}|tool belt}}|tool belt|{{lc:{{{6|}}}}}}}}}
+
-->{{#ifeq: {{#var:slot skill table}}|true|{{#vardefine:this_profession|{{#if:{{{5|}}}|{{{5}}}|Common}}}}<!--
 +
-->{{#switch: {{#var:header css class{{#var:table id}}}}|<!-- empty, not defined yet-->={{#vardefine:header css class{{#var:table id}}|{{lc:{{{5|}}}}}}}|<!-- same class -->{{lc:{{{5|}}}}}=|<!-- dummy class to distinguish from emtpy -->#default={{#vardefine:header css class{{#var:table id}}|white}}}}<!--
 +
 
 +
Profession subheader
 +
 
 +
-->{{#ifeq: {{#var:showProfessionSubheader|false}}|true
 +
| {{#ifeq: {{#var:this_profession}}{{{6|}}}|{{#var:last_profession}}{{#var:last_specialization}}|<!-- same profession+specialization, do nothing -->
 +
  | {{#vardefine:last_profession|{{#var:this_profession}}}}{{#vardefine:last_specialization|{{{6|}}}}}{{#vardefine:last_type|<!-- new profession section, reset type -->}}
 +
{{!}}- class="{{lc:{{{5|}}}}}"
 +
! colspan="7" {{!}} {{#tag: {{#var:profession heading|h4}}|{{#ifeq: {{{6|}}}|| {{ {{#var:this_profession}} }} [[{{#var:this_profession}}]] | {{ {{{6|}}} }} [[{{{6|}}}]] }} }}
 +
{{!}}-
 +
  }}
 +
}}<!--
 +
 
 +
Type subheader
 +
 
 +
-->{{#ifeq: {{#var:showTypeSubheader|false}}|true
 +
| {{#ifeq: {{{9|}}}|{{#var:last_type}}|<!-- same type, do nothing -->
 +
  | {{#vardefine:last_type|{{{9|}}}}}
 +
{{!}}- class="{{lc:{{{5|}}}}}"
 +
! colspan="7" {{!}} {{#tag: {{#ifeq: {{#var:type heading}} | plain | span | {{#var:type heading|h5}} }} | {{#arraymap:{{{9|}}}|,|@@@|[[@@@]]|,\s}} {{#ifeq: {{#var:showProfessionSubheader|false}}|true||{{#ifeq: {{{6|}}}|<!--empty-->||<small>(requires {{ {{{6|}}} }} [[{{{6|}}}]])</small>}} }} }}
 +
{{!}}-
 +
  }}
 +
}}
 +
}}<!--
 +
 
 +
Slot skill row
 +
 
 +
-->|- class="{{lc:{{{5|}}}}} {{{class|}}}"
 +
| <span style="vertical-align:middle;">{{#switch: {{#if: {{{chain|}}}|{{lc:{{{chain|}}}}}|{{#if: <!-- tool belts may have more than one skill type-->{{#pos:{{lc:{{{8|}}}}}|tool belt}}|tool belt|{{lc:{{{8|}}}}}}}}}
 
  | n | no | none =
 
  | n | no | none =
 
  | chain = [[File:Redirect Arrow.png|25px|link=|Цепочка]]
 
  | chain = [[File:Redirect Arrow.png|25px|link=|Цепочка]]
  | toolbelt | tool belt = [[File:Chain Arrow Toolbelt.png|25px|link=Tool belt|Пояс с инструментами]]
+
  | toolbelt
 +
| tool belt = [[File:Chain Arrow Toolbelt.png|25px|link=Tool belt|Пояс с инструментами]]
 
  | burst = [[File:Chain Arrow Toolbelt.png|25px|link=Burst|Вспышка ярости]]
 
  | burst = [[File:Chain Arrow Toolbelt.png|25px|link=Burst|Вспышка ярости]]
  | primalburst | primal burst = [[File:Chain Arrow Toolbelt.png|25px|link=Primal Burst|Первобытная ярость]]
+
  | primal burst = [[File:Chain Arrow Toolbelt.png|25px|link=Primal Burst|Первобытная ярость]]
  | stealth | stealth attack = [[File:Chain Arrow Toolbelt.png|25px|link=Stealth Attack|Атака невидимки]]
+
  | stealth =
 +
| stealth attack = [[File:Chain Arrow Toolbelt.png|25px|link=Stealth Attack|Атака невидимки]]
 
  | ambush = [[File:Chain Arrow Toolbelt.png|25px|link=Ambush|Засада]]
 
  | ambush = [[File:Chain Arrow Toolbelt.png|25px|link=Ambush|Засада]]
  | #default = {{#ifexpr: ({{#if:{{{13|}}}|{{{13|}}}|1}} > 1) AND ({{#if:{{{13|}}}|{{{13|}}}|5}} < 5)|[[File:Redirect Arrow.png|25px|link=|Цепочка]]}}
+
| fire = [[File:Parent arrow.png|25px|link=]][[File:Fire Attunement.png|25px|link=Fire Attunement]]
}}{{borderless|{{#sub:{{{3|}}}|5}}|25|link={{{1}}}}}&nbsp;[[{{{1}}}|{{{2|}}}]]</span>  
+
| water = [[File:Parent arrow.png|25px|link=]][[File:Water Attunement.png|25px|link=Water Attunement]]
{{#ifeq:{{#var:showType}}|true|
+
| air = [[File:Parent arrow.png|25px|link=]][[File:Air Attunement.png|25px|link=Air Attunement]]
{{!}} {{#if:{{{6|}}}|{{#arraymap:{{{6}}}|,|@@@|[[@@@|{{rus lang|skill type|@@@}}]]|,&#32;}} }} }}
+
| earth = [[File:Parent arrow.png|25px|link=]][[File:Earth Attunement.png|25px|link=Earth Attunement]]
| style="text-align:center;" | {{#ifeq:{{{14}}}|Y|[[File:Ground_target_aim.png|18px|Прицеливание на землю|link=Targeting#Прицеливание на землю]]}}
+
| celestial = [[File:Parent arrow.png|25px|link=]][[File:Celestial Avatar.png|25px|link=Celestial Avatar]]
| style="text-align:center;" | {{#switch:{{{10|}}}|N|Land only=[[File:Not available underwater.png|20px|link=Underwater mode#Подводные умения|Недоступно под водой]]|Underwater only=[[File:Underwater.png|link=Underwater mode#Подводные умения|Подводное умение]]}}
+
| non_cele = [[File:Parent arrow.png|25px|link=]][[File:Release Celestial Avatar.png|25px|link=Celestial Avatar]]
| style="text-align:center;" data-sort-value="{{{8|0}}}"  | {{fraction|{{{8|}}}}}
+
  | #default = {{#if: {{#var:last_sequence}}{{#var:last_sort}}<!-- checking if empty due to #var caching bug -->
{{#ifeq:{{#var:showEnergy}}|true|{{!}} style="text-align:center;" data-sort-value="{{{11|0}}}" {{!}} {{{11|}}}{{#if:{{{11|}}}|{{#if:{{{12|}}}|&nbsp;/&nbsp;}}}}{{{12|}}} }}
+
              | <!-- automatic  -->{{#if: {{#ifeq: {{{17|}}}|{{#var:last_sequence}}|+|<!-- fallback, same skill sort name -->{{#ifeq:{{{18|}}}|{{#var:last_sort}}|+}}}}<!--
| style="text-align:center;" data-sort-value="{{{9|0}}}" | {{fraction|{{{9|}}}}}
+
                                  -->| {{#ifexpr: {{#if:{{{10|}}}|{{{10|}}}|1}} > 1|[[File:Redirect Arrow.png|25px|link=|Chain]]}}}}
| {{{4|}}}
+
              | <!-- manual case -->{{#ifexpr: {{#if:{{{10|}}}|{{{10|}}}|1}} > 1|[[File:Redirect Arrow.png|25px|link=|Chain]]}}}}
 +
              }}{{#vardefine:last_sequence|{{{17|}}}}}{{#vardefine:last_sort|{{{18|}}}}}<!--
 +
--><span style="overflow: hidden; width: 25px; height: 25px; display:inline-block; vertical-align:middle;"><span style="margin: -4px; overflow: hidden; display: inline-block;">[[{{{3|}}}|33x33px|link={{{1}}}]]</span></span>&nbsp;[[{{{1}}}|{{{2|}}}]]</span>
 +
{{#ifeq:{{#var:showType}}|true|{{!!}} {{#if:{{{8|}}}|{{#arraymap:{{{8}}}|,|@@@|[[@@@]]|,\s}} }} }}
 +
| style="text-align:center;" | {{#ifeq:{{{20}}}|Y|[[File:Ground_target_aim.png|18px|Прицеливание на землю|link=Targeting#Прицеливание на землю]]}}
 +
| style="text-align:center;" | {{#switch:{{{16|}}}|Land only=[[File:Not available underwater.png|20px|link=Underwater mode#Подводные умения|Недоступно под водой]]|Underwater only=[[File:Underwater.png|link=Underwater mode#Подводные умения|Подводное умение]]}}
 +
| style="text-align:center;" | {{fraction|{{{11|}}}}}
 +
{{#ifeq:{{#var:showEnergy}}|true|{{!}} style="text-align:center;" {{!}} {{{14|}}}{{#if:{{{14|}}}|{{#if:{{{15|}}}|&nbsp;/&nbsp;}}}}{{{15|}}} }}
 +
| style="text-align:center;" | {{fraction|{{{12|}}}}}
 +
| style="padding-left:2em" | {{{4|}}}
 
</includeonly><noinclude>
 
</includeonly><noinclude>
Called as a semantic result template by [[Template:Slot skill table row]].
+
Called as a semantic result template by [[Template:Slot skill table row]] and [[Template:Slot skill table]].
  
 
=== Input parameter list ===
 
=== Input parameter list ===
# PAGENAME
+
# Skill                                <!-- 1 -->
# Has canonical name
+
# Has canonical name                   <!-- 2 -->
# Has game icon
+
# Has game icon                       <!-- 3 -->
# Has game description
+
# Has game description                 <!-- 4 -->
# Is for profession
+
# Is for profession                   <!-- 5 -->
# Has skill type
+
# Is for specialization                <!-- 6 -->
# Has training hero point cost
+
# Has skill context                    <!-- 7 -->
# Has activation time
+
# Has skill type                      <!-- 8 -->
# Has recharge time
+
# Has skill type sort order            <!-- 9 -->
# Is usable underwater
+
# Has chain sequence position          <!--10 -->
# Has energy cost
+
# Has activation time                 <!--11 -->
# Has upkeep cost
+
# Has recharge time                   <!--12 -->
# Has chain sequence position
+
# Has initiative cost                  <!--13 -->
# Is ground targeted
+
# Has energy cost                     <!--14 -->
 +
# Has upkeep cost                     <!--15 -->
 +
# Is usable underwater                <!--16 -->
 +
# Has chain sequence                   <!--17 -->
 +
# Has skill sort order                <!--18 -->
 +
# Has ammunition number                <!--19 -->
 +
# Is ground targeted                   <!--20 -->
  
 
[[Category:Skill formatting templates]]
 
[[Category:Skill formatting templates]]
 
[[Category:Semantic result templates]]
 
[[Category:Semantic result templates]]
 +
</noinclude>

Версия 10:19, 5 января 2024

Called as a semantic result template by Template:Slot skill table row and Template:Slot skill table.

Input parameter list

  1. Skill
  2. Has canonical name
  3. Has game icon
  4. Has game description
  5. Is for profession
  6. Is for specialization
  7. Has skill context
  8. Has skill type
  9. Has skill type sort order
  10. Has chain sequence position
  11. Has activation time
  12. Has recharge time
  13. Has initiative cost
  14. Has energy cost
  15. Has upkeep cost
  16. Is usable underwater
  17. Has chain sequence
  18. Has skill sort order
  19. Has ammunition number
  20. Is ground targeted