Hard Light Productions Forums

Modding, Mission Design, and Coding => FS2 Open Coding - The Source Code Project (SCP) => Topic started by: General Battuta on April 08, 2015, 04:22:11 pm

Title: Require (or fake require) AI aspect lock?
Post by: General Battuta on April 08, 2015, 04:22:11 pm
AI parity with human players is a great tool for mission and weapon designers.

Can we require the AI to obtain aspect lock? Can we fake a system in which an aspect-seeking weapon has an 'AI lock time requirement'?

What happens, right now, if the AI encounters a ship that can't be targeted? Will it correctly refuse to fire aspect seekers at it?
Title: Re: Require (or fake require) AI aspect lock?
Post by: AdmiralRalwood on April 08, 2015, 05:04:06 pm
AI parity with human players is a great tool for mission and weapon designers.

Can we require the AI to obtain aspect lock? Can we fake a system in which an aspect-seeking weapon has an 'AI lock time requirement'?
The AI is currently required to obtain an aspect lock; the "AI lock time requirement" is the weapon's minimum lock time. Now, it will take the AI less time to lock onto a target than a human player would because the AI's attempts to lock on aren't thrown off by it or its target maneuvering; changing that would require making quite a few changes to the AI code.

What happens, right now, if the AI encounters a ship that can't be targeted? Will it correctly refuse to fire aspect seekers at it?
If it has the "hidden from sensors" flag or is under stealth, the AI won't obtain an aspect lock, and as mentioned before, an aspect lock is required for the AI to fire an aspect-seeking missile.
Title: Re: Require (or fake require) AI aspect lock?
Post by: headdie on April 08, 2015, 06:08:49 pm
AI parity with human players is a great tool for mission and weapon designers.

Can we require the AI to obtain aspect lock? Can we fake a system in which an aspect-seeking weapon has an 'AI lock time requirement'?
The AI is currently required to obtain an aspect lock; the "AI lock time requirement" is the weapon's minimum lock time. Now, it will take the AI less time to lock onto a target than a human player would because the AI's attempts to lock on aren't thrown off by it or its target maneuvering; changing that would require making quite a few changes to the AI code.


Perhaps not what Battuta is looking for but might help.

How much work would it be to create a modifier in the AI tables to affect that lock time, something like this

 $LockTime:                      1.0      0.75     0.5      0.0     -0.25

So on:
Very Easy the minimum lock time value the AI uses has a 1 second penalty
Easy - a 0.75 secong penalty, Normal 0.5 second
Hard would use the Tabled value
Insane would have the lock time reduced by 0.25 seconds

Basically while the change is controlled in the AI table, the effect is in the minimum lock time Value the AI uses, so no significant changes to the AI code I hope.

also to make it a little less predictable a +/- random number range that can be set to further modify the changes

As I say the changes I suggest wont make the engine mechanically more believable but would give mod makers a little more control over difficulty
Title: Re: Require (or fake require) AI aspect lock?
Post by: General Battuta on April 08, 2015, 06:12:31 pm
We already have $Hostile AI Secondary Fire Delay Scale: for that.
Title: Re: Require (or fake require) AI aspect lock?
Post by: headdie on April 08, 2015, 06:21:04 pm
ahhhh, ok