Author Topic: SP/bot AI modding: help/advice needed  (Read 561 times)

Offline Drawde

  • Jr. Member
  • **
  • Posts: 160
    • View Profile
SP/bot AI modding: help/advice needed
« on: 25-01-2010, 10:01:11 »
I used to do a lot of modding with BF1 and BF:V, both AI tweaks and weapon/vehicle "realism" mods - though I don't think I ever got anything complete and polished enough to release, I had a lot of fun! However, I never really got into BF2 modding, and in any case my BF modding skills are very "rusty" as I haven't played the game for a couple of years. Recently I decided to reinstall BF2 and try out some of the mods available, including FH2.

Anyway, after playing some offline games on various maps, and reading the threads in the single-player feedback section of this forum, I've had a look through the AI files to see if there's anything that can be tweaked to improve/fix the AI a bit, and it seems like there are a lot of inconsistent and odd values in the weapon ai.con files which could be contributing to the AI's erratic behaviour. For example, a lot of weapons have extremely high minimum range values - notably HE rounds for tank guns. Values for "deviation" (I think this controls how (in)accurate the AI is allowed to be when firing the gun) are also very inconsistent for weapons of the same type.

I've been attempting to modify this data to see if it makes any difference to the AI's behaviour, but haven't so far managed to get BF2/FH2 to load my modified data. I've tried the following:
- Created a new mod with its own folder, loading the data files from the FH2 folder via serverarchives.con - result: FH2 levels/maps don't show up on the map list, though the menu uses FH2's text colours and music (but the background movies are the default BF2 ones)
- Created separate ZIP files with the modified files, and modify FH2's serverarchives.con to load these as well as the original files - result: BF2 crashes almost immediately when loading a map. Unfortunately there doesn't seem to be an error/crash log stored anywhere to give me a clue as to what specifically could be causing the crash.
- Unzipped, modified and repacked the FH2 objects_weapons_server and objects_vehicles_server ZIP files - result: BF2 crashes when the map is about 75% loaded (regardless of whether or not I modify anything).

Any clues as to what I could be doing wrong?

Offline Drawde

  • Jr. Member
  • **
  • Posts: 160
    • View Profile
Re: SP/bot AI modding: help/advice needed
« Reply #1 on: 25-01-2010, 12:01:21 »
Looks like the problem with the second and third methods was due to my own stupidity; I packed the archives with the wrong folder structure. Having corrected this, I've now got FH2 to work with the modded files (using the second method - separate archives containing the modded files, loaded before the default FH2 files in serverarchives.con).
My AI tweaks seem to have made a noticeable difference to the vehicle AI, I played a game on "Siege of Tobruk" and the AI was much more aggressive and effective in its use of tanks. I even saw the AI firing emplaced mortars a couple of times! Still a lot of work to be done, but it shows that the AI can be improved.

I'd still appreciate any help/advice on how to get the first method (i.e a separate mod which refers to the FH2 files) working.