Difference between revisions of "Template:Transient icon"
Jump to navigation
Jump to search
m (Mrquiggles moved page Template:Companion icon to Template:Transient icon) |
|||
Line 3: | Line 3: | ||
[[{{{subobject}}}]] | [[{{{subobject}}}]] | ||
| | | | ||
[[Has game context:: | [[Has game context::Transient]] | ||
[[Has lowercase English name::{{lc:{{{1|}}}}}]] | [[Has lowercase English name::{{lc:{{{1|}}}}}]] | ||
{{#if:{{{rarity|}}}|[[Has rarity::{{{rarity}}}]]}} | {{#if:{{{rarity|}}}|[[Has rarity::{{{rarity}}}]]}} | ||
Line 9: | Line 9: | ||
{{#if:{{{energy|}}}|[[Has energy::{{{energy}}}]]}} | {{#if:{{{energy|}}}|[[Has energy::{{{energy}}}]]}} | ||
}} | }} | ||
|?= | |?=Transient icon subobject | ||
|?Has English name | |?Has English name | ||
|?Has icon | |?Has icon | ||
Line 17: | Line 17: | ||
|?Has variant | |?Has variant | ||
|format=template | |format=template | ||
|template= | |template=Transient icon result format | ||
|userparam=frame=y,size={{#switch:{{lc:{{{size|small}}}}}| | |userparam=frame=y,size={{#switch:{{lc:{{{size|small}}}}}| | ||
| medium = medium | | medium = medium | ||
Line 45: | Line 45: | ||
[[{{{subobject}}}]] | [[{{{subobject}}}]] | ||
| | | | ||
[[Has game context:: | [[Has game context::Transient]] | ||
[[Has lowercase English name::{{lc:{{{1|}}}}}]] | [[Has lowercase English name::{{lc:{{{1|}}}}}]] | ||
{{#if:{{{rarity|}}}|[[Has rarity::{{{rarity}}}]]}} | {{#if:{{{rarity|}}}|[[Has rarity::{{{rarity}}}]]}} | ||
Line 51: | Line 51: | ||
{{#if:{{{energy|}}}|[[Has energy::{{{energy}}}]]}} | {{#if:{{{energy|}}}|[[Has energy::{{{energy}}}]]}} | ||
}} | }} | ||
|?= | |?=Transient icon subobject | ||
|?Has English name | |?Has English name | ||
|?Has icon | |?Has icon | ||
|?Has variant | |?Has variant | ||
|format=template | |format=template | ||
|template= | |template=Transient icon result format | ||
|userparam=frame=n,size={{#switch:{{lc:{{{size|small}}}}}| | |userparam=frame=n,size={{#switch:{{lc:{{{size|small}}}}}| | ||
| medium = medium | | medium = medium | ||
Line 77: | Line 77: | ||
| large = [[File:Unknown icon.png|link={{{link|}}}]] | | large = [[File:Unknown icon.png|link={{{link|}}}]] | ||
| small | | small | ||
|#default=[[File:Unknown icon.png|20x20px|link={{{link|}}}]]{{#if:{{{link|}}}|[[{{{link}}}|{{{1|Unknown}}}]]|[[{{{1}}}|{{{1|Unknown}}}]]}}{{#if:{{{link|}}}||[[Category:List of invalid | |#default=[[File:Unknown icon.png|20x20px|link={{{link|}}}]]{{#if:{{{link|}}}|[[{{{link}}}|{{{1|Unknown}}}]]|[[{{{1}}}|{{{1|Unknown}}}]]}}{{#if:{{{link|}}}||[[Category:List of invalid Transient icon template calls]]}} | ||
}}<!-- end switch --> | }}<!-- end switch --> | ||
}}<!-- end ask (no frame) --> | }}<!-- end ask (no frame) --> | ||
Line 83: | Line 83: | ||
== Description == | == Description == | ||
This template displays a link to a | This template displays a link to a transient together with its icon. If multiple transients would fit the search criteria, only the one with the lowest rarity of the standard variant is displayed. | ||
== Usage == | == Usage == | ||
<pre>{{ | <pre>{{Transient icon | ||
|<en | |<en transient name> | ||
| rarity = | | rarity = | ||
| variant = | | variant = | ||
Line 98: | Line 98: | ||
=== Parameters === | === Parameters === | ||
; en | ; en transient name : Required. Name of the transient | ||
; rarity : Filter result by the rarity of the | ; rarity : Filter result by the rarity of the transient. | ||
; energy : Filter result by the energy of the | ; energy : Filter result by the energy of the transient. | ||
; variant : Filter result by the variant of the | ; variant : Filter result by the variant of the transient. | ||
; frame : Set to ''y'' to also display a frame with rarity, energy and weapon type of the | ; frame : Set to ''y'' to also display a frame with rarity, energy and weapon type of the transient, ''n'' to only display the icon. Defaults to ''n''. | ||
; size : Set to ''small'', ''medium'' or ''large'' to change the size of the icon. When set to ''small'', also displays the | ; size : Set to ''small'', ''medium'' or ''large'' to change the size of the icon. When set to ''small'', also displays the transient's English name. Defaults to ''small''. | ||
; link : Page that the icon should link to. Defaults to the page of the | ; link : Page that the icon should link to. Defaults to the page of the transient. | ||
; show name : Set to ''y'' to show the name, ''n'' to hide. Defaults to ''y'' if '''size''' is set to ''small'', ''n'' otherwise. | ; show name : Set to ''y'' to show the name, ''n'' to hide. Defaults to ''y'' if '''size''' is set to ''small'', ''n'' otherwise. | ||
; subobject : Subobject of the | ; subobject : Subobject of the transient. Can be used by other templates to directly display the correct transient. Do not use this parameter manually. | ||
=== Examples === | === Examples === | ||
<pre>{{ | <pre>{{Transient icon|Moritaka}}</pre> | ||
{{ | {{Transient icon|Moritaka}} | ||
<pre>{{ | <pre>{{Transient icon|Moritaka|size=large}}</pre> | ||
{{ | {{Transient icon|Moritaka|size=large}} | ||
<pre>{{ | <pre>{{Transient icon|Moritaka|size=medium|frame=y}}</pre> | ||
{{ | {{Transient icon|Moritaka|size=medium|frame=y}} | ||
<pre>{{ | <pre>{{Transient icon|Moritaka|rarity=4}}</pre> | ||
{{ | {{Transient icon|Moritaka|rarity=4}} | ||
<pre>{{ | <pre>{{Transient icon|Moritaka|variant=Valentine|frame=y}}</pre> | ||
{{ | {{Transient icon|Moritaka|variant=Valentine|frame=y}} | ||
[[Category:Formatting templates]]</noinclude> | [[Category:Formatting templates]]</noinclude> |
Revision as of 20:31, 20 August 2018
Description
This template displays a link to a transient together with its icon. If multiple transients would fit the search criteria, only the one with the lowest rarity of the standard variant is displayed.
Usage
{{Transient icon |<en transient name> | rarity = | variant = | link = | energy = | subobject = | show name = }}
Parameters
- en transient name
- Required. Name of the transient
- rarity
- Filter result by the rarity of the transient.
- energy
- Filter result by the energy of the transient.
- variant
- Filter result by the variant of the transient.
- frame
- Set to y to also display a frame with rarity, energy and weapon type of the transient, n to only display the icon. Defaults to n.
- size
- Set to small, medium or large to change the size of the icon. When set to small, also displays the transient's English name. Defaults to small.
- link
- Page that the icon should link to. Defaults to the page of the transient.
- show name
- Set to y to show the name, n to hide. Defaults to y if size is set to small, n otherwise.
- subobject
- Subobject of the transient. Can be used by other templates to directly display the correct transient. Do not use this parameter manually.
Examples
{{Transient icon|Moritaka}}
{{Transient icon|Moritaka|size=large}}
{{Transient icon|Moritaka|size=medium|frame=y}}
{{Transient icon|Moritaka|rarity=4}}
{{Transient icon|Moritaka|variant=Valentine|frame=y}}