Template:Rarity: Difference between revisions

From FHX Wiki
No edit summary
No edit summary
 
Line 1: Line 1:
<includeonly>{{#switch:{{{1}}}|normal=[[{{#ifexist:{{{2}}}|{{{2}}}|Item Rarity}}|<span style="color:#FFF;background-color:#AAA;padding:4px;">'''{{#if:{{{2|}}}|{{{2}}}|{{{1}}}}}'''</span>]]|magic=[[{{#ifexist:{{{2}}}|{{{2}}}|Item Rarity}}|<span style="color:#0FF;background-color:#AAA;padding:4px;">'''{{#if:{{{2|}}}|{{{2}}}|{{{1}}}}}'''</span>]]|rare=[[{{#ifexist:{{{2}}}|{{{2}}}|Item Rarity}}|<span style="color:#FF0;background-color:#AAA;padding:4px;">'''{{#if:{{{2|}}}|{{{2}}}|{{{1}}}}}'''</span>]]|soul=[[{{#ifexist:{{{2}}}|{{{2}}}|Item Rarity}}|<span style="color:#DAA949;background-color:#AAA;padding:4px;">'''{{#if:{{{2|}}}|{{{2}}}|{{{1}}}}}'''</span>]]|unique=[[{{#ifexist:{{{2}}}|{{{2}}}|Item Rarity}}|<span style="color:#050;background-color:#AAA;padding:4px;">'''{{#if:{{{2|}}}|{{{2}}}|{{{1}}}}}'''</span>]]}}</includeonly><noinclude>
<includeonly>{{#switch:{{lcfirst:{{{1}}}}}|normal=[[{{#ifexist:{{{2}}}|{{{2}}}|Item Rarity}}|<span style="color:#FFF;background-color:#AAA;padding:4px;">'''{{#if:{{{2|}}}|{{{2}}}|{{{1}}}}}'''</span>]]|magic=[[{{#ifexist:{{{2}}}|{{{2}}}|Item Rarity}}|<span style="color:#0FF;background-color:#AAA;padding:4px;">'''{{#if:{{{2|}}}|{{{2}}}|{{{1}}}}}'''</span>]]|rare=[[{{#ifexist:{{{2}}}|{{{2}}}|Item Rarity}}|<span style="color:#FF0;background-color:#AAA;padding:4px;">'''{{#if:{{{2|}}}|{{{2}}}|{{{1}}}}}'''</span>]]|soul=[[{{#ifexist:{{{2}}}|{{{2}}}|Item Rarity}}|<span style="color:#DAA949;background-color:#AAA;padding:4px;">'''{{#if:{{{2|}}}|{{{2}}}|{{{1}}}}}'''</span>]]|unique=[[{{#ifexist:{{{2}}}|{{{2}}}|Item Rarity}}|<span style="color:#050;background-color:#AAA;padding:4px;">'''{{#if:{{{2|}}}|{{{2}}}|{{{1}}}}}'''</span>]]}}</includeonly><noinclude>
== Description ==
== Description ==
<pre>{{rarity|<rarity>|<optional item name>}}</pre>
<pre>{{rarity|<rarity>|<optional item name>}}</pre>
Line 16: Line 16:
* {{rarity|rare}} is produced from <code><nowiki>{{rarity|rare}}</nowiki></code>
* {{rarity|rare}} is produced from <code><nowiki>{{rarity|rare}}</nowiki></code>
* {{rarity|soul}} is produced from <code><nowiki>{{rarity|soul}}</nowiki></code>
* {{rarity|soul}} is produced from <code><nowiki>{{rarity|soul}}</nowiki></code>
* {{rarity|unique}} is produced from <code><nowiki>{{rarity|unique}}</nowiki></code>
* {{rarity|Unique}} is produced from <code><nowiki>{{rarity|Unique}}</nowiki></code>
* {{rarity|normal|Old Quilted Cloth Cape}} is produced from <code><nowiki>{{rarity|normal|Old Quilted Cloth Cape}}</nowiki></code>
* {{rarity|normal|Old Quilted Cloth Cape}} is produced from <code><nowiki>{{rarity|normal|Old Quilted Cloth Cape}}</nowiki></code>

Latest revision as of 04:59, 24 June 2024

Description

{{rarity|<rarity>|<optional item name>}}

Displays a formatted version of the rarity/quality name. Links to the item page, if it exists, otherwise links to Item Rarity.

Parameters

1 (unnamed parameter)
Rarity name.
2 (unnamed parameter)
Optional item name.

Examples

  • normal is produced from {{rarity|normal}}
  • magic is produced from {{rarity|magic}}
  • rare is produced from {{rarity|rare}}
  • soul is produced from {{rarity|soul}}
  • Unique is produced from {{rarity|Unique}}
  • Old Quilted Cloth Cape is produced from {{rarity|normal|Old Quilted Cloth Cape}}