Author Topic: AI tweak/fix mini-mod v1.0 ready for download  (Read 7839 times)

Offline Drawde

  • Jr. Member
  • **
  • Posts: 160
    • View Profile
Re: AI tweak/fix mini-mod v1.0 ready for download
« Reply #45 on: 05-03-2010, 20:03:09 »
EDIT: If you wont mind releasing it twice, you can upload the current build and get others to try it out - it might be faster finding the issue that way -

I think that's what I'll do if I haven't fixed the problem within a couple of days. I think, though, that I might have just been unlucky with the CTDs on Supercharge; the last two games I played on this map didn't crash.

A few things I noticed -
- I saw a bot use a Geballte Ladung charge for the first time - took out an Allied tank but blew himself up in the process, maybe this is why bots are disabled from using these in the default FH2 AI! But I'll continue trying to get the AI to use these weapons properly (after I've released the current version).
- I also saw a bot fire the 25pdr howitzer, using it like an AT gun to fire AP rounds at a German tank. Still no progress with getting them to fire HE indirectly, but at least it shows the AI is capable of firing these weapons.
- Supercharge gets really hard for the Germans once the British get as far as Gazal Station! They don't have anything that can reliably kill the heavier Allied tanks (Sherman, Grant, Valentine) other than the Pz.IIIJ's special AP rounds, and I think the German aircraft also stop spawning once the Allies get this far.
- Bots really don't seem to understand how to use AT rifles correctly - they never lie down to fire them, so rarely hit anything even at point-blank range. Not sure why this is, since they seem to understand how to use MGs. Since at least one in four bots seem to be using the AT kit, this makes AI infantry rather less effective than it should be.

Offline djinn

  • Masterspammer
  • ****
  • Posts: 5.723
    • View Profile
Re: AI tweak/fix mini-mod v1.0 ready for download
« Reply #46 on: 05-03-2010, 21:03:25 »
EDIT: If you wont mind releasing it twice, you can upload the current build and get others to try it out - it might be faster finding the issue that way -
I think that's what I'll do if I haven't fixed the problem within a couple of days. I think, though, that I might have just been unlucky with the CTDs on Supercharge; the last two games I played on this map didn't crash.

Supercharge developed a CTD issue from FH2.2, it might just be that

A few things I noticed -
- I saw a bot use a Geballte Ladung charge for the first time - took out an Allied tank but blew himself up in the process, maybe this is why bots are disabled from using these in the default FH2 AI! But I'll continue trying to get the AI to use these weapons properly (after I've released the current version).

Bots in 2.0 used the gabellte Ladung - It was stopped after that release... But the truth is, even I die from it sometimes inspite of fleeing after dropping it. It has a larger explosion than sticky bombs - Same goes for British charges. They too die sometimes, inspite of fleeing - Perhaps its about how far they flee, since IMO, they already do

- I also saw a bot fire the 25pdr howitzer, using it like an AT gun to fire AP rounds at a German tank. Still no progress with getting them to fire HE indirectly, but at least it shows the AI is capable of firing these weapons.

Another weapon that worked fine in 2.0 save for indirect fire. Again, you might really want to consider my suggestion of elevated perspective, irrespective of how it affects players' view point in COOP/SP. It seems a sure bet - Don't forget BF2 vanilla never supported manned artillery and so indirect fire as existed in FH1 might be impossible, or require toying with hardcode, which will make FH2 contraband. Yes, with the insane range AT guns seem to fire, increased elevation should certainly do it if it is possible

- Supercharge gets really hard for the Germans once the British get as far as Gazal Station! They don't have anything that can reliably kill the heavier Allied tanks (Sherman, Grant, Valentine) other than the Pz.IIIJ's special AP rounds, and I think the German aircraft also stop spawning once the Allies get this far.

That, coupled with bots not being able to use the gabellte landung and Supercharge having some insane commander logic which goes bonkers once the Germans only hold the town - For both armies... In reality, the battle should move to the town with bots moving in mechanized groups up to the town, dismounting and proceeding inward to take the flags, facing stiff infantry resistance from the mg, AA (Another reason for making AA anti-vehicle and anti-personnel also) and close-range infantry combat... For the last bit, the Germans excel.. IF the British actually get off their vehicles to move in. Tanks fighting in the outskirt become secondary.. simply defending the flanks and preventing a breakout, with German tanks trying to force that breakout... It actually does happen, but rarely.

- Bots really don't seem to understand how to use AT rifles correctly - they never lie down to fire them, so rarely hit anything even at point-blank range. Not sure why this is, since they seem to understand how to use MGs. Since at least one in four bots seem to be using the AT kit, this makes AI infantry rather less effective than it should be.

Personally, I think the AT rifle as it is is fine since AT rifle bots also have the AT bombs to compensate for the rocket AT bots who have both range and destructive power in their single main weapon. Also, the devs made bots own a unique AT rifle, that unlike its Conquest counterpart, can be fired standing but at terrible accuracy - Nonetheless, bots have no issue taking out PZIIs and anythin lighter - Even Crusaders, ever so often, so I think its fine in that sense..

