Page 1 of 3

Driving AI tutorial - Without making them braindead.

Posted: Sat May 31, 2008 4:09 pm
by >Shadow<
How to make AI actually drive their vehicles

Technical note: You probably need Phenom's 64 Plugin Pack for this.

Now then, normally AI shall only actually drive if they are in a ghost or warthog, and even then they usually drive around like maniacs running over their teammates. This tutorial shall hopefully fix this annoying problem.

Step 1 – Getting the AI to go forwards
So, you may thing that it’s the AI that have the problem. Well, you're wrong, as it’s the vehicle that is having the problem with the AI.

Open up Eschaton and go to the vehicle tag and go to the 32-bit bitmasks.
Change the bits so that in the end it looks like this:

[X]Speed wakes physics
[ ]turn wakes physics
[X]driver power wakes physics
[ ]gunner power wakes physics
[X]control opposite speed sets brake
[ ]side wakes physics
[X]Kills riders at terminal velocity
[X]Causes collision damage
[ ]ai weapon cannot rotate
[ ]ai does not require driver
[ ]ai unused
[X]ai driver enabled
[X]ai driver flying
[ ]ai driver can sidestep
[ ]ai driver hovering

Remove the check from "ai driver unused" and check "ai driver flying". When the AI believes that he can fly, he'll step on it. Now then, at this point your AI will act extremely retarded and will just run into walls and such. We now want to make the AI use their brains.

Step 2 - Making the AI avoid walls

Now go to the Floating Point Numbers section.
You will need to make them know how much obstacle avoidance they will perform. To do this, set the "ai avoidance distance" and "ai pathfinding radius" to something else. If you set them very high, then the AI will avoid objects that are far away. And vice versa if you set these too low. You also want to set the "throttle maximum" to something else because if you set it too high, than the AI will still act incredibly "dumb". A good speed for warthogs would be 0.15, because then they go fast, but aren't completely braindead. Tinker with this as you please. 0.15 also works incredibly well for Scorpian drivers. You may also want to set the "oversteering bounds to something like 220, since this can improve their driving. Also, if it isn't already, set the "destination radius" to 1.75.

Note: A good avoidance distance would be about 5, and a good pathfinding radius would be 10.
That should about do it for making AI drive ground vehicles, and not act completely retarded about it.

Props to Kirby422 for creating the original tutorial.

Have fun! ^.^

Posted: Sat May 31, 2008 4:16 pm
by Fonzeh
Sexy, I wonder if We do this, other people joining games can see the AI hogs moving? hm.... interesting short idea...

Posted: Sat May 31, 2008 4:56 pm
by Fuel
nice i've always wondered how to do this :)
maybe i can release spartan squad O_O
Edit: Wait is this in actv vehi or actr?

Posted: Sat May 31, 2008 5:03 pm
by >Shadow<
No, the vehi tag.

Posted: Sat May 31, 2008 10:48 pm
by TaxiService
*clap clap clap* Awesome. really good job. grazie! ^^

Posted: Sat May 31, 2008 10:50 pm
by Mota-Lev
Wow. I never noticed this till taxi posted.


This looks awesome. Testing now.

Posted: Sun Jun 01, 2008 2:12 am
by Moxus
This comes at just the right time... thanks Shadow!

-=Moxus=-

Posted: Sun Jun 01, 2008 3:55 am
by G[v]N
How 'bout a link to Phenom's 65 Plugin Pack? :P

Posted: Sun Jun 01, 2008 3:59 am
by DanDan
YES, i would like that.^

Posted: Sun Jun 01, 2008 4:06 am
by Dirk Gently
I did a tutorial similar to this once here.

(dang, where is it now :\ I swear I posted it)

anyway here is the other link to it.

(dang again, I cannot reach Halomods. :\ )

Posted: Sun Jun 01, 2008 7:41 am
by >Shadow<
I would post the link, but Halomods is currently down...
Anyways, here is how to install it once you've got it:

1. Rename the Folder to "HMT style plugins" (It should be the same as in your Eschaton folder.)

2. Back up your original "HMT style plugins" (The one that comes with your download of Eschaton.)

3. Stick the backup in a folder somewhere.

4. Drag Phenom's plug pack (Now named HMT style plugins) and stick it in the Eschaton folder. Now when you select HMT style plugins in Eschaton, you will be able to run Phenom's Plug pack in Eschaton!

Posted: Sun Jun 01, 2008 9:41 am
by Fuel
just use google :roll:

Posted: Sun Jun 01, 2008 9:51 am
by Dirk Gently
what do you mean? I was looking for post I made.

Posted: Mon Jun 02, 2008 12:53 pm
by Monk34
The bitmasks your were talking about arent there. the 32-bitmask folder has the Vehicle ID only in it.

Re: Driving AI tutorial - Without making them braindead.

Posted: Mon Jun 02, 2008 12:57 pm
by Kayar
>Shadow< wrote: Technical note: You probably need Phenom's 64 Plugin Pack for this.