Difference between revisions of "Template:Transient extended infobox"

From Tokyo Afterschool Summoners
Jump to navigation Jump to search
Line 407: Line 407:
}}
}}
{{#vardefine:strategy|{{#ifexist:{{{en name|}}}/Strategy|{{{en name|}}}/Strategy|}}}}
{{#vardefine:strategy|{{#ifexist:{{{en name|}}}/Strategy|{{{en name|}}}/Strategy|}}}}
{{#vardefine:enemy|{{#ifexist:{{{en name|}}}/Enemy|{{{en name|}}}/Enemy|}}}}
{{#vardefine:transient id|{{{id|{{#if:{{{jp title|}}}|{{#masterdata:Card|{{{jp title|}}}|id:name.title}}}}}}}}}
{{#vardefine:transient id|{{{id|{{#if:{{{jp title|}}}|{{#masterdata:Card|{{{jp title|}}}|id:name.title}}}}}}}}}
{{#ifexpr:{{#var:transient id|}}<2|{{#vardefine:transient id|}}}}
{{#ifexpr:{{#var:transient id|}}<2|{{#vardefine:transient id|}}}}
Line 430: Line 431:
| Has icon = {{#ifexist:File:{{{icon|}}}.png|File:{{{icon}}}.png|{{#ifexist:File:{{{en name}}}{{#if:{{{variant|}}}|_{{{variant}}}|}}_{{{rarity}}}star_icon.png|File:{{{en name}}}{{#if:{{{variant|}}}|_{{{variant}}}|}}_{{{rarity}}}star_icon.png|File:Unknown icon.png}}}}
| Has icon = {{#ifexist:File:{{{icon|}}}.png|File:{{{icon}}}.png|{{#ifexist:File:{{{en name}}}{{#if:{{{variant|}}}|_{{{variant}}}|}}_{{{rarity}}}star_icon.png|File:{{{en name}}}{{#if:{{{variant|}}}|_{{{variant}}}|}}_{{{rarity}}}star_icon.png|File:Unknown icon.png}}}}
| Has strategy = {{#var:strategy|}}
| Has strategy = {{#var:strategy|}}
| Has enemies = {{#var:enemy|}}
| Has rarity ={{#ifeq: {{{rarity|0}}} | 0 | 0 | {{{rarity}}} }}
| Has rarity ={{#ifeq: {{{rarity|0}}} | 0 | 0 | {{{rarity}}} }}
| Has card cost ={{#ifeq: {{{cost|0}}} | 0 | 0 | {{{cost}}} }}
| Has card cost ={{#ifeq: {{{cost|0}}} | 0 | 0 | {{{cost}}} }}
Line 1,028: Line 1,030:
     <tr>
     <tr>
       <th colspan="3">[[{{#var:strategy}}|Strategy]]</th>
       <th colspan="3">[[{{#var:strategy}}|Strategy]]</th>
    </tr>
    </table>
  |}}
  {{#if:{{#var:enemy|}}|
    <table class="data transientInfo{{#var:transientnumber}}">
    <tr>
      <th colspan="3">[[{{#var:enemy}}|Enemy-only]]</th>
     </tr>
     </tr>
     </table>
     </table>

Revision as of 18:21, 7 September 2019

Description

This templates creates an infobox and subobject for a Transient. Please do not directly invoke this template.

An example to feed override parameters (such as translation names) are:

{{#vardefine:transient en name|Name}}
{{#vardefine:transient en title|Title}}
{{#vardefine:transient availability|Available}}
{{#vardefine:transient acquisition|Gacha}}
{{#vardefine:transient en jingi|Charge Skill Name}}
{{#vardefine:transient species|Species}}
{{#vardefine:transient gate|Gate Name}}
{{#vardefine:transient jp en research file|Translation for Japanese Research File}}

To invoke this template properly, use (after the vardefines):

{{#masterdata:Card|CARDID}}

Consult other transient pages for additional undocumented options.