Posted: Tue Mar 17, 2009 11:18 pm
It turns out that the reason the pirate dont work is that FLY_TO_LURK_AREA isnt working properly, and the AI just gets FRUSTRATED but never makes any progress.
I have changed the following in pirate ai this change works, i nso far as it makes pirates behave more sensibly when they are unable to reach the target lurk area, however, there is something funny going on with
I have changed the following in pirate ai
Code: Select all
"TRAVEL_TO_LURK_AREA" =
{
ENTER = (setDestinationToCurrentLocation, "setDesiredRangeTo: 1500.0", performFlyToRangeFromDestination);
ATTACKED = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP");
"DESIRED_RANGE_ACHIEVED" = ("setStateTo: LURK");
"GROUP_ATTACK_TARGET" = (setTargetToFoundTarget, "setStateTo: ATTACK_SHIP");
"INCOMING_MISSILE" = (fightOrFleeMissile, "setStateTo: FLEE");
"ENTER WORMHOLE" = ("setStateTo: ENTER_WORMHOLE");
"EXITED WITCHSPACE" = ("switchAITo: enteringPirateAI.plist"); // Unreachable? If so, enteringPirateAI and enteringTraderAI are unused.
"FRUSTRATED" = ("setStateTo: LURK");
};
Code: Select all
(setDestinationToCurrentLocation, "setDesiredRangeTo: 1500.0", performFlyToRangeFromDestination);