Difference between revisions of "Template:E"

From Tales of Maj'Eyal
Jump to: navigation, search
m
(adds section: 'Light radius')
Line 58: Line 58:
 
| mentalresist = Mental save:
 
| mentalresist = Mental save:
 
| ?? }} + ({{{4}}}-{{#expr:{{{4}}}+{{{3}}}}})
 
| ?? }} + ({{{4}}}-{{#expr:{{{4}}}+{{{3}}}}})
 +
| lite = Light radius: + ({{{3}}}-{{#expr:{{{3}}}+{{{2}}}}})
 
| ?? }}</onlyinclude></includeonly>
 
| ?? }}</onlyinclude></includeonly>
 
[[Category:Templates]]
 
[[Category:Templates]]
Line 134: Line 135:
 
=== Saving Throws ===
 
=== Saving Throws ===
  
The lua code for an ego's effect on physical save is
+
The lua code for an ego's effect on physical save looks like
 
<pre>combat_physresist = resolvers.mbonus_material(15, 10)</pre>
 
<pre>combat_physresist = resolvers.mbonus_material(15, 10)</pre>
  
Line 141: Line 142:
  
 
To produces the following text: {{e|combat|physresist|15|10}}
 
To produces the following text: {{e|combat|physresist|15|10}}
 +
 +
== Light radius ==
 +
 +
The lua code for an ego's effect on light radius looks like
 +
<pre>lite = resolvers.mbonus_material(1, 2)</pre>
 +
 +
Convert it with this template as
 +
<pre>{{e|lite|1|2}}</pre>
 +
 +
To produces the following text: {{e|lite|1|2}}

Revision as of 03:01, 15 November 2016


This template is designed to match item effects descriptions and their lua code, to ensure consistency, intuitive conversion, and keep the wording in line with their in-game description. Source:game/modules/mod/class/Object.lua


Damage Types: Increases, Resistances and So Forth

Supported damage types:

  • all
  • acid
  • arcane
  • blight
  • cold
  • darkness
  • fire
  • light
  • lightning
  • mind
  • nature
  • physical
  • temporal

Resistances

The lua code specifying an ego's effect on fire resistance is

resists={[DamageType.FIRE] = resolvers.mbonus_material(15, 15)}

Convert it with this template as

{{e|resists|fire|15|15}}

To produces the following text: Changes resistances: + (15-30)% Fire

Effects on Hit

The lua code specifying an ego's effect when the wearer is hit is

on_melee_hit={[DamageType.PHYSICAL] = resolvers.mbonus_material(10, 10)}

Convert it with this template as

{{e|on_melee_hit|physical|10|10}}

To produces the following text: Damage when hit (Melee): + (10-20) Physical

Melee and Ranged Attacks with Extra Flat Damage

The lua code specifying an ego's effect on wearer's melee attacks regarding flat damage looks like

melee_project={[DamageType.FIRE] = resolvers.mbonus_material(15, 8),}

Convert it with this template as

{{e|melee_project|fire|15|8}}

To produces the following text: Damage (Melee): + (8-23) Fire

Stats

Supported:

  • str (Strength)
  • dex (Dexterity)
  • con (Constitution)
  • mag (Magic)
  • wil (Willpower)
  • cun (Cunning)
  • lck (Luck)

The lua code for an ego's effect on a character's stats looks like

inc_stats = {[Stats.STAT_WIL] = resolvers.mbonus_material(5, 1)}

Convert it with this template as

{{e|stats|wil|5|1}}

To produces the following text: ??

Stats Beginning with combat_ in LUA Code

Supported combat stats:

  • physresist (physical save)
  • spellresist (spell save)
  • mentalresist (mental save)

Saving Throws

The lua code for an ego's effect on physical save looks like

combat_physresist = resolvers.mbonus_material(15, 10)

Convert it with this template as

{{e|combat|physresist|15|10}}

To produces the following text: ??

Light radius

The lua code for an ego's effect on light radius looks like

lite = resolvers.mbonus_material(1, 2)

Convert it with this template as

{{e|lite|1|2}}

To produces the following text: Light radius: + (2-3)