Шаблон:Trait infobox — различия между версиями
Материал из Guild Wars 2 wiki
Blood (обсуждение | вклад) |
Blood (обсуждение | вклад) |
||
Строка 1: | Строка 1: | ||
− | {{infobox status|{{{status|{{#ifeq:{{{historical|n}}}|y|historical}} }}} }}{{#if: | + | {{infobox status|{{{status|{{#ifeq:{{{historical|n}}}|y|historical}} }}} }}{{infobox release|{{{release|}}} }}{{#if: |
{{#vardefine:traitline| {{ifexists|{{{line}}} (specialization)|{{{line}}} (specialization)|{{{line|Profession}}}}} }} | {{#vardefine:traitline| {{ifexists|{{{line}}} (specialization)|{{{line}}} (specialization)|{{{line|Profession}}}}} }} | ||
{{#vardefine:profession| {{lc:{{#show:{{#var:traitline}}|?Is for profession|link=none|default=Any}}}} }} | {{#vardefine:profession| {{lc:{{#show:{{#var:traitline}}|?Is for profession|link=none|default=Any}}}} }} | ||
Строка 31: | Строка 31: | ||
}}{{#if:{{{id|}}} | | }}{{#if:{{{id|}}} | | ||
; Игр. ссылка | ; Игр. ссылка | ||
− | : {{#arraymap:{{{id}}}|,|@@@|{{trait link|@@@}}{{#set:Has game id=@@@}}|<br>}}}} | + | : {{#arraymap:{{{id}}}|,|@@@|{{trait link|@@@}}{{#set:Has game id=@@@}}|<br>}} |
+ | }}{{#if: {{{id|}}} | {{#switch: {{{status|{{#ifeq:{{{historical|n}}}|y|historical}}}}} | unimplemented | unimplemented | temporary | historical = | #default = | ||
+ | ; Внеш. ссылки | ||
+ | : [https://api.guildwars2.com/v2/traits?ids={{{id}}} API] | ||
+ | }} }} | ||
</div> | </div> | ||
{{clear}}{{#set:Has context=Trait}} | {{clear}}{{#set:Has context=Trait}} | ||
Строка 108: | Строка 112: | ||
; categorize : Optional. "y" or "n" to turn on/off categorization. Default is on for main namespace articles and off for others. If using "status", don't set this parameter. | ; categorize : Optional. "y" or "n" to turn on/off categorization. Default is on for main namespace articles and off for others. If using "status", don't set this parameter. | ||
; status : Optional. Status of content. Only set if not currently obtainable ingame, displays relevant notice. Available options: "historical", "future", "unimplemented", "current" (default). | ; status : Optional. Status of content. Only set if not currently obtainable ingame, displays relevant notice. Available options: "historical", "future", "unimplemented", "current" (default). | ||
+ | ; release : Optional. The expansion or living world season required to access the content. Displays a notice of the release. See {{tl|infobox release}} for options. | ||
; historical : Optional. (legacy parameter). Duplicates function of setting <code>status = historical</code>. ''y'' displays the {{tl|historical content}} notice. | ; historical : Optional. (legacy parameter). Duplicates function of setting <code>status = historical</code>. ''y'' displays the {{tl|historical content}} notice. | ||
[[Category:Infobox templates]] | [[Category:Infobox templates]] | ||
</noinclude> | </noinclude> |
Версия 22:38, 24 февраля 2017
“Описание отсутствует.
— Внутриигровое описание
Description
{{Trait infobox | name = | icon = | line = | tier = | type = | recharge = | description = | facts = | id = }}
Parameters
- name
- Optional. Trait name. Defaults to the page name.
- icon
- Optional. Icon filename. Defaults to
File:<page name>.png
. - line
- Required. The trait line that the trait is under.
- tier
- Required. The tier (Proficiency elite spec only, Adept, Master, Grandmaster) of the trait; displays Unspecified if omitted.
- type
- Required. The trait type (Minor or Major); displays Unspecified if omitted.
- position
- Required. The vertical position of the trait within the main trait selection panel.
- recharge
- Optional. The trait's recharge time, if any.
- description
- Required. The in-game description.
- facts
- Optional. The trait facts displayed in-game below the description. Each fact should be presented as an individual instance of the {{skill fact}} template.
- id
- Optional. The game id required to produce the chat link to the trait ingame.
- categorize
- Optional. "y" or "n" to turn on/off categorization. Default is on for main namespace articles and off for others. If using "status", don't set this parameter.
- status
- Optional. Status of content. Only set if not currently obtainable ingame, displays relevant notice. Available options: "historical", "future", "unimplemented", "current" (default).
- release
- Optional. The expansion or living world season required to access the content. Displays a notice of the release. See {{infobox release}} for options.
- historical
- Optional. (legacy parameter). Duplicates function of setting
status = historical
. y displays the {{historical content}} notice.