I've got the escorts using a custom AI, but when attacked they go to
interceptAI.plist
from the trunk (rev 5466). However when they exit that sub-AI, they end up in route1PatrolAI.plist
rather than back where they should have been wildShips_solarEscortAI.plist
.I'm somewhat confused as to why this is happening, as that AI is not set/switched to in either interceptAI or the main escort custom AI (reproduced below). This AI is
wildShips_solarEscortAI.plist
, with the mother flying under wildShips_solarAI.plist
(which takes them from the main station to the system Kiota solar station and then docks with it).Can someone test this for me? I can make the updated version of wildShips available if needed, although it's still a WIP.
Code: Select all
{
GLOBAL =
{
ENTER = ("setStateTo: BEGIN_BUSINESS");
};
"BEGIN_BUSINESS" =
{
"LAUNCHED OKAY" = ("setStateTo: CLEAR_STATION");
ESCORTING = ("setDesiredRangeTo: 0.0", "setStateTo: FLYING_ESCORT");
"NOT_ESCORTING" = ("switchAITo: wildShips_solarAI.plist");
"ATTACKED" = (setTargetToPrimaryAggressor, "setStateTo: UNDER_ATTACK");
"ATTACKER_MISSED" = (setTargetToPrimaryAggressor, "messageMother: ATTACKER_MISSED", "setStateTo: UNDER_ATTACK");
"ATTACKED_BY_CLOAKED" = ("messageMother: ATTACKED_BY_CLOAKED");
UPDATE = (escortCheckMother, "pauseAI: 7.5");
};
"CLEAR_STATION" =
{
ENTER = (
getWitchspaceEntryCoordinates,
setDestinationFromCoordinates,
"setDesiredRangeTo: 5000.0",
"setSpeedFactorTo: 0.50",
performFlyToRangeFromDestination,
escortCheckMother
);
"DESIRED_RANGE_ACHIEVED" = ("setStateTo: LOOK_FOR_BUSINESS");
"TARGET_FOUND" = (setTargetToFoundTarget, suggestEscort, "pauseAI: 1.0");
ESCORTING = ("setDesiredRangeTo: 0.0", "setStateTo: FLYING_ESCORT");
"NOT_ESCORTING" = (scanForFormationLeader);
"NOTHING_FOUND" = ("setSpeedFactorTo: 0.50", performFlyToRangeFromDestination);
"ATTACKED" = (setTargetToPrimaryAggressor, "setStateTo: UNDER_ATTACK");
"ATTACKER_MISSED" = (setTargetToPrimaryAggressor, "messageMother: ATTACKER_MISSED", "setStateTo: UNDER_ATTACK");
"ATTACKED_BY_CLOAKED" = ("messageMother: ATTACKED_BY_CLOAKED");
UPDATE = ("pauseAI: 15.0");
};
"LOOK_FOR_BUSINESS" =
{
ENTER = (scanForFormationLeader);
RESTARTED = ("setStateTo: BEGIN_BUSINESS");
"LAUNCHED OKAY" = ("setStateTo: CLEAR_STATION");
"CASCADE_WEAPON_DETECTED" = ("setAITo: fleeQMineAI.plist");
ESCORTING = ("setDesiredRangeTo: 0.0", "setStateTo: FLYING_ESCORT");
"NOT_ESCORTING" = ("switchAITo: wildShips_solarAI.plist");
"TARGET_FOUND" = (setTargetToFoundTarget, suggestEscort);
"NOTHING_FOUND" = ("switchAITo: wildShips_solarAI.plist");
"FRUSTRATED" = ("switchAITo: wildShips_solarAI.plist");
"ATTACKED" = (setTargetToPrimaryAggressor, "setStateTo: UNDER_ATTACK");
"ATTACKER_MISSED" = (setTargetToPrimaryAggressor, "messageMother: ATTACKER_MISSED", "setStateTo: UNDER_ATTACK");
"ATTACKED_BY_CLOAKED" = ("messageMother: ATTACKED_BY_CLOAKED");
UPDATE = ("pauseAI: 7.5", scanForFormationLeader);
};
"FLYING_ESCORT" =
{
ENTER = (performEscort);
RESTARTED = ("setStateTo: FLYING_ESCORT");
"GROUP_ATTACK_TARGET" = (setTargetToFoundTarget, "setAITo: interceptAI.plist");
ESCORTING = ("setDesiredRangeTo: 0.0", performEscort);
"INCOMING_MISSILE" = ("messageMother: INCOMING_MISSILE");
"CASCADE_WEAPON_DETECTED" = ("setAITo: fleeQMineAI.plist");
"ATTACKED" = (setTargetToPrimaryAggressor, "setStateTo: UNDER_ATTACK");
"ATTACKER_MISSED" = (setTargetToPrimaryAggressor, "messageMother: ATTACKER_MISSED", "setStateTo: UNDER_ATTACK");
"ATTACKED_BY_CLOAKED" = ("messageMother: ATTACKED_BY_CLOAKED");
"NOT_ESCORTING" = ("setStateTo: LOOK_FOR_BUSINESS");
"TARGET_LOST" = ("setStateTo: LOOK_FOR_BUSINESS");
"TARGET_DESTROYED" = ("setStateTo: LOOK_FOR_BUSINESS");
UPDATE = (escortCheckMother, "pauseAI: 15");
};
"UNDER_ATTACK" =
{
ENTER = ("messageMother: ATTACKED", "messageMother: ESCORT_ATTACKED", "setSpeedFactorTo: 0.0", performIdle);
"TARGET_DESTROYED" = (escortCheckMother);
"TARGET_LOST" = (escortCheckMother);
ESCORTING = ("setDesiredRangeTo: 0.0", "setStateTo: FLYING_ESCORT");
"NOT_ESCORTING" = ("setStateTo: LOOK_FOR_BUSINESS");
EXIT = ("setSpeedFactorTo: 1.0");
};
}