Sign in to follow this  

racetrack mesh

This topic is 3778 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

heya coders, i'm thinking about coding a racing game - i already made myself somewhat comfortable with the beautiful ODE physics lib - and i need some help with the technical implementation. actually, especially the road.. take for example a game level from nfs: hot pursuit 2 (and similar games). it's roads seem to merge with the environment (rocks/buildings/..) at the side edges, and sometimes there's a shortcut route, also merging seemlessly with the main route, vertexwise. i was wondering how to code stuff like this, still retaining custom curvature, texturing and such. i hestitate to believe these guys just load up a huge 3dstudio mesh file, it seems to me their level editor does the magic, but how? when i think about it, there's mainly these 2 aspects i can't figure out. - forking roads - seemlessness with the $world at the road's edges i guess there's more than just a single solution, thoughts on this are pretty welcome :)

Share this post


Link to post
Share on other sites
It is quite possible for them to output the entire level as a 3dstudio mesh.
However this would make placing of nodes for the AI to follow difficult. The levels are probably done inside of a modeling package and then imported into a level editor where AI nodes and scripts and triggers are added.
Having a fork in a road isn't difficult just have a seperate node for each fork and let your ai car decide which node to go to next. You can do this randomly or choose which node to take depending on how close the car is to the center of the road. merging with the origonal road after taking the shortcut isn't a special case as there would be only one node for the car to travel to.

Share this post


Link to post
Share on other sites
Well, its pretty easy to select the road edges in an editor.
Even writing such an editor seems quite easy to me.
And if you have the edges beetween the road and the world, you can generate the AI waypoints from them.

Share this post


Link to post
Share on other sites

This topic is 3778 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.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this