[an error occurred while processing this directive] Modification: Data File Definitions

\CTP2_DATA\DEFAULT\AIDATA\Goals.txt

The Goals file defines the various goals that the AI can pursue. The various goals that are defined within this file can then be set from the Strategies file where they are given priority ratings and other attributes.

Variables:
NeedsEscort - Unit with this goal should be escorted by military units
IsSally - This goal is a sally point
AvoidWatchfulCity - Do not target watchful cities
ExecuteIncrementally - Execute even if force-match requirements aren't met
NeverSatisfied - Goal is never completed (used for retreat)
RemoveWhenComplete - Remove goal after completing
RallyFirst - Armies should rally forces together before following through
NoTransport - Do not use transports to satisfy this goal
TargetProtectionWonder - Wonder ID that protects targets from this goal. Must be a valid Wonder from Wonders.txt
Execute - Order ID to execute for this goal. Must be a valid Order from Orders.txt
ForceMatch - Force match definition to use when creating squads for this goal. Force match attributes are set within a strategy. Valid values: Offensive, Defensive, StealthAttack, Bombard, Special, Harass
The following flags define which units can execute a goal and what are valid targets. Multiple flags can be defined.
SquadClass - Flags to determine what kinds of unit can execute this goal. Valid values: CanExplore, CanAttack, CanDefend, HasZoc, CanCaptureCity, CanBombard, Special & CanTransport
TargetType - Flags to determine what targets are valid for this goal. Valid values: AttackUnit, SpecialUnit, SettleLand, SettleSea, City, ChokePoint, GoodyHut, TradeRoute, Improvement, Unexplored, Border, Endgame, Random
TargetOwner - Flags to determine which player targets are valid for this goal. Valid values: Self, Ally, Neutral, ColdEnemy, HotEnemy, NoContact
The following priority bonus values are added to the base priority values from the strategy to determine if the goal should be executed. Some are absolute bonuses that applied when true while others are scaled. Scaled bonuses are given as a ratio from 0 to the value of the bonus depending on game state. For example: the target with highest threat rating would get the full ThreatBonus and all other targets would be given a percentage of the bonus based on the ratio of itís threat rating to the highest threat rating.
ThreatBonus - Scaled bonus given based on amount of threat
EnemyValueBonus - Scaled bonus given based on value of target if itís an enemy
AlliedValueBonus - Scaled bonus given based on value of target if itís an ally
PowerBonus  - Scaled bonus given based on power level of target
DistanceToHomeBonus  - Scaled bonus given based on target distance from center of empire
DistanceToEnemyBonus - Scaled bonus given based on target distance from center of enemy empire
ChokePointBonus  - Flat bonus given if target is at a chokepoint location
UnexploredBonus  - Flat bonus given if target is in unexplored territory
ObsoleteArmyBonus - Flat bonus if squad is obsolete
TreaspassingArmyBonus - Flat bonus given if squad is trespassing
The following values are used by the diplomatic system. They allow a goal to be associated with a Threat. When a threat is given all goals that are associated with that threat will get a priority bonus making them more likely to be executed.
ThreatenType - Type of diplomatic threat that applies to this goal. Valid values: AttackCity, Pirate, SpecialAttackCity, DestroyCity, None
ThreatenBonus - Flat bonus to give to this goal if an associated threat has been given


Example:
GOAL_ATTACK {
RallyFirst
 
SquadClass:CanAttack
 
TargetType:AttackUnit
TargetType:SpecialUnit
TargetOwner:HotEnemy
 
Execute ORDER_ATTACK
 
ThreatBonus 100
EnemyValueBonus -250
AlliedValueBonus 1500
PowerBonus 500
DistanceToHomeBonus 0
DistanceToEnemyBonus 0
ChokePointBonus 50
UnexploredBonus -999999
ObsoleteArmyBonus 100
TreaspassingArmyBonus 0
 
ThreatenType:DestroyCity
ThreatenBonus 5000
 
ForceMatch:Offensive
 
TargetProtectionWonder WONDER_THE_FORBIDDEN_CITY
}



BACK TO Directory Structure PAGE

BACK TO MODIFICATION INDEX PAGE

[an error occurred while processing this directive]