User:Vergir/AbilityInteraction: Difference between revisions

Jump to navigation Jump to search
Vergir (talk | contribs)
Drop all interaction types not in the canonical user-specified list (with help from vergir-bot LLM)
Vergir (talk | contribs)
Replace ItemIcon with plain links in headers; update colors to weapon/vitality/spirit/grey; rename debuff_reduction→debuff_resist, slowing_hex→movement_restriction (with help from vergir-bot LLM)
Line 2: Line 2:
   AbilityInteraction: renders one styled interaction row.
   AbilityInteraction: renders one styled interaction row.
   Parameters:
   Parameters:
     type - interaction type key (see valid values in doc)
     type   - interaction type key (see valid values in doc)
     text - freeform wikitext description
    color  - one of: weapon, vitality, spirit, default (default: default)
     text   - freeform wikitext description
 
  Color palette (matches Deadlock stat categories):
    weapon  = #e8922a  (orange)
    vitality = #86c921 (green)
    spirit  = #de80ff  (purple)
    default = #6b7280  (grey)
-->
-->
{{#if: {{{type|}}} |
{{#if: {{{type|}}} |
<div class="ability-interaction" style="margin-bottom:4px; border-radius:4px; overflow:hidden; font-family:'Open Sans','PT Serif',serif;">
<div class="ability-interaction" style="margin-bottom:4px; border-radius:4px; overflow:hidden; font-family:'Open Sans','PT Serif',serif;">
   <div style="background:{{#switch:{{{type|}}}
   <div style="background:{{#switch:{{{color|default}}}
     | unstoppable        = #a07830
     | weapon   = #e8922a
    | counterspell      = #4a5a7a
     | vitality = #86c921
    | debuff_reduction   = #4a6a7a
     | spirit   = #de80ff
    | dispel_magic      = #4a7a6a
     | #default = #6b7280
     | slowing_hex        = #6a5a7a
     | ability_range      = #5a6a4a
    | ability_duration   = #5a5a6a
    | charges            = #7a5a4a
     | #default           = #555555
   }}; padding:4px 8px; font-weight:bold; font-size:0.85rem; display:flex; align-items:center; gap:6px; color:#FFEFD7;">[[File:{{#switch:{{{type|}}}
   }}; padding:4px 8px; font-weight:bold; font-size:0.85rem; display:flex; align-items:center; gap:6px; color:#FFEFD7;">[[File:{{#switch:{{{type|}}}
     | unstoppable       = Unstoppable Symbol.png
     | unstoppable         = Unstoppable Symbol.png
     | counterspell       = Counterspell.png
     | counterspell         = Counterspell.png
     | debuff_reduction  = Debuff_Reducer.png
     | debuff_resist        = Debuff_Reducer.png
     | dispel_magic       = Dispel_Magic.png
     | dispel_magic         = Dispel_Magic.png
     | slowing_hex        = Slowing_Hex.png
     | movement_restriction = Slowing_Hex.png
     | ability_range     = Greater_Expansion.png
     | ability_range       = Greater_Expansion.png
     | ability_duration   = Duration_Extender.png
     | ability_duration     = Duration_Extender.png
     | charges           = Rapid_Recharge.png
     | charges             = Rapid_Recharge.png
     | #default           = GenericProperty.png
     | #default             = GenericProperty.png
   }}|20px|link=]] {{#switch:{{{type|}}}
   }}|20px|link=]] {{#switch:{{{type|}}}
     | unstoppable       = [[Status Effects#Unstoppable|Unstoppable]]
     | unstoppable         = [[Status Effects#Unstoppable|Unstoppable]]
     | counterspell       = {{ItemIcon|Counterspell}}
     | counterspell         = [[Counterspell]]
     | debuff_reduction  = [[Debuff Resist|Debuff Reduction]]
     | debuff_resist        = [[Debuff Resist]]
     | dispel_magic       = {{ItemIcon|Dispel Magic}}
     | dispel_magic         = [[Dispel Magic]]
     | slowing_hex        = {{ItemIcon|Slowing Hex}}
     | movement_restriction = [[Slowing Hex|Movement Restriction]]
     | ability_range     = [[Ability Range|Ability Range]] ({{ItemIcon|Greater Expansion}})
     | ability_range       = [[Ability Range]]
     | ability_duration   = [[Ability Duration|Ability Duration]] ({{ItemIcon|Duration Extender}})
     | ability_duration     = [[Ability Duration]]
     | charges           = Charges ({{ItemIcon|Rapid Recharge}})
     | charges             = Charges
     | #default           = <span style="color:red;">Unknown type: <code>{{{type}}}</code></span>
     | #default             = <span style="color:red;">Unknown type: <code>{{{type}}}</code></span>
   }}</div>
   }}</div>
   <div style="background:#1e1a22; padding:6px 10px; font-size:0.85rem; color:#FFEFD7;">{{{text|}}}</div>
   <div style="background:#1e1a22; padding:6px 10px; font-size:0.85rem; color:#FFEFD7;">{{{text|}}}</div>
Line 49: Line 51:
|-
|-
| <code>type</code> || Interaction type key. Must be one of the valid values below. || Yes
| <code>type</code> || Interaction type key. Must be one of the valid values below. || Yes
|-
| <code>color</code> || Color category: <code>weapon</code>, <code>vitality</code>, <code>spirit</code>, or <code>default</code>. Defaults to <code>default</code> (grey). || No
|-
|-
| <code>text</code> || Description of the interaction. Freeform wikitext; may span multiple lines, include links, templates, and bullet points. || Yes
| <code>text</code> || Description of the interaction. Freeform wikitext; may span multiple lines, include links, templates, and bullet points. || Yes
|}
|}
=== Color palette ===
Choose the color that matches the Deadlock stat category most relevant to the interaction:
* <code>weapon</code> — orange (#e8922a) — for weapon/bullet interactions
* <code>vitality</code> — green (#86c921) — for healing, health, regen interactions
* <code>spirit</code> — purple (#de80ff) — for spirit/ability interactions
* <code>default</code> — grey (#6b7280) — when no category fits clearly


=== Valid type values ===
=== Valid type values ===
The canonical list of types is also documented in [[User:Vergir/Module:InteractionTypes]]. Adding a new type requires updating both this template's <code>#switch</code> blocks and that module.
Adding a new type requires updating the three <code>#switch</code> blocks in this template (color, icon, label).


* <code>unstoppable</code> — [[Status Effects#Unstoppable|Unstoppable]]
* <code>unstoppable</code> — [[Status Effects#Unstoppable|Unstoppable]]
* <code>counterspell</code> — [[Counterspell]]
* <code>counterspell</code> — [[Counterspell]]
* <code>debuff_reduction</code> — [[Debuff Resist|Debuff Reduction]] (icon: [[Debuff Reducer]])
* <code>debuff_resist</code> — [[Debuff Resist]]
* <code>dispel_magic</code> — [[Dispel Magic]]
* <code>dispel_magic</code> — [[Dispel Magic]]
* <code>slowing_hex</code> — [[Slowing Hex]]
* <code>movement_restriction</code> — [[Slowing Hex|Movement Restriction]]
* <code>ability_range</code> — [[Ability Range]] (icon: [[Greater Expansion]])
* <code>ability_range</code> — [[Ability Range]]
* <code>ability_duration</code> — [[Ability Duration]] (icon: [[Duration Extender]])
* <code>ability_duration</code> — [[Ability Duration]]
* <code>charges</code> — Charges (icon: [[Rapid Recharge]])
* <code>charges</code> — Charges


=== Example ===
=== Example ===
<pre>
<pre>
{{User:Vergir/AbilityInteraction
{{User:Vergir/AbilityInteraction
| type = dispel_magic
| type = counterspell
| text =
| color = spirit
{{ItemIcon|Dispel Magic}} used by an ally on the channeled target will immediately return them.
| text  = [[Counterspell]] blocks the slow and accuracy debuff, but not the damage.
}}
}}
</pre>
</pre>
</noinclude>
</noinclude>