Difference between revisions of "Template:Attributes"

From Medivia Online Wiki
Tag: Reverted
m (Reverted edits by Eldrin (talk) to last revision by MoonMoon)
Tag: Rollback
 
(2 intermediate revisions by the same user not shown)
Line 146: Line 146:
</table>
</table>
}}
}}
<!-- ========================================================= -->
<!-- === AUTOMATIC TOOLTIP LINK GENERATION STARTS HERE ====== -->
<!-- ========================================================= -->
<!-- Tooltip dictionary -->
{{#define:attr-tooltip|
{{#switch: {{{1}}}
|Superior = Increases the armor of an item.
|Fortitude = Increases your health regeneration by X amount per X regen ticks (regen tick length depends on vocation/promotion).
|Vitality = Increases total health point pool (knights/archers/mages).
|Strength = Increases strength (knights only).
|Intelligence = Increases intelligence (mages and druids only).
|Intellect = Increases total mana point pool.
|Presence of Mind = Increases mana regeneration per 16 regen turns.
|Mana Absorb = 10% chance to absorb damage and convert it to mana.
|#default =
}}
}}
<!-- Scanner for attributes inside text -->
{{#define:linkify|
<!-- Superior -->
{{#ifexpr: {{#pos: {{{1}}} | Superior }} > -1 |
  [[Attributes#Superior|{{#tip-text: Superior| {{#invoke:var|attr-tooltip|Superior}} }}]]
}}
<!-- Fortitude -->
{{#ifexpr: {{#pos: {{{1}}} | Fortitude }} > -1 |
+ [[Attributes#Fortitude|{{#tip-text: Fortitude| {{#invoke:var|attr-tooltip|Fortitude}} }}]]
}}
<!-- Vitality -->
{{#ifexpr: {{#pos: {{{1}}} | Vitality }} > -1 |
+ [[Attributes#Vitality|{{#tip-text: Vitality| {{#invoke:var|attr-tooltip|Vitality}} }}]]
}}
<!-- Strength -->
{{#ifexpr: {{#pos: {{{1}}} | Strength }} > -1 |
+ [[Attributes#Strength|{{#tip-text: Strength| {{#invoke:var|attr-tooltip|Strength}} }}]]
}}
<!-- Intelligence -->
{{#ifexpr: {{#pos: {{{1}}} | Intelligence }} > -1 |
+ [[Attributes#Intelligence|{{#tip-text: Intelligence| {{#invoke:var|attr-tooltip|Intelligence}} }}]]
}}
<!-- Intellect -->
{{#ifexpr: {{#pos: {{{1}}} | Intellect }} > -1 |
+ [[Attributes#Intellect|{{#tip-text: Intellect| {{#invoke:var|attr-tooltip|Intellect}} }}]]
}}
<!-- Presence of Mind -->
{{#ifexpr: {{#pos: {{{1}}} | Presence of Mind }} > -1 |
+ [[Attributes#Presence_of_Mind|{{#tip-text: Presence of Mind| {{#invoke:var|attr-tooltip|Presence of Mind}} }}]]
}}
<!-- Mana Absorb -->
{{#ifexpr: {{#pos: {{{1}}} | Mana Absorb }} > -1 |
+ [[Attributes#Mana_Absorb|{{#tip-text: Mana Absorb| {{#invoke:var|attr-tooltip|Mana Absorb}} }}]]
}}
}}
{{#if: {{{name_1|}}} | {{#invoke:var|linkify|{{{name_1}}}}} }}
{{#if: {{{name_2|}}} | {{#invoke:var|linkify|{{{name_2}}}}} }}
{{#if: {{{name_3|}}} | {{#invoke:var|linkify|{{{name_3}}}}} }}
{{#if: {{{name_4|}}} | {{#invoke:var|linkify|{{{name_4}}}}} }}
{{#if: {{{name_5|}}} | {{#invoke:var|linkify|{{{name_5}}}}} }}
{{#if: {{{name_6|}}} | {{#invoke:var|linkify|{{{name_6}}}}} }}
{{#if: {{{name_7|}}} | {{#invoke:var|linkify|{{{name_7}}}}} }}

Latest revision as of 22:28, 22 November 2025