AI Driver Toolkit 3.0

AI Driver Toolkit

Create races against NPCs or animate your cars and other vehicles in your urban games. The AI Driver Toolkit brings life into your Unity game by giving your vehicle models artificial intelligence.

The toolkit contains:

  • AI vehicle controller
  • Obstacle Avoidance
  • Respawn System
  • Waypoint Editor
  • Speed areas
  • Example vehicle
  • complete demo scene incl. player controller

Version 2.0:

The following video shows some scenes of version 2:

Version 3.0:

The new version 3.0 is out now. It includes a separate AI for combining it with other vehicle physics like Unity’s car turial or Edy’s vehicle physics. The demo scene demonstrates the new version of AI Driver Toolkit.

Version 3.2:

A new spline path tool optimize your paths. Because of the respawn system this is helpful in both controlling modes (obstacle avoidance and of course the waypoint mode).

Shops

AI Driver Toolkit is available in the Unity Asset Store and at GamePrefabs.com . So if you are interessted in, visit them! Please note the version no. (see above)!

Play demo scene

See the AI Driver Toolkit in action in the small demo scene, which is included in the package.

More infos

Documentation and tutorials you can find here: Tutorials and Documentation.

No application is perfect and every tool has bugs. So if you find problems or have some ideas to optimize this tool, you can contact me at hummelwalker[at]seifert-ing.de or Twitter @hummelwalker.

