Difference between revisions of "Template:Rarity"
Dinoguy1000 (talk | contribs) (+Collector's Rare/CR) |
Dinoguy1000 (talk | contribs) (add Gold Rare (no abbreviation because GR, the most obvious, is already used for Ghost Rares, and I'm not sure what to add)) |
||
Line 25: | Line 25: | ||
| msr | mosaic rare = {{ #if: {{{full|}}} | Mosaic Rare | MSR }} | | msr | mosaic rare = {{ #if: {{{full|}}} | Mosaic Rare | MSR }} | ||
| cr | collector's rare = {{ #if: {{{full|}}} | Collector's Rare | CR }} | | cr | collector's rare = {{ #if: {{{full|}}} | Collector's Rare | CR }} | ||
+ | | | gold rare = Gold Rare | ||
| gur | gold ultra rare = {{ #if: {{{full|}}} | Gold Ultra Rare | GUR }} | | gur | gold ultra rare = {{ #if: {{{full|}}} | Gold Ultra Rare | GUR }} | ||
| gscr | gold secret rare = {{ #if: {{{full|}}} | Gold Secret Rare | GScR }} | | gscr | gold secret rare = {{ #if: {{{full|}}} | Gold Secret Rare | GScR }} |
Revision as of 13:24, 17 December 2013
C
Usage
This template is used to standardize rarity names/abbreviations for templates, so they don't have to implement such a check locally. It currently supports all official rarities and their abbreviations, and is not case-sensitive. The template doesn't return anything when fed unsupported values, which can be used for error-checking.
Basic usage is {{rarity|rarity}}
, outputting the abbreviation for the given rarity. The full name can be output instead by using the {{{full}}}
parameter.
Examples
Code | Result | Code | Result |
---|---|---|---|
{{rarity|Common}} |
C | {{rarity|C}} |
C |
{{rarity|common}} |
C | {{rarity|c}} |
C |
{{rarity|Common|full=yes}} |
Common | {{rarity|C|full=yes}} |
Common |
{{rarity|Rare}} |
R | {{rarity|R}} |
R |
{{rarity|Ghost Rare}} |
GR | {{rarity|GR}} |
GR |
{{rarity|Foo}} |
{{rarity|BLA}} |
||
{{rarity|}} |
{{rarity}} |