From Brotato Wiki

(Add support for passing the character name (mainly done so we can show a working preview))
m (use min-width:100px)
 
(2 intermediate revisions by the same user not shown)
Line 3: Line 3:
<!-- Item or weapon -->
<!-- Item or weapon -->
{{#switch: {{lc:{{Character Data|{{{1|{{PAGENAME}}}}}|unlocktype}}}}
{{#switch: {{lc:{{Character Data|{{{1|{{PAGENAME}}}}}|unlocktype}}}}
  | item    = {{Iconbox|{{Character Data|{{{1|{{PAGENAME}}}}}|unlocks}}|rarity={{Item Data|{{Character Data|{{{1|{{PAGENAME}}}}}|unlocks}}|rarity}}}}
  | item    = {{Iconbox|{{Character Data|{{{1|{{PAGENAME}}}}}|unlocks}}|rarity={{Item Data|{{Character Data|{{{1|{{PAGENAME}}}}}|unlocks}}|rarity}}|maxwidth=110px}}
  | weapon  = {{Iconbox|{{Character Data|{{{1|{{PAGENAME}}}}}|unlocks}}|rarity={{Weapon Data|{{Character Data|{{{1|{{PAGENAME}}}}}|unlocks}}|rarity}}}}
  | weapon  = {{Iconbox|{{Character Data|{{{1|{{PAGENAME}}}}}|unlocks}}|rarity={{Weapon Data|{{Character Data|{{{1|{{PAGENAME}}}}}|unlocks}}|rarity}}|maxwidth=110px}}
  | #default = Error: "unlocktype" was not specified for "{{{1|{{PAGENAME}}}}}" in [[Template:Character_Data]]<!--
  | #default = Error: "unlocktype" was not specified for "{{{1|{{PAGENAME}}}}}" in [[Template:Character_Data]]<!--
-->}}</onlyinclude></includeonly><noinclude>
-->}}</onlyinclude></includeonly><noinclude>


== Example ==
Inserts content on a [[Characters|Character]] page, showing their unlock.
 
== Usage ==


Use on character pages:
Use on character pages:
Line 17: Line 19:


<pre>{{CharacterUnlocks|Well Rounded}}</pre>
<pre>{{CharacterUnlocks|Well Rounded}}</pre>
== Example ==


'''Example output is directly below (including the heading):'''
'''Example output is directly below (including the heading):'''


{{CharacterUnlocks|Well Rounded}}
{{CharacterUnlocks|Well Rounded}}
{{CharacterUnlocks|Crazy}}

Latest revision as of 01:07, 10 November 2022


Inserts content on a Character page, showing their unlock.

Usage

Use on character pages:

{{CharacterUnlocks}}

Use anywhere:

{{CharacterUnlocks|Well Rounded}}

Example

Example output is directly below (including the heading):

Unlocks

Unlocks Potato if you win a game with Well Rounded:

Unlocks

Unlocks Hunting Trophy if you win a game with Crazy: