ae84915d19
1) Make pirates with full holds (and other offenders using route1traderAI) less likely to go to main station, especially not fugitives. (Expansion of changes from r4770) 2) Experimentally ensure always at least one rock hermit in all non-nova systems. If normal generation does not place a hermit, one is added well away from all spacelanes. 3) New "ATTACKER_MISSED" AI event for when a ship tried to shoot a laser at its target but narrowly missed. Many stock AIs modified to treat this as a hostile action. 4) Tidy function/property names in docking code 5) Add checks for cloaking in some AI routines 6) Use weak refs rather than universal ID for targeting, and clean up git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@5144 127b21dd-08f5-0310-b4b7-95ae10353056
51 lines
2.2 KiB
Plaintext
51 lines
2.2 KiB
Plaintext
{
|
|
GLOBAL =
|
|
{
|
|
ENTER = ("setStateTo: LOOK_FOR_SUN");
|
|
};
|
|
"LOOK_FOR_SUN" =
|
|
{
|
|
ENTER = (setSunSkimStartCoordinates);
|
|
"WAIT_FOR_SUN" = (setSunSkimStartCoordinates);
|
|
"APPROACH_COORDINATES" = ("setStateTo: HEAD_FOR_SUN");
|
|
"EXITED WITCHSPACE" = ("switchAITo: route1traderAI.plist");
|
|
UPDATE = ("pauseAI: 10");
|
|
};
|
|
"HEAD_FOR_SUN" =
|
|
{
|
|
ENTER = ("setDesiredRangeTo: 50000", "pauseAI: 0");
|
|
"COURSE_OK" = (setSpeedToCruiseSpeed, performFlyToRangeFromDestination);
|
|
"WAYPOINT_SET" = ("setAITo: gotoWaypointAI.plist");
|
|
"DESIRED_RANGE_ACHIEVED" = ("setStateTo: GO_TO_SKIM");
|
|
ATTACKED = ("setAITo: traderInterceptAI.plist", fightOrFleeHostiles);
|
|
"ATTACKER_MISSED" = ("setAITo: traderInterceptAI.plist", fightOrFleeHostiles);
|
|
"ATTACKED_BY_CLOAKED" = ("setAITo: traderInterceptAI.plist", "setStateTo: FLEE_FOR_CLOAKED");
|
|
"INCOMING_MISSILE" = ("setAITo: traderInterceptAI.plist", "setStateTo: INCOMING_MISSILE", "randomPauseAI: 0.5 2.0");
|
|
"CASCADE_WEAPON_DETECTED" = ("setAITo: fleeQMineAI.plist");
|
|
"EXITED WITCHSPACE" = ("switchAITo: route1traderAI.plist");
|
|
"RESTARTED" = ("setStateTo: LOOK_FOR_SUN");
|
|
UPDATE = (setDestinationFromCoordinates, checkCourseToDestination, "pauseAI: 15");
|
|
};
|
|
"GO_TO_SKIM" =
|
|
{
|
|
ENTER = (setSunSkimStartCoordinates, setDestinationFromCoordinates, "setDesiredRangeTo: 100", "setSpeedFactorTo: 1.0", performFlyToRangeFromDestination);
|
|
"DESIRED_RANGE_ACHIEVED" = ("setStateTo: SKIM_SUN");
|
|
};
|
|
"SKIM_SUN" =
|
|
{
|
|
ENTER = (setSunSkimEndCoordinates, setDestinationFromCoordinates, "setDesiredRangeTo: 50", "setSpeedFactorTo: 2.0", performFlyToRangeFromDestination);
|
|
"DESIRED_RANGE_ACHIEVED" = ("setStateTo: LEAVE_SUN");
|
|
};
|
|
"LEAVE_SUN" =
|
|
{
|
|
ENTER = (setSunSkimExitCoordinates, setDestinationFromCoordinates, "setDesiredRangeTo: 250", "setSpeedFactorTo: 2.0", performFlyToRangeFromDestination);
|
|
"DESIRED_RANGE_ACHIEVED" = ("addFuel: 70", "setStateTo: EXIT_SYSTEM");
|
|
};
|
|
"EXIT_SYSTEM" =
|
|
{
|
|
UPDATE = (performHyperSpaceExit);
|
|
"WITCHSPACE OKAY" = (wormholeEscorts);
|
|
"WITCHSPACE BLOCKED" = (setTargetToFoundTarget, setDestinationWithinTarget, "setDesiredRangeTo: 10000.0", performFlyToRangeFromDestination);
|
|
"WITCHSPACE UNAVAILABLE" = ("setAITo: route1traderAI.plist");
|
|
};
|
|
} |