Page 1 of 1

station and carriers - too few fighters?

Posted: Sun Mar 11, 2007 10:06 am
by gabbakeisen
I've only been playing Oolite for a few weeks and was intercepted by a targoid carrier. I had beam lasers, fuel injectors and an extra energy unit so I thought I was a goner from my memory of the original a single thargoid with robotic fighters was damn near impossible to kill without a bomb. Anyway a couple of thargoids come out and I managed to kill them - no robotic fighters were seen and then nothing. nada. ziltch. The carrier just sat there, so i fly up real close so it can't use its ecm launch my three missiles at it and it slowly starts to fly away. What the? no laser fire or anything? so I follow it blasting al kinds of molten hell out of the damn thing and after an eternity of depleting the lazers and waiting for a recharge it eventually explodes. I mean its wayyy too easy. I've also noticed that the space stations only release a couple of fighters if you fire on them. Whilst in the original it was a constant stream of death. Are these two things linked? and can we have more fighters please!

Posted: Sun Mar 11, 2007 10:31 am
by LittleBear
Faily easy to tweak if you want to. If you open up the shipdata and find "max defence ships", change the number to a higher one. Most stations and carriers have 7.

Posted: Sun Mar 11, 2007 10:40 am
by gabbakeisen
cheers :) but I find that usually only 3 are released? Any way I'll up it and see what happens

Posted: Mon Mar 12, 2007 10:51 am
by Arexack_Heretic
One problem with the Thargoid carrier is the way the ThargoidAI reacts to any thargoid ship that does not EXACTLY has 'thargoid' as role.

This causes the launched thargoid warships to attack the carrier if no other viable targets are available.

(Usually the ship launches only when non-thargoid are nearby, thankfully. I used escorts in Thargorn Threat, that was a bigger problem as escorts were spawned near their mothers no matter how close non-thargoids were. This causes alot of internacine-warfare.)
todo: repost request to fix this... bug?

Posted: Mon Mar 12, 2007 12:00 pm
by LittleBear
Could give the Bugs a CustomAI, which makes them attack everything except the Bugs (or things with non-standard roles). Just do a likeship to a normal Thargoid but give it a custom role and specify as the Carrier's defence ship- EG:-

This is a modded version of Thargoid AI but with the roles I want the ship to fight in multiple look_for_targets states:-

Code: Select all

{
"ATTACK_SHIP" = {
        ENTER = (switchLightsOn, performAttack); 
        "ATTACKED" = (setTargetToPrimaryAggressor); 
        "ENERGY_LOW" = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP"); 
        "INCOMING_MISSILE" = (fightOrFleeMissile, setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP");
        "TARGET_DESTROYED" = ("commsMessage: [erebel-chat]", "setStateTo: LOOK_FOR_TARGETS"); 
        "TARGET_LOST" = ("commsMessage: [erebel-chat]", "setStateTo: LOOK_FOR_TARGETS"); 
        EXIT = (); 
	  UPDATE = (performAttack); 
     };

"LOOK_FOR_TARGETS" = {
ENTER = (switchLightsOff, "scanForNearestShipWithRole: imperial");
        "ATTACKED" = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP"); 
        "INCOMING_MISSILE" = (fightOrFleeMissile, setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP"); 
		"TARGET_FOUND" = (setTargetToFoundTarget, "setStateTo: ATTACK_SHIP"); 
        	"NOTHING_FOUND" = ("setStateTo: LOOK_FOR_TARGETS2"); 
EXIT = ();
	UPDATE = ("scanForNearestShipWithRole: imperial", "pauseAI: 1.0");
	};

"LOOK_FOR_TARGETS2" = {
ENTER = (switchLightsOff, "scanForNearestShipWithRole: warimp");
        "ATTACKED" = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP"); 
        "INCOMING_MISSILE" = (fightOrFleeMissile, setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP"); 
		"TARGET_FOUND" = (setTargetToFoundTarget, "setStateTo: ATTACK_SHIP"); 
        	"NOTHING_FOUND" = ("setStateTo: LOOK_FOR_TARGETS3"); 
EXIT = ();
	UPDATE = ("scanForNearestShipWithRole: warimp", "pauseAI: 1.0");
	};

"LOOK_FOR_TARGETS3" = {
ENTER = (switchLightsOff, "scanForNearestShipWithRole: imperial4");
        "ATTACKED" = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP"); 
        "INCOMING_MISSILE" = (fightOrFleeMissile, setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP"); 
		"TARGET_FOUND" = (setTargetToFoundTarget, "setStateTo: ATTACK_SHIP"); 
        	"NOTHING_FOUND" = ("setStateTo: HEAD_FOR_PLANET"); 
EXIT = ();
	UPDATE = ("scanForNearestShipWithRole: imperial4", "pauseAI: 1.0");
	};

"HEAD_FOR_PLANET" = {		
ENTER = (setCourseToPlanet, "setDesiredRangeTo: 80000.0", checkCourseToDestination);
"COURSE_OK" = ("setSpeedFactorTo: 1.0", performFlyToRangeFromDestination);
"WAYPOINT_SET" = ("setStateTo: GO_TO_WAYPOINT1");
"DESIRED_RANGE_ACHIEVED" = ("setStateTo: LOOK_FOR_TARGETS");
ATTACKED = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP");
"INCOMING_MISSILE" = ("commsMessage: [erebel-chat]", fightOrFleeMissile, setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP");
"TARGET_FOUND" = (setTargetToFoundTarget, "setStateTo: ATTACK_SHIP");
EXIT = ();
		
UPDATE = ("scanForNearestShipWithRole: imperial", "pauseAI: 1.0");
	};
 
"GO_TO_WAYPOINT1" = {
ENTER = ("setDesiredRangeTo: 50.0", checkCourseToDestination);
"COURSE_OK" = ("setSpeedFactorTo: 1.0", performFlyToRangeFromDestination);
"WAYPOINT_SET" = ("setDesiredRangeTo: 50.0", checkCourseToDestination);
"DESIRED_RANGE_ACHIEVED" = ("setStateTo: HEAD_FOR_PLANET");
ATTACKED = (setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP");
"INCOMING_MISSILE" = ("commsMessage: [erebel-chat]", fightOrFleeMissile, setTargetToPrimaryAggressor, "setStateTo: ATTACK_SHIP");
EXIT = ();
		
UPDATE = ("scanForNearestShipWithRole: warimp", "pauseAI: 1.0");
	}; 


GLOBAL = {
        ENTER = ("setStateTo: LOOK_FOR_TARGETS"); 
        EXIT = (); 
        UPDATE = (); 
    }; 
}
This is for an OXP ship that only appears at at certain mission stage and is fighting ships with the above roles. (They have similar AIs to make them attack the enemy ships). But if your substuted, trader, police, pirate, miner, player. Then the ship would attack pretty much every human ship it encountered, whilst leaving Bugs alone.

Posted: Mon Mar 12, 2007 12:31 pm
by Arexack_Heretic
I don't think I like that method for standard thargoid behaviour.
Seeing as there is this readymade method to select potential 'thargets',
I'd rather have that fixed than work around it by scanning for all possible scanclasses.

Posted: Mon Mar 12, 2007 1:30 pm
by JensAyton
gabbakeisen wrote:
cheers :) but I find that usually only 3 are released? Any way I'll up it and see what happens
*Looks up from revamping station set-up code*
The default for max_defense_ships is in fact three.