34 Responses to AI Driver Toolkit 3.0

  1. dij says:

    There are a couple of thing you must add to this release

    1. an option to hold down a keyboard button and place way points, having to go back and click ‘add waypoint’ makes the precess take 4-5 times longer atleast.

    2. Group waypoints, so you can have one main setting (speed) and all the waypoint you add use this speed setting, this will speed the proses of setting the speed for waypoints up ten times.

    Thanks

  2. Carsten Seifert says:

    Hi dij,

    thank you for your ideas.
    To your second: I don’ know if I understand you correclty, but I think the toolkit already does it. If you change the speed parameter to 150, all waypoints you’ll create up then will get this speed automaticly. Is this the functionality you mean?
    To your first idea: I know the problem. Thanks for your input, perhaps I’ll implement your solution :)

  3. Sobhan says:

    Hi Carsten Seifert

    your posts here made me to ask some questions !

    1 – does this version 3 (AI Toolkit) released ? or your gonna release it in future ?

    2-does it have a good AI system ? i ask this because i write my own AI system for car to follow the waypoints but it sucks! because when the AI car have an accident with Player car or something else that make it (AI Car) have a J or U turn , then the AI do not correct the Cars direction and car will continue following Waypoints Backward and with Revers gauge !!!!

    so does your AI system have options or ability to avoid this problem ???
    3- does it have Gauges for Speed and RPM ???? or will you add this future to it ?

    thanks so much

  4. Carsten Seifert says:

    Hi Sohan,

    1) yes, it’s released.
    2) At first my AI has a respawn system. As soon as the AI recognize that the car isn’t on the correct way (or the vehicle overturns or the vehicle can’t reverse,…), the car respawns and everything is okay.

    You have to controlling mechanismens. 1. By waypoint : Then you have absolutly no problem with this 2. By Obstacle Avoidance. If your AI make 180 turn this could happend, but in this case the respawn function brings your car to the right way. So in the end, it’s not a problem.

    3) You have speed areas where you define the max speed of the car. So in different areas of the road, the AI drives different max speeds.

    • Sobhan says:

      Hi again thanks for the replay !

      but i think i ask my 3rd question in a bad way :D

      i mean does it have any Speedometer and Tachometer Gui ??? because i really need a good Gui like these and if your project have them its so great and i purchase it opened eye !!!

      another question is , can i use my own cars ? or it will get errors if i use my own cars ???

      5th question is : does it have any features to give the cars a mode like drifting ???

      i’ll be really thankful if you answered these question too .

      Best regards dear friend,
      Sobhan

  5. Carsten Seifert says:

    Hi again :)

    3) the toolkit doesn’t include a gui.
    4) Yes of course, thats possible. Please have a look to my first video: http://www.seifert-engineering.de/ai-driver-toolkit/ai-driver-toolkit-tutorials/
    5) You can mode your cars like you need them, because my motor-script use wheelcolliders, which you can modify them like you need them. By the way, you can use in addition to this you can use the scripts of the Unity Car Tutorial whichs drifts a lot. Have a look to this example game: http://www.der-softwareentwickler-blog.de/onlinetest/cartutorial/WebPlayer.html One AI car use Unitys scripts (with drifting), one AI car use my scripts.

    • Sobhan says:

      Hi

      Thanks in advance !

      will you please add a Gui which Include a Tachometer and Speedometer ?

      if the problem is money i can spend 15$ more i mean buy it for 100$ i know

      that’s not the actual cost of your efforts but please help me ! i need it so much !

      and really a poor about money !!!

      Do you have any tutorials on how to use that 2? i mean Unity tuts script for A.I and your script for Player ?

      mmm…. lets talk about this in private … is it possible for you ?

      if its ok please send me an email

      thanks

  6. Sobhan says:

    Hi dear Friend !

    i decided to spent 20$ more i mean 120$ if you make the following to your project :

    1-A Gui which a Tachometer and Speedometer included.

    2-some good and all aspect tutorials too

    adding some features like this : http://www.youtube.com/watch?v=rmQybvZblJ8&feature=related

    i have a question too :

    can use your other script features like obstacle avoidance and etc. with Andrew’s Car

    tutorial or any thing similar to it ? like this one : http://www.youtube.com/watch?v=rmQybvZblJ8&feature=related ?

    thanks if you like please send me an email.

  7. Pablo Vidaurre says:

    Dear Seifert Developers,

    Your AI solution called my attetion while seeking fro AI solutions for an Unity based racing game.

    Even more when I saw it does directly support Edy vehicle physycs wich is the one I´ve aquired for vehicle physycs.

    Now, what I’m interested in is a racing AI toolkit with expanded toolset to match some other available packages or comercial games.

    I.E. unique racing line, as alternative to waypoints. Other features appearing in this video regarded to racing line are also very interesting.
    http://www.youtube.com/watch?v=Zu-0HrLbyKI

    So, are you ready to extent the AI toolkit based on user demands even if do not fit the mainstream if they are paid appart?

    regards,

    Pablo

  8. Jonathon says:

    I have a few questions about your product.

    The examples show cars racing, how well would the ai handle driving like street traffic and in lanes?

    What I’m looking for is for cars to be able to drive in heavy traffic on a congested road with different cars having different driving behaviors, sometimes slowing down and staying behind another car, other times passing them like is shown.

    Can they be made to follow and switch lanes? And can they be made to slowdown and stop like at a traffic light? The same goes for following other “rules of the road”

    How easily can the code be modified to get different AI behavior? I’d like to be able to have AI sometimes be aggressive, tailgating and cutting off a driver, other times being passive or driving sloppy like a drunk driver.

  9. Carsten Seifert says:

    @Pablo: I’ve send an eMail to you.

  10. Carsten Seifert says:

    @Jonathon : Simple street traffic is not a problem. But behaviours like you descriped (traffic lights, other “rules of the road” etc.) won’t be supported.

    If you need different behaviours, AI Driver Toolkit includes a parameter called Steering Mode. You have two modes: Cautious and Tough which defines if the car recognize cars which drive besides them. In addition to this, you have many options like changing the steering speed and the steering radius, you have speed areas for defining the max speed of the car in different areas of the road.

    If you have more questions, don’t hesitate to ask me!

    Carsten

    • Jonathon says:

      Thanks for the quick reply!

      Is the code compiled and inaccessible or can it be edited to add new features? and can multiple cars use the same waypoints?

      Thanks again,

      Jonathon

      • Carsten Seifert says:

        1)The code isn’t compiled. You can change the scripts like you need them.
        2)Yes, cars can use the same waypoints, that’s absolutly no problem.

        Greetings,
        Carsten

  11. mainstgrfx says:

    I posted some questions on using your AIDriver toolkit on the Unity forums but I’ll repeat them here since we’re under time constraint:

    Just bought the AIDriver Toolkit – really nice! We’re just putting it throught it’s paces and I have a couple of questions that don’t seem covered in the docs:
    In the AIDriver Controller script what is the “Steer Absolut” checkbox for? I haven’t seen any difference whether it’s on or off.
    In the AIWaypoint script, what is the checkbox “Use Trigger” for?
    How do you use the “SwitchOAMode” script? To what object does this get attached?
    How do you use the “ShowRaycasts” script? It seems intuitive but nothing happens no matter what Object I place it on.
    The “Max Steer Angle” defaults to 20. Isn’t that really low compared to real world auto steering angles? Setting it higher will allow the vehicle to turn sharper correct?
    Thanks in advance and thanks for a great product.

    Much of this thread is devoted to new ideas for AI so let me chime in too. One thing we really, really want is the ability for a NP car to branch off from waypoints and follow another path. For example, a racecar makes a pit stop based on dynamic logic like “if lapnum == 25… then switch to a branching set of waypoints to the pit. Of course if the branching logic used a random number to decide a course of action (among 3 or more paths?) it would really bump up the AI factor. Just a thought.

    • Carsten Seifert says:

      @mainstgrfx:
      Thanks a lot for your comment,mainstgrfx. Sadly I forgot to refresh my documentations since my last update, sorry!

      My documentation is updated now! Please have a look to it: http://www.seifert-engineering.de/ai-driver-toolkit/ai-driver-toolkit-tutorials/

      The most questions (“Steer Absolut”, “Use Trigger” ,”SwitchOAMode”, “ShowRaycasts”) can be find in my docs. In addition to that, here are some additional comments:

      Quote Originally Posted by mainstgrfx View Post
      The “Max Steer Angle” defaults to 20. Isn’t that really low compared to real world auto steering angles? Setting it higher will allow the vehicle to turn sharper correct?
      Absolutely. I set this default value because cars drive not so hard curves while racings.

      By the way, I anwered in the forum, too!

      Carsten

  12. paul says:

    ive asked a number of questions but havent received any replies ,so ill ask again the ai motion is not that realistic im a noob and was wondering can you make a tutorial on implementing rapidunity vehicle resource pack as everytime i import it i get errors
    ‘AIDriver.m_isBraking’ is assigned but its value in never used thanks

    paul

  13. paul says:

    ive managed to add the aikit to rapidunity vehicle resource pack but im getting this error now
    Assets/Plugins/AIDriverToolkit/Scripts/AIMotorMapping.cs(25,13): error CS0246: The type or namespace name `CarControl’ could not be found. Are you missing a using directive or an assembly reference?

    any ideas

    thanks
    do you have a proper email account seems daft posting questions here

  14. Carsten Seifert says:

    Hi Paul,

    I’m sorry, but I got no messages in the past from you :( Did you post them here or in the unity forum?

    To your questions:
    To your second question: It looks like you activate the “Edy”-lines in my AIMotorMapping script like in the Edy-Tutorial. If you have no Edy scripts, that cause the problem.

    The first question I didn’t understand, because of two points: 1. the value of variable will be used 2. that shouldn’t cause an error.

    Could you send your project to me for testing?

    Greetings,
    Carsten

  15. Jon F. says:

    Does your AI driver toolkit work with terrain? For instance, can a vehicle avoid a steep hill in the terrain but go over a non steep hill?

  16. Carsten Seifert says:

    Hi Jon F.,

    you have many options for realizing complexe scences with uneven terrain.
    E.g.: You can switch between the controlling modes (waypoint mode or obstacle avoidance), when its necessary. Or you work with ignore layers to ignore very uneven terrain and work with unvisible trigger colliders when you have to recognize steep hills.
    Or you optimize the raycasts to get a good result.

    The way you are using depents on your indiviuell game situation. I hope it helps and doesn’t confuse yourself.

    Greetings,
    Carsten

  17. Ryan says:

    Can I purchase AI toolkit straight from you? Can you mail me the details?

  18. Carsten Seifert says:

    @Ryan Yes, thats possible. I’ll send you details via eMail.

  19. Ryan says:

    Heyy,
    I finally purchased AI toolkit from Unity Asset Store. It is good. :)

    But still I feel it can be done way much better. You may want to implement the rubber band AI and other intelligent features into the AI. Currently it has issues like:
    1) Re-Spawning of cars when not able to find path is a kinda spooky.
    2) AI Cars keep on just running without caring about the player car(Rubber Band AI)
    3) AI not smart enough to detect objects in its path perfectly and avoid them.

    You may want to look at this:
    http://www.gamasutra.com/view/feature/3920/the_pure_advantage_advanced_.php

  20. Carsten Seifert says:

    Hi Ryan,

    thank you for buying!

    And thanks for the link and your improvement tips. I will think about them to improve the toolkit :)

    Greetings,
    Carsten

  21. Arthur Carlos says:

    hello again,

    You have not answered my question and the post no longer exists, I would like a reply please because when you put your package generates several errors in my game (was working perfectly until then).

    Arthur

  22. Arthur Carlos says:

    Hello again,

    First I’m sorry it had not seen the answer, and congratulations on your product.

    I opened your demo include in package and compiles perfectly, but when I try compile to Android some variables can not be recognized

    Assets / AIDriverToolkit / Scripts / Additional / Car-Modified.js (412.39): BCE0019: ‘Skid’ is not a member of ‘SoundController’.
    Assets / AIDriverToolkit / Scripts / Additional / Car-Modified.js (498.80): BCE0005: Unknown identifier: ‘normPower’.

    Ps. I did not change anything, just tried to recompile for Android platform.

    I have another question, I followed some posts and the question about DRIFT, can you give me some help where i change to implement the DRIFT ?

    Arthur

  23. Arthur Carlos says:

    Forget ANDROID problem, its my mistake

    I just want your help on the issue about DRIFT

    Arthur

  24. Carsten Seifert says:

    If you need drift, you can do this by changing the wheel collider parameters themself (e.g. stiffness).
    But note, if you work with drift, it’s harder to find good parameters for the AI.

    Greetings,
    Carsten

  25. Arthur Carlos says:

    Hi Carsten,

    My game runs on orthographic camera and the curves are always 90 degrees when I use your AI system it behaves very strangely.

    As you can see the video
    http://www.youtube.com/watch?v=l_yMKbS2I5U

    How can I solve this problem?

    Tks
    Arthur

  26. Ryan says:

    Heyy… I made some improvements in your AI toolkit… check out…
    http://forum.unity3d.com/threads/118702-Rubberband-AI-Implemented-in-AIDriverToolkit

    Shall I send you the code for it?

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>