PDA

View Full Version : My AI's all crash?



Worthless
May 19th, 2012, 04:58
This doesn't happen all the time, but sometimes for no apparent reason....at the very end of a mission all of the wingman either crash or bail out just before landing. It happens on missions I've constructed and on missions I've downloaded. I doubt if this is new to longtime CFS2 flyers. Is there an answer, or a solution to this?

Allen
May 19th, 2012, 15:42
The CFS2 AI has VARY hard time of landing. This is why I didn't have any AI aircraft "land at base" with In the Army Air Force (AAF) campaign. Only the player and wingmen are set to land at a base.

If you are using 1% aircraft or there .air they will crash 99% of the time when trying to land.

Worthless
May 19th, 2012, 17:33
I was flying the FDG2 f4u1. No idea whose Air file, but when I switched to the MS F4U1A stock AC most of my AI made the landing with no trouble. So, I guess the problem was the AC.

Allen
May 19th, 2012, 19:17
From my experience for the AI to land an aircraft it must have a clean stall speed of 85 MPH or less according to AirWrench and *CL_DF Lift - Flaps according to Aired must be at or less than 0.300000

You can get away with 86 MPH but *CL_DF Lift - Flaps in the Primary Aerodynamics going over 0.300000 will send aircraft wobbling side to side tell they crash.

Talon
May 19th, 2012, 19:47
I've always studied how the AI perform in different situations.I have test missions to see how they attack and as they finish their mission I watch them land. I've used Beaufighters,SBDs,B-25s,B-24s and P-40s and they always landed safely.None of them were stock BTW.

Knowing how the AI react helps in mission building.

Allen
May 19th, 2012, 21:05
I my self haven't done much with AI and landing tell In the Army Air Force (AAF) campaign. I tested the planes in test mission but the AI still seem to crash out side of the test mission randomly when trying to land.

_486_Col_Wolf
May 20th, 2012, 12:46
I had the same problems with my AI in my missions and campaigns and you are correct. The AIR file was always the culprit. Either correct them or change them out with known good AI aircraft and the problem should be gone.

Allen
May 20th, 2012, 19:01
Talon were those non stock aircraft using blank .air files and only using the Aircraft.cfg data to fly?

skylane
May 21st, 2012, 05:32
In my missions I work around this problem by not using the default way to end missions. I warp to a waypoint close to the destination airfield and disable warp there. Another waypoint is very close to the airfield and the final one is "Land at base".
The player then has to set up his approach and land while the wingmen fly around the field. I devised a trigger/event combination to end the mission after landing (works everywhere, mnot just at the intended place of landing).
This way, the wingmen don't land, so they won't crash while trying.
Giving the "Flight Attack" command while you're on downwind causes them to scatter all over the place, so they won't collide either.

Talon
May 21st, 2012, 07:17
Allen,

The B-24 was a stock plane but I used the airfile from the B-24 done by KM.

The SBD was the donationware.

Beaufighter by Bismarck13.I don't know if you remeber when this first came out it wouldn't even attack targets. I got it to attack and sent what I did to Pen32Win and he redid the airfile and cfg file. Bismarck put these in his beaufighters before he uploaded them so they work fine and land fine now.

B-25 by Tango Romeo. He knows alot about AI behavior and I think he did a tutorial on it a few years back. It may be at Lindsay's site.

P-40s-I used the KM P-40s. He is another person who understood about the AI planes.

I just wrote a mission that has 12 Beaufighters and they are escorted by 12 P-39s ( stock ). When I came back to base all the Beaufighters landed safely and only 1 P-39 crashed when landing. I also had an extra waypoint by the base before they were to land.


Talon

sc7500
May 21st, 2012, 09:04
Talon, could this be a function of the Section 1001 / MOI AIR File numbers being too high ?

bearcat241
May 21st, 2012, 13:06
Regarding AI landings, one of the things i noticed early was that in the stock missions with AI landings they very seldom crashed. This was in the days before i learned air file modding. I saw stock AI aircraft with stock flight models landing and taxiing to full stops at every airfield i was using in these missions. At first i thought it was the flight models that helped because it was the addon AC with their custom FDE files that seemed to have the most problems landing in addon missions. After some study i later realized that the stock missions tended to have longer final approaches than many addon missions, which gave the birds more air time to set up in trailing formation, lower their speed and landing gear, touch down at the proper landing speed and make a good taxi-and-turn move near or at the end of the runways.

