Author Topic: Bot Navigation Tweaks  (Read 10214 times)

Offline djinn

  • Masterspammer
  • ****
  • Posts: 5.723
    • View Profile
Re: Bot Navigation Tweaks
« Reply #15 on: 22-11-2010, 14:11:56 »
You'd still have the issue where a bot driving to the front comes across someone else and doesn't switch position to the defensive mg, but drives on or runs into a PIAT or zook rocket


I for one would love to see something like this implemented for the Marder and wespe, so that if only 1 bot is on it, it would do like Fh1 bots did, drive it to a point, change position and fire from a static position, changing back to driver position if need be, to cap a flag or something


Oh, and AGAIN, please let me know where I edit those values for vehicle position preference

Offline Remick04

  • Moderator
  • ***
  • Posts: 103
    • View Profile
Re: Bot Navigation Tweaks
« Reply #16 on: 22-11-2010, 17:11:53 »
I don't recall doing anything with the basic temps of vehicles. What basic temps levels are there are either Drawde's or Legion's doing. I may have fiddle around with the basic temp of a couple vehicles to make bots favor them over others, but I think I only did that with aircrafts.

I certainly wouldn't make the MG gunner position of higher value over the driver. But thank you Devilman for pointing that out, I'll try and fix it. Part of the problems with doing AI for FH2 is there are so many different vehicles and weapons most of which have their own AI that it's easy of little problems like this to fall through the cracks. I lose track of what vehicle or weapon files have been updated, and with new vehicles and weapons being added I lose track even further.

The only real changes to vehicle behavior I did from Drawde's AI was change the turn radius on most vehicles. I notice vehicles with a turn radius of '2' where having an easier time navigating the maps over vehicles with a turn radius of '5'. So I changed most of them to have a turn radius of '2' and notice some improvement so I kept it. You can try changing their turn radius back to '5' see if that improves anything.

Otherwise it's something in the aibehaviors.ai file that causing the bots to be "shy" in narrow areas. I've been fiddling around with my aibehaviors.ai file to try and figure out how to get infantry to aim down their sights. So my files are different than yours, and although I do see them get hung up on the occasional narrow path or corner, I doesn't seem to me as terrible as you guys are describing. Void seemed to notice some problems with the aibehaviors files so I'm hoping he can help smooth out vehicle movements for all of us. I'm not sure what I did that’s different than drawde's files other than the turn radius and increased ranges of engagement. It's possible the new ranges have bots in tanks trying to engage enemies that they previously where ignoring and that's why they seem to be driving differently.

Offline djinn

  • Masterspammer
  • ****
  • Posts: 5.723
    • View Profile
Re: Bot Navigation Tweaks
« Reply #17 on: 22-11-2010, 18:11:16 »
In most cases, it isn't, but you should see the German tanks in Goodwood, and you'd understand the concern.

About the ironsight aiming, you really should see why the G43 is handled differently. Its not done as much as say a gun in PR, but it happens at least 70% of the time with that gun compared to any other


Offline Void

  • Moderator
  • ***
  • Posts: 162
  • AI Dev
    • View Profile
    • ESAI at Moddb
Re: Bot Navigation Tweaks
« Reply #18 on: 22-11-2010, 20:11:44 »
Quote
Void seemed to notice some problems with the aibehaviors files so I'm hoping he can help smooth out vehicle movements for all of us

I guess that's my cue.

 Yeah, I've been working on FH2 vehicle AI. I've rewritten most of the AIBehaviors.ai file, and am also tweaking individual vehicle AI. I haven't yet messed with any PCO temperature settings.

I've made Goodwood my test map, and added in an extra PZIV for the Germans to have at map start. The pziv has no trouble crossing the underpass or going over the railroad. Neither does the Axis halftrack (sdkfz251_d).

