{
    "ATTACK_SHIP" = {
        "ENERGY_LOW" = (setTargetToPrimaryAggressor, broadcastDistressMessage, "setStateTo: FLEE"); 
        ENTER = (broadcastDistressMessage, performAttack); 
        "INCOMING_MISSILE" = (
            setTargetToPrimaryAggressor, 
            broadcastDistressMessage, 
            fightOrFleeMissile, 
            "setStateTo: FLEE"
        ); 
        "TARGET_DESTROYED" = ("setStateTo: GO_TO_STATION"); 
        "TARGET_LOST" = ("setStateTo: GO_TO_STATION"); 
    }; 
    FLEE = {
        ATTACKED = (fightOrFleeHostiles); 
        ENTER = ("setDesiredRangeTo: 25600", performFlee); 
        FIGHTING = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP"); 
        FLEEING = (setTargetToPrimaryAggressor, "setStateTo: FLEE"); 
        "INCOMING_MISSILE" = (
            setTargetToPrimaryAggressor, 
            broadcastDistressMessage, 
            fightOrFleeMissile, 
            fightOrFleeHostiles
        ); 
        "REACHED_SAFETY" = (performIdle, "setStateTo: GLOBAL"); 
        "TARGET_DESTROYED" = (performIdle, "setStateTo: GLOBAL"); 
        "TARGET_LOST" = (performIdle, "setStateTo: GLOBAL"); 
        UPDATE = (); 
    }; 
    GLOBAL = {ENTER = ("setStateTo: GO_TO_STATION"); }; 
    "GO_TO_STATION" = {
        "AEGIS_IN_DOCKING_RANGE" = (dockEscorts, setTargetToSystemStation, "setAITo: dockingAI.plist"); 
        ATTACKED = (fightOrFleeHostiles); 
        "COURSE_OK" = ("setSpeedFactorTo: 0.65", performFlyToRangeFromDestination); 
        "DESIRED_RANGE_ACHIEVED" = (dockEscorts, setTargetToSystemStation, "setAITo: dockingAI.plist"); 
        ENTER = (
            setTargetToSystemStation, 
            "setDesiredRangeTo: 5000.0", 
            setDestinationToTarget, 
            checkCourseToDestination
        ); 
        FIGHTING = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP"); 
        FLEEING = (setTargetToPrimaryAggressor, "setStateTo: FLEE"); 
        "INCOMING_MISSILE" = (
            setTargetToPrimaryAggressor, 
            broadcastDistressMessage, 
            fightOrFleeMissile, 
            fightOrFleeHostiles, 
            "setStateTo: FLEE"
        ); 
        "TARGET_FOUND" = (fightOrFleeHostiles); 
        UPDATE = (
            setTargetToSystemStation, 
            "setDesiredRangeTo: 5000.0", 
            setDestinationToTarget, 
            checkCourseToDestination, 
            scanForHostiles, 
            "pauseAI: 10.0"
        ); 
        "WAYPOINT_SET" = ("setAITo: gotoWaypointAI.plist"); 
    }; 
}