Thank you so much for the feeback - Really looking foward to the release :-)
« Last Edit: 05-03-2010, 21:03:03 by djinn »

Offline Drawde

  • Jr. Member
  • **
  • Posts: 160
    • View Profile
Re: AI tweak/fix mini-mod v1.0 ready for download
« Reply #47 on: 06-03-2010, 20:03:43 »
Quote from: djinn
Also, the devs made bots own a unique AT rifle, that unlike its Conquest counterpart, can be fired standing but at terrible accuracy - Nonetheless, bots have no issue taking out PZIIs and anythin lighter - Even Crusaders, ever so often, so I think its fine in that sense..

Interesting, I didn't realise this - do you have any idea where the data for these bot-only AT rifles is stored? This might explain why none of the changes I've made to the AT rifle data seem to have much effect on the bot's usage of these weapons.

One major thing that still really needs fixing (I'll try and have a look at this once I've released the current version) is bots disembarking from vehicles and changing crew positions. Once this is in, bot usage of passenger + tank rider positions can be re-enabled, and infantry bots might actually stand a chance on some of the large North Africa maps!

It looks like the Supercharge CTD was not directly related to the changes in my mini-mod, I was just unlucky in having it crash early on twice in a row. However, I'm now getting CTDs on Mersa Matruh 64, usually about 10-15 minutes after starting. This seems to be related to either aircraft or possibly AA guns - when I remove my modded Stuka files, the map (unlike the AI Stukas) never seems to crash
Anyone else have CTDs when playing this map offline, with or without my mini-mod installed?

Offline djinn

  • Masterspammer
  • ****
  • Posts: 5.723
    • View Profile
Re: AI tweak/fix mini-mod v1.0 ready for download
« Reply #48 on: 06-03-2010, 20:03:46 »
Sadly no... *sigh* man, I was actually fingers crossed when I saw Drawde as the latest post a few minutes ago, hoping it was a release

Well, sadly, Mersa has always been one of the more stable ones... Not even with your current patch does it give issues.. not even with my crappy PC, which might crash if things get too interesting..

So yes, there is a chance that this one is your fault(jk) as a result of something new

What makes you think its AA or aircraft... I could try to investigate, granted we don't have the updated files, but it will be more possible to deduce why it might be the case cuz I for one have plated FH2 COOP avidly since 2.0 and can tell you, like I did earlier all the possible nooks and crannys of bot behaviour or logic.

Offline Drawde

  • Jr. Member
  • **
  • Posts: 160
    • View Profile
Re: AI tweak/fix mini-mod v1.0 ready for download
« Reply #49 on: 06-03-2010, 22:03:55 »
I thought the problem might be aircraft-related as removing the modded Stuka files solved the crash problem completely. This is odd, as I haven't made any significant changes to aircraft in the last week or so, so it could possibly be caused by AA guns, maybe the Bren AA which there are plenty of in Mersa Matruh and which the bots rarely if ever seem to use.

But I managed to play for about 30min on Mersa Matruh today, using the modded aircraft files, without any crash (I exited the game after 30min rather than it crashing) so I think the minimod is stable enough for a "beta" release (see the new thread with download link)

Also, I think I've got somewhere in solving the bot disembarking/bailing/switching position issue - if you open aibehaviours.ai and find this line under the FixedWeights table (which is used by both stationary guns and all non-driver positions on vehicles):
Quote
aiSettings.setBehaviourModifier Change 0.0

Change "0.0" to any positive value, and bots will be able to exit or switch vehicle crew + passenger positions. I set it to 1.0 - this may not be the optimum value (too low, and it won't have much effect - too high, and bots will keep jumping in and out of vehicles) but I did notice, for example, bots leaving AT guns when there were no enemy vehicles around, and tank hull gunners switching to the driver position when you (the driver) exit the vehicle.
A fair bit more work will probably be needed for bots to use APCs and trucks effectively, so I haven't included this fix in the 1.1 release of my mini-mod.

Offline djinn

  • Masterspammer
  • ****
  • Posts: 5.723
    • View Profile
Re: AI tweak/fix mini-mod v1.0 ready for download
« Reply #50 on: 06-03-2010, 22:03:42 »
In the words of Jumjum... HUZZAR!

That said, you make a mistake. The bots CAMP those bren-aas to the point where I have to execute half my army

You see, like other guns you set, bots will use them as defense weapons and quite deadly against aircrafts too.. two runs over one and I was 2/3rd gone in my Stuka

but yes, once we capped all flags but the two closest to the ocean, many of my teammates, spurred by a hysterical commander shouting endless commands to defend, camped practically all the AAs in their sector, making the allies require only jeeps and a few oldmen with boys rifles to reclaim the other mersa base...

Will definitely try the code you posted