In the tanks I'm working on, I have the turn radius set to 3.0, and the max speed I increased to 12 (from 10). I've decreased the value for throttle sensitivity a little, and for yaw sensitivity a lot. This, combined with increasing the lookahead values for both params, seems to help a great deal. I also increased the angle of the yaw scale slightly (don't know yet if this last is helping or hurting).

For pictures of the German halftrack and PZIV using the underpass and crossing the railway, look at this photobucket album.

I still don't feel like I'm all the way there, but I will probably soon post a beta of the work done on my "mini mod" so far. Should I use a separate thread for that? I don't want to completely hijack this one.


Offline djinn

  • Masterspammer
  • ****
  • Posts: 5.723
    • View Profile
Re: Bot Navigation Tweaks
« Reply #19 on: 22-11-2010, 21:11:23 »
Well, it IS on the same topic so I don't personally see a problem with it being right here

Aren't you totally changing tank handling then? Rather than how bots use tanks?

Offline Void

  • Moderator
  • ***
  • Posts: 162
  • AI Dev
    • View Profile
    • ESAI at Moddb
Re: Bot Navigation Tweaks
« Reply #20 on: 22-11-2010, 23:11:36 »
No, I'm not touching the actual tank controls. I'm not about to change that. I like the way FH2 tanks handle, honestly.

I am rewriting the AI templates for the tanks. I am changing the instructions for the bots regarding how exactly to handle a tank, in other words.

I have so far somewhat reduced the pointless cycle of backing up,going forward,backing up....and on and on.

In the tanks I've been working with, I am seeing more actual turning in both forward and reverse, and the bots are making some actual course corrections in this process.

 It is far from perfect, but I just ran a test on both Goodwood and Mareth Line, with and without my changes. I'm seeing better tank behavior on both maps with the new AI code.

I'm not limiting my changes to tanks, and have already rewritten the basic behaviors for all the vehicle types, but at this point I've only tuned the individual AI for most of the tanks and halftracks. I haven't started working on cars/trucks yet.

Interestingly enough, the only time I'm getting traffic jams on the Mareth Line bridges is when a truck sneaks in and blocks the way (backing up, going forward...) for the Crusaders and the Shermans.

Offline djinn

  • Masterspammer
  • ****
  • Posts: 5.723
    • View Profile
Re: Bot Navigation Tweaks
« Reply #21 on: 22-11-2010, 23:11:27 »
I would advice you use Drawde's approach in your minimod. So that rather than having fans replace every single vehicle code, they simply need to drop in a folder or zip and replace their serverarchives.con file to point to your patch.

Great work. can't wait to try it out

Offline Void

  • Moderator
  • ***
  • Posts: 162
  • AI Dev
    • View Profile
    • ESAI at Moddb
Re: Bot Navigation Tweaks
« Reply #22 on: 22-11-2010, 23:11:58 »
Quote
....rather than having fans replace every single vehicle code, they simply need to drop in a folder or zip and replace their serverarchives.con....

That is the approach I am taking. I have a server side archive that consists of nothing but the new vehicle AI templates. The only other extra is the new aibehaviors.ai file I'm working on, which will also need to be added.

Offline djinn

  • Masterspammer
  • ****
  • Posts: 5.723
    • View Profile
Re: Bot Navigation Tweaks
« Reply #23 on: 23-11-2010, 00:11:59 »
you are the man :-D

Offline Devilman

  • I belong to Naughty Club
  • **
  • Posts: 274
    • View Profile
Re: Bot Navigation Tweaks
« Reply #24 on: 23-11-2010, 02:11:04 »
That is the approach I am taking. I have a server side archive that consists of nothing but the new vehicle AI templates. The only other extra is the new aibehaviors.ai file I'm working on, which will also need to be added.

If your doing that,you may also want to run FH2 through the debugger,as there as a few vehicles with faulty,mistyped,missing or incorrect AI templates/plugins

sorry i dont recall which ones they are

Offline cannonfodder

  • Full Member
  • ***
  • Posts: 1.228
    • View Profile
Re: Bot Navigation Tweaks
« Reply #25 on: 23-11-2010, 10:11:41 »
@Remick: Sorry mate, bit of a brain-fail there, I meant Drawde... ;)


The whole problem with trying to fix FH2's AI is it was a hastily slapped together pile of shit to start with, and I mean no offence to the person(s) responsible, I have little doubt they'd agree.

But regarding tank behaviour, I did notice that with ESAI, they don't seem to persist as long with a gap they are having trouble with. They'll have a few go's, then try a different route/approach, as opposed to endlessly going back 'n forth on the spot.

It's probably just a side effect of them being more focused... :-\



Great sig too Void...

Offline Void

  • Moderator
  • ***
  • Posts: 162
  • AI Dev
    • View Profile
    • ESAI at Moddb
Re: Bot Navigation Tweaks
« Reply #26 on: 23-11-2010, 15:11:21 »
Quote
The whole problem with trying to fix FH2's AI is it was a hastily slapped together pile of shit to start with, and I mean no offence to the person(s) responsible, I have little doubt they'd agree.

I sorta get that feeling too, going through it. Many vehicles have AI templates that aren't even used when you look at the tweak file.

I'm slowly slapping together my own dung pile, but I think there is a chance it may be an improvement. We will see what we will see when I have a passable beta to post.


Offline djinn

  • Masterspammer
  • ****
  • Posts: 5.723
    • View Profile
Re: Bot Navigation Tweaks
« Reply #27 on: 23-11-2010, 15:11:40 »
And rest assured, Remick_04 has proven he can reverse engineer any good addition to make it part of the build. I say, the days or reinventing Fh2 AI are behind us. Go for it!

Offline Remick04

  • Moderator
  • ***
  • Posts: 103
    • View Profile
Re: Bot Navigation Tweaks
« Reply #28 on: 23-11-2010, 17:11:44 »
I sorta get that feeling too, going through it. Many vehicles have AI templates that aren't even used when you look at the tweak file.

I'm slowly slapping together my own dung pile, but I think there is a chance it may be an improvement. We will see what we will see when I have a passable beta to post.

I've been finding that with the weapons files also. The whole idleling bots on Operation Cobra is due to faulty AI for the colt1911. Same goes for the idle bots on Totalize with the bhipo.

So take your time Void, it seems the more hastily done things are the more likely little mistake occur, especially with so many files to manage.

Offline Void

  • Moderator
  • ***
  • Posts: 162
  • AI Dev
    • View Profile
    • ESAI at Moddb
Re: Bot Navigation Tweaks
« Reply #29 on: 24-11-2010, 03:11:49 »
I'm not rushing this project. It will be finished when I finish it.

 I've uploaded two videos that show some of my progress. The vids are of the British motorpool in Mareth Line - a before and after comparison. (I've done work on all the brit vehicles on Mareth.)

I'm running ESAI in both clips. The "After" clip is using all my new vehicle code. Oh yeah, I actually named this project the "VAI minimod". "V" stands for vehicle, unless it stands for Void. Take your pick.

Clips:

Mareth Motor Pool before VAI

Mareth Motor Pool after VAI