So, i went to work testing my ideas for 100% success in all AI landings involving addon AC. First i created 'T/O and landing only' missions and set the last waypoint before "LAND AT BASE" at about 2 miles out at 150 knots, 250 AGL to give the flight a long, slow and low final with which to set up. I then went to work on the air files by lowering the flap lift to almost nothing, doubling the braking strength and increasing the steering angle of the nosewheel or tailwheel - depending on whether tricycle gear or tail-dragger was involved. Taking advantage of the long final after the last waypoint, i would gain a slight lead ahead of the pack and wait for them to lower their gear. That means they're now in actual landing mode and will start to lose altitude and airspeed quickly and go into a single file trail. At that point i raced far ahead and landed quickly (a little hot) so i could be parked, waiting and watching as the first wingy touched down.

I've already gone over the benefits of the long approach, so now here's where the air file mods help. The near zero flap lift lets the AC touchdown sooner without floating halfway down the runway, then trying to stick it hard and stop fast. The doubled brake strength slows them faster - of course - and the modified steering angle on the "third wheel" allows them to turn off the strip sooner and taxi to a shorter stopping point without running over the hill or into infrastructure.

Braking strength and flap lift are found in air file section 1101. The default for brakes is about 32767 or so. You strengthen the brakes by lowering this variable. So double would be about 16384. Allen already mentioned the flap lift above. In the aircraft.cfg the first line in the contact points is always the nosewheel or tailwheel. The eight variable - separated by commas - is the steer angle. Set it at about 75 degrees for sharp turning in taxi.


[contact_points]
//0 Class
//1 Longitudinal Position (feet)
//2 Lateral Position (feet)
//3 Vertical Position (feet)
//4 Impact Damage Threshold (Feet Per Minute)
//5 Brake Map (0=None, 1=Left, 2=Right)
//6 Wheel Radius (feet)
//7 Steer Angle (degrees)
//8 Static Compression (feet) (0 if rigid)
//9 Max/Static Compression Ratio
//10 Damping Ratio (0=Undamped, 1=Critically Damped)
//11 Extension Time (seconds)
//12 Retraction Time (seconds)
//13 Sound Type
//14 Airspeed limit for retraction (KIAS)
//15 Airspeed that gear gets damage at (KIAS)

point.0 = 1, -14.4116, 0, -3.35, 2000, 0, 0.45, 75, 0.264, 2.5, 0.8, 5, 5, 0, 148, 180
point.1 = 1.000, 1.700, -6.200, -7.100, 2360.000, 1.000, 1.150, 0.000, 0.500, 2.500, 0.800, 5.000, 5.000, 2.000, 148.000, 180.000
point.2 = 1.000, 1.700, 6.200, -7.100, 2360.000, 2.000, 1.150, 0.000, 0.500, 2.500, 0.800, 9.000, 7.000, 3.000, 148.000, 180.000
point.3 = 2, 0, -18.0638, -1.182, 1500, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0
point.4 = 2, 0, 18.1888, -1.1202, 1500, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0
point.5 = 2, -19.779, 0, -0.739, 1500, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0
point.6 = 2, 7.8097, 5.5373, -1.9746, 1500, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0
point.7 = 2, 2.1587, -4.7916, -2.8525, 1500, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
point.8 = 2, -3.976, 0, -3.8862, 1500, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
point.9 = 2, 0, 0, 0, 1500, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0

Use these tips and you should rarely see a landing mishap. But in a final note i would remind all that in the interest of realism you really don't want to fully eliminate all such incidents, since landing mishaps were very common in every theater of warbird operations. A random crash every now and again makes the sim behavior seem more authentic. Also, if your AI suffer battle damage (which you may not always be aware of) that affects their flight envelopes they will likely have control issues when landing that can lead to a crash. They're not as gifted as a human pilot would be in nursing a wounded bird safely home. You guys ever had a mission where you got chewed up so badly that the moment you got back and into your final, you lowered flaps and/or gear and the plane would almost go inverted from a severe wing drop? Its usually survivable with airfield landings, but carrier traps under these conditions are deadly. :pop4: Well, believe it or not, AI have to deal with battle damage while landing too. And it ain't always pretty to watch.

Allen
May 21st, 2012, 13:26
This should be usefull for me. My landing test mission is at Munda. It has water on 3 sides so I dound it to be a good test area. My bigest prob was the AI not stopping. It would keep going and running off the runway and right into the water...

The other was as soon as the AI would lower the landing gear they would sway side to side than crash in the water before geting over land at all. Lowering the *CL_DF Lift - Flaps to next to nothing fixed the sway side to side but they still like to hit the water just before land.


