Template:Resistance: Difference between revisions
Jump to navigation
Jump to search
(Reverting since we are solving this another way, should still be removed elsehwer) |
(Improve code clarity and link to Resistances instead of Damage Types.) |
||
Line 1: | Line 1: | ||
<includeonly>{{#lvardef:degree|{{#switch: {{{2|}}}| magical = Resistant | vulnerable = Vulnerable | | <includeonly>{{trim| | ||
}}<span style="display: inline-block;" aria-label="{{#lvar:degree}} to {{{1}}}">[[File: | {{#lvardef: degree | {{#switch: {{{2|}}} | ||
| magical | |||
| double | |||
| resistant | |||
| Magical | |||
| Double | |||
| Resistant = Resistant | |||
| vulnerable | |||
| Vulnerable = Vulnerable | |||
| immunity | |||
| immune | |||
| Immunity | |||
| Immune = Immune | |||
}} }} | |||
{{#lvardef: filename | {{{1}}} {{#switch: {{{2|}}} | |||
| vulnerable | |||
| Vulnerable = V | |||
| resistant | |||
| Resistant = NM | |||
| magical | |||
| Magical = M | |||
| double | |||
| Double = R | |||
| immunity | |||
| immune | |||
| Immunity | |||
| Immune = Immunity | |||
}}.png }} | |||
}}<span style="display: inline-block;" aria-label="{{#lvar:degree}} to {{{1}}}">[[File:{{#lvar:filename}}|{{{3|28px}}}|link=Resistances]]</span>{{#if:{{{nocat|}}}||{{Main only|[[Category:{{#lvar:degree}} to {{{1}}}]]}}}}</includeonly><noinclude>[[Category:Templates]] | |||
Example: | Example: | ||
{{Resistance|Psychic|resistant|nocat=1}}{{Resistance|Fire|double}}{{Resistance|Magic|magical}}{{Resistance|Thunder|immune}}{{Resistance|Radiant|vulnerable}} | {{Resistance|Psychic|resistant|nocat=1}}{{Resistance|Fire|double}}{{Resistance|Magic|magical}}{{Resistance|Thunder|immune}}{{Resistance|Radiant|vulnerable}} |
Revision as of 17:15, 6 April 2024
Example: {{Resistance|Psychic|resistant}}{{Resistance|Fire|double}}{{Resistance|Magic|magical}}{{Resistance|Thunder|immune}}{{Resistance|Radiant|vulnerable}}
You can also use {{Resistance|Acid|immune|40px}} to make it bigger
Template data
No description.
Parameter | Description | Type | Status | |
---|---|---|---|---|
type | 1 | The damage type | String | required |
resistance | 2 | How resistant?
| String | required |
size | 3 | Size of the icon.
| Number | optional |
nocat | nocat | If specified, does not insert categories. | Unknown | optional |