Skip to content

Commit

Permalink
Simplify leadership (and THoT inspire) using new ability formulas
Browse files Browse the repository at this point in the history
  • Loading branch information
CelticMinstrel committed Jun 25, 2017
1 parent d2067e4 commit c47b3f3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 105 deletions.
60 changes: 2 additions & 58 deletions data/campaigns/The_Hammer_of_Thursagan/utils/abilities.cfg
Expand Up @@ -6,73 +6,17 @@ _" The presence of this unit inspires own units next to it to deal more damage i
#define ABILITY_INSPIRE
# Canned definition of the Inspire ability to be included in an
# [abilities] clause.
# Note: Works only on units of level 0-5
[leadership]
id=inspire
value=150
value="(25 * (level - other.level + 1))"
cumulative=no
name= _ "inspire"
female_name= _ "female^inspire"
description= _ "This unit can inspire own units that are next to it, making them fight better. Adjacent own units of lower or equal level will deal 25% more damage plus 25% for each level they are below the inspiring unit."
affect_self=no
[affect_adjacent]
[filter]
formula="level = other.level - 5"
[/filter]
[/affect_adjacent]
[/leadership]
[leadership]
id=inspire
value=125
cumulative=no
affect_self=no
[affect_adjacent]
[filter]
formula="level = other.level - 4"
[/filter]
[/affect_adjacent]
[/leadership]
[leadership]
id=inspire
value=100
cumulative=no
affect_self=no
[affect_adjacent]
[filter]
formula="level = other.level - 3"
[/filter]
[/affect_adjacent]
[/leadership]
[leadership]
id=inspire
value=75
cumulative=no
affect_self=no
[affect_adjacent]
[filter]
formula="level = other.level - 2"
[/filter]
[/affect_adjacent]
[/leadership]
[leadership]
id=inspire
value=50
cumulative=no
affect_self=no
[affect_adjacent]
[filter]
formula="level = other.level - 1"
[/filter]
[/affect_adjacent]
[/leadership]
[leadership]
id=inspire
value=25
cumulative=no
affect_self=no
[affect_adjacent]
[filter]
formula="level = other.level"
formula="level <= other.level"
[/filter]
[/affect_adjacent]
[/leadership]
Expand Down
49 changes: 2 additions & 47 deletions data/core/macros/abilities.cfg
Expand Up @@ -99,10 +99,9 @@ This ability will not cure an affected unit of poison, however, only delay its e
#define ABILITY_LEADERSHIP
# Canned definition of the Leadership ability to be included in an
# [abilities] clause.
# Note: Works only on units of level 1-5
[leadership]
id=leadership
value=125
value="(25 * (level - other.level))"
cumulative=no
name= _ "leadership"
female_name= _ "female^leadership"
Expand All @@ -112,51 +111,7 @@ Adjacent own units of lower level will do more damage in battle. When a unit adj
affect_self=no
[affect_adjacent]
[filter]
formula="level = other.level - 5"
[/filter]
[/affect_adjacent]
[/leadership]
[leadership]
id=leadership
value=100
cumulative=no
affect_self=no
[affect_adjacent]
[filter]
formula="level = other.level - 4"
[/filter]
[/affect_adjacent]
[/leadership]
[leadership]
id=leadership
value=75
cumulative=no
affect_self=no
[affect_adjacent]
[filter]
formula="level = other.level - 3"
[/filter]
[/affect_adjacent]
[/leadership]
[leadership]
id=leadership
value=50
cumulative=no
affect_self=no
[affect_adjacent]
[filter]
formula="level = other.level - 2"
[/filter]
[/affect_adjacent]
[/leadership]
[leadership]
id=leadership
value=25
cumulative=no
affect_self=no
[affect_adjacent]
[filter]
formula="level = other.level - 1"
formula="level < other.level"
[/filter]
[/affect_adjacent]
[/leadership]
Expand Down

0 comments on commit c47b3f3

Please sign in to comment.