ANL: alternative solution for Guard Problem

This avoids not only luring them on weak terrain,
but also luring them out of the way.
This commit is contained in:
Severin Glöckner 2019-06-21 21:59:36 +02:00
parent dead6d723c
commit 2e57d9b170
2 changed files with 35 additions and 3 deletions

View File

@ -9,14 +9,18 @@
#enddef #enddef
#define MOVEMENT_RESTRICTION #define MOVEMENT_RESTRICTION
# to avoid luring onto unprotected terrain, can still move in castles
[object] [object]
silent=yes silent=yes
duration=forever duration=scenario
[effect] [effect]
apply_to=movement_costs apply_to=movement_costs
replace=true replace=true
[movement_costs] [movement_costs]
flat={UNREACHABLE} flat={UNREACHABLE}
frozen={UNREACHABLE}
cave={UNREACHABLE}
reef={UNREACHABLE}
sand={UNREACHABLE} sand={UNREACHABLE}
shallow_water={UNREACHABLE} shallow_water={UNREACHABLE}
swamp_water={UNREACHABLE} swamp_water={UNREACHABLE}
@ -25,3 +29,31 @@
[/effect] [/effect]
[/object] [/object]
#enddef #enddef
#define MOVEMENT_RESTRICTION_FULL
# to avoid luring onto destroyable buildings or out of position
[object]
silent=yes
duration=scenario
[effect]
apply_to=movement_costs
replace=true
[movement_costs]
castle={UNREACHABLE}
village={UNREACHABLE}
flat={UNREACHABLE}
mountains={UNREACHABLE}
frozen={UNREACHABLE}
cave={UNREACHABLE}
hills={UNREACHABLE}
reef={UNREACHABLE}
fungus={UNREACHABLE}
sand={UNREACHABLE}
forest={UNREACHABLE}
shallow_water={UNREACHABLE}
swamp_water={UNREACHABLE}
deep_water={UNREACHABLE}
[/movement_costs]
[/effect]
[/object]
#enddef

View File

@ -243,7 +243,7 @@
{GUARDIAN} {GUARDIAN}
[+unit] [+unit]
[+modifications] [+modifications]
{MOVEMENT_RESTRICTION} {MOVEMENT_RESTRICTION_FULL}
[/modifications] [/modifications]
[/unit] [/unit]
#enddef #enddef
@ -254,7 +254,7 @@
{GUARDIAN} {GUARDIAN}
[+unit] [+unit]
[+modifications] [+modifications]
{MOVEMENT_RESTRICTION} {MOVEMENT_RESTRICTION_FULL}
{TRAIT_LOYAL} {TRAIT_LOYAL}
[/modifications] [/modifications]
[/unit] [/unit]