Increase to the range of AI Blocks for player built missile weapons

Ripps Black shared this feedback 2 months ago
Not Enough Votes

So the last few days I have been working on semi-automated guided missile weapon system.

https://steamcommunity.com/sharedfiles/filedetails/?id=3171036152

I managed to create a missile I am quite proud of, its capable of automatically launching its self.

and with some guidence from the player it can be pointed in the direction of the enemy and coast the distance

untill the AI blocks can target a grid and take control of the missile.


This all worked great until I came to test the missile against live targets and it got shot down by the enemy turrets.

So me and a friend working together came up with an idea to deploy decoys as the missile weapon enters weapon range, or rather slightly before hand

so that the decoys can get dispersed as you're entering enemy weapons range. This way the missile has a much greater chance of survival.


The problems all started here.

I wanted a way to deploy the decoys automatically so the missile can be more or less automated at the final approach.

When I used an event controller block with the event; Distance to Target locked: and the related block being the AI offensive block.

I noticed the range wasn't great, but it was twice that of the enemy turrets so I figured I could make this work.

When the distance between the missile and locked target was less than 1400m, I disengaged the merge blocks holding the decoys in place.

The results of this were that the decoys seperated but maintained the forward trajectory of the missile and so did not spread. Enemy fire was still concentrated on the missile.

I began to think about how I can solve this, so I installed some extra gyroscopes and gave those an override roll value to make it the missile spin, this will impart some momentum to the decoys

encouraging them to spread out and give the missile a chance of hitting the target.

What I learned was that when the AI Flight and Offensive blocks were in control of the missile, they overrode the override setting on the gryos, and the autopilot actively avoided the spin.

So I began to experiment with ways of disabling the AI behavior long enough to perform a manual spin and seperate the decoys using timers blocks.


I quickly realised that 2500m range I at first thought wasn't too bad was just not enough.


So I now think I now know what needs to happen to make the autopilot behave as expected.

the problem is one of range, max AI range is 2500m

max turret targetting range is 1200m

speed = ~100m/s

therefore.... we have 13 seconds to perform all the required actions

the seperation takes of decoys takes 8 for maximum dispersal effect. we can reduce this to one second by releasing them all at once.

AI re-targets at minimum every 5 seconds.

so a situation can occur when you enter visual range, but the AI just performed its last check prior to entering.

it wont check for another 5 seconds.

So for example:


If it performed its last scan at 2501m distance from target.

then you have to wait 5 seconds before you can scan again.

so if your speed is close to max (in my case it was 99ms)

thats 500m before you get a target lock.

That means the distance between you and the 'target' is now 2000m to start with

Now the maximum effective weapon range of player controlled weapons is 1400m

and the maximum effective weapon range of AI controlled turrets is 800-1200m


this leaves you with 6 seconds to perform all spin and seperation actions against player controlled ships.

worse case we get 8 seconds against AI based weapon systems.

best case we get 12 seconds.


Its just not enough.

I'm hoping keen realise their error next update and icnrease some of these ranges

otherwise I'm going to have to perform an entire writeup explanining why they are wrong and whey certain numbers MUST be increased

2500m for anything space related is just not enough time to do the following:

plot a course trajectory

get to speed

disengage AI blocks

engage spin

seperate decoys

stop spin

engage AI blocks

course correct again

and hit the target.


There is an event, distance to locked target

the locked target is relative to a cockpit block, custom turret controller block, AI block or remote control

so for example;

a player in a cockpit or in control of remote control block can target any enemy with turrets just by being in weapons range but they wont 'target lock'.

that is done when a player presses right mouse on a potential target, a countdown will occur (for players only)

at which point the target will become locked and all turrets and weapons on your grid

will ingore their own AI and target the locked enemy grid

for AI blocks its different, the offensive and deffensive blocks 'lock a target'

whenever the conditions for a valid target are met.

this means its an event an enemy grid can respond to (being target locked)

that would be useful, if turrets target locked the missile.

we could use that event to deploy the decoys instead.

but they dont.

so we cant.

so instead we are using an event controller to detect the distance of the target 'locked' by the offensive AI block.

and the offensive block will only lock targets in that stupid 2500m range

and only minimum once per 5 seconds


So I asked around the Space Engineers community to ask if what I wanted was even possible and was meet with hositlity towards the idea of increasing the range due to performance cost of ray casting.


the AI blocks have insufficient range for use a misiles, fact.

there are no favourable conditions to make this happen, fact.

one of the primary functions of the AI blocks was missiles

(primarly drones, but missiles are a documented 'feature') they are reffered to as PBW (player built weapons)

another fact. source: https://www.spaceengineersgame.com/new-players/grid-ai-guide/

screenshot incase you try any funny business and remove the mention of missiles: https://puu.sh/K1Zy7/050dfb7e90.png


to make AI blocks work as missiles

some change needs to be made to their behavior

which will allow them to target from a greater distance.

if this behavior can not be done via the casting of rays, cheat.

take the known positions of the grids from the server.

subtract those outside of antenna range.

the remaining grids are 'viable' targets.

using that GPS position data, that is also visually available to the player via the nav points beacons and antennas create which literally give us all the distance values we need.

plot a course, maybe an intercept course (predictive path) maybe not.

bobs your uncle, no rays cast - target lock aquired.

where is the problem in this?


I mean fuck it - you can probably add this to the existing game without modifying much of the base code

I am ofcourse no coder - but this seems like fairly simple logic to me

the only 'hard' part - would be the predictive course as the grid will be moving it will need to replot every few ticks

however you can have it plot more often the closer it gets and less the further away it is to avoid any significant performance costs.


please fucking please tell me I'm not the only one who can see the problem here?

Leave a Comment
 
Attach a file