Jump to content

How to make AI planes land correctly?


Recommended Posts

SAS_Storebror
Posted

Hi folks,

 

I've got a couple of problems with getting AI to land right when they RTB.

I understand that the "AI return to base decision" is a bad thing if you have Tank Airfields on your map (which usually are not located on an airfield, but somewhere "in the wild") because AI would want to choose them for landing.

So I decided to watch out for "OnPlaneCricitalDamage", "OnPlaneBingoMainMG" and "OnPlaneBingoFuel" events in order to let the plane RTB "manually".

Manually RTB means that I have set a high priority Waypoint near the base where I let the planes fly to (after force finishing any previous command), and that waypoing points to a Command:Land MCU.

Now there's the problem: The planes don't land at that MCU, but they land a few hundred meters in front of the next airfield they see when they eventually decide to land.

That decision seems out of reach to me.

Sometimes for instance the plane starts an approach, then spots an enemy fighter, then first engages that fighter (even though the landing command has high priority), and only when it's done engaging it (which can take looooooong time), it will decide to land again, and whatever location it is at when this happens, the nearest airfield to that location will be where it lands in such case.

That's damn nasty.

Last but not least, the "OnPlaneBingoFuel" event seems pretty useless, as it means that the plane 9 out of 10 times will run out of fuel before it reaches any airfield.

 

Any hints from your side my dearest mission experts?

 

Cheers!

Mike

Posted

Seems like you have the right idea and method to me. You don't have "AI return to base decision" checked in the plane advanced properties box do you? 

 

For sure high priority WP's will make the AI ignore being attacked. But now that I think about it I rarely make situations where I wanted the planes to land with enemy aircraft near... I think a couple of my stuka missions planes where landing as an airbattle was waged very near... maybe the new update messed this up? maybe it's plane type dependent? - could rule that last one out at least. I'd guess fighters will engage before landing while every other plane type will in fact actually make that land command "high" priority.

 

 

Posted
4 hours ago, SAS_Storebror said:

Now there's the problem: The planes don't land at that MCU, but they land a few hundred meters in front of the next airfield they see when they eventually decide to land.

That decision seems out of reach to me.

 

Does your fakefield have an entity, does it have the right coalition and does it have a chart?

SAS_Storebror
Posted
18 hours ago, NETSCAPE said:

You don't have "AI return to base decision" checked in the plane advanced properties box do you? 

(...)

I'd guess fighters will engage before landing while every other plane type will in fact actually make that land command "high" priority.

Correct, I've explicitely unchecked the "AI return to base decision" because otherwise AI planes will usually return to Tank airfields which on my mission are closer to the battlefield than the real airfields. This in fact I consider a bug: The Tank airfield is a distinctive object in ME, AI should never pick such an "airfield" (where in fact the attribute "air" is already misleading) for landing.

Concerning the plane type dependency you might be right.

I haven't seen bombers ignoring the land command yet, but fighters constantly do.

The issue arises when AI fighters run out of ammo or out of fuel, or they get critically damaged.

In all these cases I will want to let them return to base, but other AI planes might chase them home.

Sure, I could use the "Behaviour" command MCU to take away the "engageable" flag from the planes when they start running home, but this would be unrealistic to me - imagine an AI plane runs out of ammo, therefore starts heading home, and immediately it would be left untouched by other AI planes.

 

Yesterday I've witnessed the utmost extreme incarnation of this "fight instead land" issue.

Two AI Spitfires ran out of ammo and one was critically damaged, so they all headed home, one after another.

The last Spitfire got chased home by two Bf 109 G-6.

Eventually all three Spitfires and the two 109s ended up circling above the red airbase, where the damaged Spit crash-landed 5 minutes later when the engine eventually died.

But on top of this, one of the "winchester" spits already was on short final when the last Spit with the two 109s on it's tail arrived.

Once they got in sight, the Spit aborted landing and started chasing after 109s. With gear and flaps down!

That was a funny sight.

And to put the icing on the cake, when 10 minutes later AAA finally got the last 109, that Spit put flaps in and retracted gears for another go-around and landing approach. But previously, while chasing the 109s, it constantly had legs and flaps down :dash:

 

16 hours ago, coconut said:

 

Does your fakefield have an entity, does it have the right coalition and does it have a chart?

Yes, yes and no.

Do I need to have a chart for AI to land correctly?

 

Cheers!

Mike

Posted

Yeah just click edit chart, it's pretty self explanatory what to do :) ...move two middle points are the start and end of runway and move the taxi points on taxiway or where ever you want the planes to taxi

 

Sounds like no chart is one of your problems, which you can easily fix. But the AI fighters are probably just programmed to not land when enemy fighters are around, I don't blame them... but probably nothing you can do there. 

 

I feel bad, I laughed when reading about your Spit pilot LOL. 

 

We all know the pain and struggles of mission editing though... it's only downhill for you from here comrade. hahaha. good luck man. 

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...