65913

bearcat241
May 21st, 2012, 14:05
BTW, you should also reduce the flap pitch to near zero as well. In the hands of AI, i've seen some addons with high flap pitch settings overcompensate while trying hard to keep the nose down after touchdown. They go down the runway with tail high and nose very low near prop strike...yeah, its ugly. Stockers, on the other hand, have zero flap pitch and very little lift.

Worthless
May 21st, 2012, 16:43
This has turned into a great thread. I'm going to save it for future reference. A question or two. Are these changes for folks with lots of experience or can anyone make theses alterations?
For instance, Flaps pitch vs *CL_DF Lift - Flaps.....Are these the same? And how about "Clean Stall Speed"......where do I find these?

Allen
May 21st, 2012, 16:59
AirWrench.

http://www.mudpond.org/AirWrench_main.htm

It is in demo mode unless you want to pay $20 for the Activation Code. While in demo mode it it still dose all of estimating of how the air file will work in the game. I use AirWrench as a reader and do all the work in AirEdit.

65925

bearcat241
May 21st, 2012, 18:17
This has turned into a great thread. I'm going to save it for future reference. A question or two. Are these changes for folks with lots of experience or can anyone make theses alterations?
For instance, Flaps pitch vs *CL_DF Lift - Flaps.....Are these the same? And how about "Clean Stall Speed"......where do I find these?

You don't need Airwrench for this...in fact, that's a bit overkill for these minor modifications. Don't get too technically involved in the stall speed for this exercise. The tips given in my post completely disregard that detail because they're applicable to any FDE as-is. Once you start fiddling with stall speed you are effectively skirting the arena of advanced FDE mods and could run the risk of the triggering a cascading effect where one change affects another to the point of needing AirWrench to bail yourself out.

Just open your *.air file with Aired and go to section 1101. I use version 1.52, found at SimV these days i'm sure. As for modding the cfg, that's a simple Notepad job. I was using these two and nothing else for years before investing in AirWrench. I only pull AW out of the toolbox when i need a complete overhaul of some sort.

Allen
May 21st, 2012, 21:34
You may want to revise one thing. If "*Breaking Strength - Max (ft/sec^2*2048?)=" is the only thing that set braking strength. It is wrong to lower it in my testing.


I set *Breaking Strength - Max (ft/sec^2*2048?)= to 16384 and I was able to take off with the parking brake on. I was not able to do this with with 32767.

skylane
May 21st, 2012, 23:49
Bearcat,
thanks for this very interesting information.
One question: If I make these changes to the airfile, does it also affect the way the player aircraft flies?

bearcat241
May 22nd, 2012, 01:43
Not in any way that matters. You're only changing flap pitch and lift, the brakes and the steer angle of the third wheel. The brakes and wheel changes only affect ground handling. The flap changes don't matter unless you use them extensively in air combat maneuvering (ACM). And even in that case, you really only want flap drag, not pitch and lift which tend to throw off your aim if there's too much effectiveness in these.

bearcat241
May 22nd, 2012, 01:56
You may want to revise one thing. If "*Breaking Strength - Max (ft/sec^2*2048?)=" is the only thing that set braking strength. It is wrong to lower it in my testing.


I set *Breaking Strength - Max (ft/sec^2*2048?)= to 16384 and I was able to take off with the parking brake on. I was not able to do this with with 32767.

Sorry man, i forgot to mention that you have to do this in the negative, not positive numbers, such as -16384. Anyway i got this info back in my FDE schooling days from my guru, Rabijjah Guder, who wrote and circulated an excellent brief on air file editing called Air101.

In it he wrote:



Now go to Section 1101 of the airfile called Main Dynamics(FDE), or Flight Dynamics(AirEd) and edit the entry named Braking Factor(FDE), Braking Strength(AirEd). This entry controls the maximum force of the landing gears brakes. Valid entries are between –32768 and 32767. The lower the entry is, the stronger will be your gears. In fact if you make them too strong your plane can even crash while braking. Examples 737: -25536, Learjet: -15536, Bf109G: 12000. Since I read that the Me262 had very poor brakes I set this value to 18211.


Using negatives, this works well for me BTW. I remember when i first started experimenting in this i would set brakes so low that i would nose over and explode when i revved my engine too high with park brakes on.

Allen
May 22nd, 2012, 20:37
Negative 16384 seemed to fix my pesky Kate .air. It kept wanting to running off into the water at Munda.