Hard Light Productions Forums

Modding, Mission Design, and Coding => The Modding Workshop => Topic started by: Erebus Alpha on May 14, 2016, 07:25:32 pm

Title: Strange Turret and Bomber Behavior
Post by: Erebus Alpha on May 14, 2016, 07:25:32 pm
So, I've got most of the ships and weapons finished that I want to use, and I've started testing them. The AI sometimes isn't very smart, but the AI-stupidity was best demonstrated in a bomber-vs-capship test I did:

On the initial attack run, the bombers flew at the enemy capital ship and made a swarm of bombs, which worked great. However, they only fired one wave of bombs; they didn't switch banks to lock and fire more waves of bombs. Or if they did switch banks, they never established lock and fired.

Once the bombers got in close to the capital ship, they sort of loitered around it at short range. Because of the $FOF property I set up in point defense weapons, getting really close to a capital ship is supposed to be kind of dangerous. These are really big, ursa-dwarfing bombers, designed to not care terribly about enemy PD, but they were so close that they sometimes blew themselves up with their own shockwaves. I could do some screwing around with damage types and armor.tbl, and make bombers immune or near-immune to bomb shockwaves, but if smaller bombers repeat this behavior too, they'll get torn to shreds by PD guns.

The turret behavior for shooting down bombs is really really weird. The turrets seem to always prefer the closest bomb - which in theory, makes sense. Unless you have dozens of PD guns, and they end up concentrating fire on just one or two bombs. I need a way to make them target bombs a little more randomly, and spread fire across multiple targets. A swarm-barrage of ten non-radius-doubling corkscrew-enabled bombs isn't supposed to be easy to shoot down, but even on simple capship-to-capship torpedoes that fly in a straight line, PD guns have problems.
Title: Re: Strange Turret and Bomber Behavior
Post by: niffiwan on May 14, 2016, 07:44:43 pm
On the turrets; have a look at the subsystem flag; $Max Turrets per bomb: (http://www.hard-light.net/wiki/index.php/Subsystem#.24Max_Turrets_per_Bomb:), that'll force turrets to spread their fire across multiple bombs, if not exactly randomly like you said.

On the bomber behaviour, not sure what can be done about this, bombers have a tendency to do one run, then loiter near their target, lobbing bombs at close range...
Title: Re: Strange Turret and Bomber Behavior
Post by: Erebus Alpha on May 15, 2016, 01:47:03 am
Sweet, thanks!

I also noticed Target Priority is an option, so I can finally achieve my dream of having those large, cool-looking, multipart turrets on capital ships shoot non-capitals occasionally!

On the note of getting the AI to use weapons intelligently - how would I get the AI to prefer using a specific (fighter-based) primary weapon on capital ships? The aforementioned bombers also include forward-facing beam cannons, which the AI seems content to ignore. The bombing runs would do a lot more damage if they used those instead of Maxims.