2005-04-19 19:53:18 +00:00
|
|
|
{
|
|
|
|
"ATTACK_SHIP" = {
|
|
|
|
ATTACKED = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP");
|
|
|
|
"ENERGY_LOW" = ("setStateTo: FLEE");
|
|
|
|
ENTER = (performAttack);
|
|
|
|
EXIT = ();
|
|
|
|
"INCOMING_MISSILE" = (fightOrFleeMissile, "setStateTo: FLEE");
|
|
|
|
"TARGET_DESTROYED" = ("setStateTo: COLLECT_LOOT");
|
|
|
|
"TARGET_LOST" = ("setStateTo: COLLECT_LOOT");
|
|
|
|
UPDATE = ();
|
|
|
|
};
|
|
|
|
"COLLECT_LOOT" = {
|
|
|
|
ATTACKED = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP");
|
|
|
|
ENTER = ("setSpeedTo: 0.0", performIdle);
|
|
|
|
EXIT = ();
|
|
|
|
"HOLD_FULL" = ("setStateTo: EXIT_SYSTEM");
|
|
|
|
"GROUP_ATTACK_TARGET" = (setTargetToFoundTarget, "setStateTo: ATTACK_SHIP");
|
|
|
|
"INCOMING_MISSILE" = (fightOrFleeMissile, "setStateTo: FLEE");
|
|
|
|
"TARGET_FOUND" = (setTargetToFoundTarget, "setStateTo: LOOT");
|
|
|
|
"NOTHING_FOUND" = ("setStateTo: CONSIDER_DOCKING");
|
|
|
|
UPDATE = (scanForLoot, "pauseAI: 5.0");
|
|
|
|
};
|
|
|
|
"EXIT_SYSTEM" = {ENTER = (performHyperSpaceExit); EXIT = (); UPDATE = (); };
|
|
|
|
FLEE = {
|
2005-10-24 19:18:47 +00:00
|
|
|
ENTER = ("setDesiredRangeTo: 25600", performFlee);
|
2005-04-19 19:53:18 +00:00
|
|
|
"ENERGY_FULL" = (performIdle, "setStateTo: LURK");
|
|
|
|
"TARGET_LOST" = (performIdle, "setStateTo: LURK");
|
2005-10-24 19:18:47 +00:00
|
|
|
"DESIRED_RANGE_ACHIEVED" = (performIdle, "setStateTo: LURK");
|
2005-04-19 19:53:18 +00:00
|
|
|
"INCOMING_MISSILE" = (fightOrFleeMissile, "setStateTo: FLEE");
|
|
|
|
"REACHED_SAFETY" = ("setSpeedTo: 0.0", performIdle, "pauseAI: 10.0");
|
2005-10-24 19:18:47 +00:00
|
|
|
ATTACKED = (setTargetToPrimaryAggressor, "setStateTo: FLEE");
|
2005-04-19 19:53:18 +00:00
|
|
|
UPDATE = ();
|
2005-10-24 19:18:47 +00:00
|
|
|
EXIT = ();
|
2005-04-19 19:53:18 +00:00
|
|
|
};
|
|
|
|
GLOBAL = {ENTER = ("setStateTo: TRAVEL_TO_LURK_AREA"); EXIT = (); UPDATE = (); };
|
|
|
|
LOOT = {
|
|
|
|
ATTACKED = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP");
|
|
|
|
"CARGO_SCOOPED" = (checkForFullHold, "setStateTo: COLLECT_LOOT");
|
|
|
|
ENTER = (performCollect);
|
|
|
|
EXIT = ();
|
|
|
|
"GROUP_ATTACK_TARGET" = (setTargetToFoundTarget, "setStateTo: ATTACK_SHIP");
|
|
|
|
"HOLD_FULL" = ("setStateTo: CONSIDER_DOCKING");
|
|
|
|
"INCOMING_MISSILE" = (fightOrFleeMissile, "setStateTo: FLEE");
|
|
|
|
"TARGET_LOST" = ("setStateTo: COLLECT_LOOT");
|
|
|
|
UPDATE = ();
|
|
|
|
};
|
|
|
|
LURK = {
|
|
|
|
ENTER = ("setSpeedTo: 0.0", performIdle);
|
2005-10-24 19:18:47 +00:00
|
|
|
ATTACKED = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP");
|
2005-04-19 19:53:18 +00:00
|
|
|
EXIT = ();
|
|
|
|
"INCOMING_MISSILE" = (fightOrFleeMissile, "setStateTo: FLEE");
|
|
|
|
"NOTHING_FOUND" = ("setStateTo: COLLECT_LOOT");
|
|
|
|
"TARGET_FOUND" = (setTargetToFoundTarget, checkGroupOddsVersusTarget);
|
|
|
|
"ODDS_GOOD" = (groupAttackTarget);
|
|
|
|
"ODDS_LEVEL" = (groupAttackTarget);
|
|
|
|
"GROUP_ATTACK_TARGET" = (setTargetToFoundTarget, "setStateTo: ATTACK_SHIP");
|
|
|
|
UPDATE = (scanForRandomMerchantmen, "pauseAI: 5.0");
|
|
|
|
};
|
|
|
|
"TRAVEL_TO_LURK_AREA" = {
|
|
|
|
ATTACKED = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP");
|
|
|
|
"DESIRED_RANGE_ACHIEVED" = ("setStateTo: LURK");
|
|
|
|
ENTER = (
|
|
|
|
setDestinationToCurrentLocation,
|
|
|
|
"setDesiredRangeTo: 1500.0",
|
|
|
|
performFlyToRangeFromDestination
|
|
|
|
);
|
|
|
|
EXIT = ();
|
|
|
|
"GROUP_ATTACK_TARGET" = (setTargetToFoundTarget, "setStateTo: ATTACK_SHIP");
|
|
|
|
"INCOMING_MISSILE" = (fightOrFleeMissile, "setStateTo: FLEE");
|
|
|
|
UPDATE = ();
|
|
|
|
};
|
|
|
|
"CONSIDER_DOCKING" = {
|
|
|
|
ATTACKED = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP");
|
|
|
|
ENTER = (checkForMotherStation);
|
|
|
|
"NOTHING_FOUND" = ("setStateTo: LURK");
|
|
|
|
"STATION_FOUND" = ("setAITo: dockingAI.plist");
|
|
|
|
EXIT = ();
|
|
|
|
"INCOMING_MISSILE" = (fightOrFleeMissile, "setStateTo: FLEE");
|
|
|
|
UPDATE = ();
|
|
|
|
};
|
|
|
|
"DOCK_WITH_STATION" = {
|
|
|
|
ATTACKED = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP");
|
|
|
|
ENTER = (setTargetToStation, "setDesiredRangeTo: 5000.0", performIntercept);
|
|
|
|
"DESIRED_RANGE_ACHIEVED" = ("setAITo: dockingAI.plist");
|
|
|
|
EXIT = ();
|
|
|
|
"INCOMING_MISSILE" = (fightOrFleeMissile, "setStateTo: FLEE");
|
|
|
|
UPDATE = ();
|
|
|
|
};
|
|
|
|
}
|