Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

szinkopa

autopilot in car driving game

This topic is 5282 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I am intereseted how can I make an autopilot in a car driving game. What method is the best for this? How should it be done?

Share this post


Link to post
Share on other sites
Advertisement
Depends on what u want the car to be doing. Supposing you wanted it to go around a track u would have to work out the optimum line for the car to follow. Also another way to do this is supposing you had barriers on either side and all the way around your track, u could get the car acting like a robot mouse, if it hits the left (or goes near) steer right, etc.

Also u would have to be able to know the ability of handling that your car has. If it knows its going to fast for it to be able stop before a barrier (that is directly ahead) u would get it to break. For now i wouldn''t worrie about sideways slip or anything.

regards

ace

Share this post


Link to post
Share on other sites
Firstly, you should really check out steering behaviour, as will likely provide useful in your situation.
If your game world is merely a racing track that does not branch in multiple directions then you can probably program your car to simply follow the centre path, avoiding obstacles and other cars as time progresses.
However, if your situation resembles an inner city web such as that seen in games like Grand Theft Auto then you may also need to make use of a pathfinding algorithm to navigate a series of waypoints that describe the driving environment.

[edited by - jack_1313 on June 5, 2004 1:10:44 AM]

Share this post


Link to post
Share on other sites
Thanks for the replies.
I will check out that document.
The game is a rally-like game with a track, it''s quite simple yet. You can try it, the URL is in my profile.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!