Oolite Bulletins

For information and discussion about Oolite.
It is currently Sun Nov 19, 2017 5:37 pm

All times are UTC




Post new topic  Reply to topic  [ 64 posts ]  Go to page Previous 1 2 3 4 5
Author Message
 Post subject: Re: [Split] Convoys OXP
PostPosted: Sun Aug 27, 2017 10:07 am 
Offline
Deadly
Deadly

Joined: Thu Aug 27, 2015 4:24 pm
Posts: 247
hmm, using

ai_type="oolite-traderAI.plist"; instead of "oolite-traderAI.js"

seem to be working somehow


Top
   
 Post subject: Re: [Split] Convoys OXP
PostPosted: Sun Aug 27, 2017 12:03 pm 
Offline
Deadly
Deadly

Joined: Thu Aug 27, 2015 4:24 pm
Posts: 247
If i use the plist reference in the shipdata.plist i can give ship a custom ai.

The following code is an edit of the escortai.plist where i removed all references to
interceptAI ( the interceptAI is the AI i see the ships getting when i attack the convoy.

Allthough i removed all references the escorts still go to interceptai ( and leave the formation )

What do i not see? :wink:


Code:
{
	GLOBAL =
	{
		ENTER = ("setStateTo: BEGIN_BUSINESS");
	};
	"FLYING_ESCORT" =
	{
		ENTER = (performEscort);
		RESTARTED = ("setStateTo: NEXT_TARGET");
		"GROUP_ATTACK_TARGET" = (setTargetToFoundTarget);
		ESCORTING = ("setDesiredRangeTo: 0.0", performEscort);
		"INCOMING_MISSILE" = ("messageMother: INCOMING_MISSILE");
		"CASCADE_WEAPON_DETECTED" = ("setAITo: fleeQMineAI.plist");
		"ATTACKED" = ("messageMother: ATTACKED", "messageMother: ESCORT_ATTACKED");
		"ATTACKER_MISSED" = ("messageMother: ATTACKER_MISSED", "messageMother: ESCORT_ATTACKED");
        "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");
		"ENTER WORMHOLE" = ("setStateTo: ENTER_WORMHOLE");
		UPDATE = (escortCheckMother, "pauseAI: 15");
	};
	"BEGIN_BUSINESS" =
	{
		"LAUNCHED OKAY" = ("setStateTo: CLEAR_STATION");
		ATTACKED = (setTargetToPrimaryAggressor);
		ESCORTING = ("setDesiredRangeTo: 0.0", "setStateTo: FLYING_ESCORT");
		"NOT_ESCORTING" = ("setStateTo: LOOK_FOR_BUSINESS");
		"EXITED WITCHSPACE" = ("setStateTo: EXIT_WORMHOLE");
		UPDATE = (escortCheckMother, "pauseAI: 7.5");
	};
	"ENTER_WORMHOLE" =
	 {
		ENTER =
		(
			setDestinationToTarget,
			"setDesiredRangeTo: 1.0",
			"setSpeedFactorTo: 1.0",
			performFlyToRangeFromDestination,
            "dropMessages: TARGET_LOST"
		);
		"PLAYER WITCHSPACE" = (enterTargetWormhole);
		"DESIRED_RANGE_ACHIEVED" = ("setStateTo: LOOK_FOR_BUSINESS");
	};
	"EXIT_WORMHOLE" =
	 {
        ENTER = (
            setDestinationToCurrentLocation, 
            "setDesiredRangeTo: 7500.0", 
			"setSpeedTo: 50", 
            performFlyToRangeFromDestination
        ); 
		ATTACKED = (setTargetToPrimaryAggressor, "setStateTo: FLYING_ESCORT");
		"CASCADE_WEAPON_DETECTED" = ("setAITo: fleeQMineAI.plist");
		"GROUP_ATTACK_TARGET" = (setTargetToFoundTarget, "setStateTo: FLYING_ESCORT");
        "DESIRED_RANGE_ACHIEVED" = ("setStateTo: LOOK_FOR_BUSINESS"); 
		ESCORTING = ("setDesiredRangeTo: 0.0", "setStateTo: NEXT_TARGET");
		UPDATE = (escortCheckMother, "pauseAI: 2.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);
		UPDATE = ("pauseAI: 15.0");
	};
	"LOOK_FOR_BUSINESS" =
	{
		ENTER = (scanForFormationLeader);
		RESTARTED = ("setStateTo: BEGIN_BUSINESS");
		"LAUNCHED OKAY" = ("setStateTo: CLEAR_STATION");
		ATTACKED = (setTargetToPrimaryAggressor);
		ATTACKER_MISSED = (setTargetToPrimaryAggressor);
		"CASCADE_WEAPON_DETECTED" = ("setAITo: fleeQMineAI.plist");
		ESCORTING = ("setDesiredRangeTo: 0.0", "setStateTo: FLYING_ESCORT");
		"NOT_ESCORTING" = ("rollD: 10");
		"ROLL_1" = ("setStateTo: CHOOSE_NEW_CAREER");
		"TARGET_FOUND" = (setTargetToFoundTarget, suggestEscort);
		"NOTHING_FOUND" = ("setStateTo: CHOOSE_NEW_CAREER");
		"FRUSTRATED" = ("setStateTo: CHOOSE_NEW_CAREER");
		"GROUP_ATTACK_TARGET" = (setTargetToFoundTarget, "setStateTo: FLYING_ESCORT");
		UPDATE = ("pauseAI: 7.5", scanForFormationLeader);
	};
    "NEXT_TARGET" = {
		ENTER = (requestNewTarget); 
		RESTARTED = (requestNewTarget); 
		"NOTHING_FOUND" = (switchLightsOff, "setStateTo: FLYING_ESCORT"); 

        "TARGET_FOUND" = (setTargetToFoundTarget); 
		"MOTHER_LOST" = (switchLightsOff, "setStateTo: BEGIN_BUSINESS"); 
		"INCOMING_MISSILE" = ("messageMother: INCOMING_MISSILE");
		"CASCADE_WEAPON_DETECTED" = ("setAITo: fleeQMineAI.plist");
    }; 
    "CHOOSE_NEW_CAREER" = {
		ENTER = (checkOwnLegalStatus); 
		"SELF_CLEAN" = ("switchAITo: route1patrolAI.plist");
		"SELF_MINOR_OFFENDER" = (checkForFullHold);
		"SELF_OFFENDER" = (checkForFullHold);
		"SELF_FUGITIVE" = ("switchAITo: pirateAI.plist");
		"SELF_THARGOID" = ("switchAITo: thargoidAI.plist");
		"NO_CARGO_BAY" = ("switchAITo: route1patrolAI.plist");
		"HOLD_FULL" = ("switchAITo: route1traderAI.plist");
		"HOLD_NOT_FULL" = ("switchAITo: pirateAI.plist");
    }; 
}


Top
   
 Post subject: Re: [Split] Convoys OXP
PostPosted: Sun Aug 27, 2017 12:46 pm 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Sun Aug 05, 2012 11:46 pm
Posts: 273
I guess this line here:
Code:
"GROUP_ATTACK_TARGET" = (setTargetToFoundTarget);
The escort gets the message from the mother after it has sent an
Code:
"ATTACKED" = ("messageMother: ATTACKED", "messageMother: ESCORT_ATTACKED");
to it... Maybe? It's been a while... :D

EDIT: I'm not quite sure, there are a few more instances of
Code:
setTargetToPrimaryAggressor
as well, could be that this triggers the general ai to change to interceptai.plist?


Top
   
 Post subject: Re: [Split] Convoys OXP
PostPosted: Sun Aug 27, 2017 2:36 pm 
Offline
Deadly
Deadly

Joined: Thu Aug 27, 2015 4:24 pm
Posts: 247
Quote:
"GROUP_ATTACK_TARGET" = (setTargetToFoundTarget);
alas this pure anaconda convoy still attacked me after i attacked the leader ( i know this sounds o.k. but what i am
trying to achieve is that part of convoy formation stays in formation )

Image


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 64 posts ]  Go to page Previous 1 2 3 4 5

All times are UTC


Who is online

Users browsing this forum: Baidu [Spider] and 15 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
cron
Powered by phpBB® Forum Software © phpBB Limited