Sign in to follow this  

Terrain design

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

My current goal is to come up with a terrain design for my project. The project requires that the player should be able to build on terrain such things as roads, walls, turrets, etc. The project is not an RTS, but is an 3D action/strategy game. What would be the best terrain implementation for this type of project? I have done some research already, and Im starting to like ROAM, but Im not sure if thats appropriate. We want the terrain in the game to be tiled so that we can build objects on the terrain. Given this, we also worry about how collision and path-finding might be affected. We are using the OGRE rendering engine. It would be neat if we can also make the terrain modifiable in game. Any help or links are appreciated. Thanks. (forum search is not working atm, so I havent had luck with searching)

Share this post


Link to post
Share on other sites
You need to consider the versatility of the terrain in question.

Do you need overhanging cliffs or will the terrain be 2.5D. How much detail do you need e.g. do some bits need to break down in to ultra-fine detail whereas fields might be a few big polygons.

How are you going to represent these modifcations to the terrain? Are roads going to be simple overlays, a changed of texture, detailed geometry? Are walls going to be models plonked on top or do you want the terrain engine to handle that as well?

How do you want the terrain to change when you 'modify' it. Do you want a gradual transition, a quick pop to the new geometry or wont it be seen at all until the change is complete?

What kind of pathfinding are you doing?

Share this post


Link to post
Share on other sites
Hello,

If you are using a heightmap, I suggest you to check the work of Hugues Hoppes, especially the geoclipmap stuff. GCM are easy to implement and may allow you to modify the terrain as you want. You can also have a look to geomipmap (simple too, and it was probably a reflection base for HH, despite the fact that he did not even mention the existence of such technique). Seamus Mc Nally wrote a special ROAM in his game Treadmarks. This particular ROAM had the possibility to modify the terrain too. mittens (Trent Polack) wrote something about this when he was a coder.

About pathfinding, heightmaps works well. It is still a 2D map - you'll have to take the slope in account.

Building objects on top of the map might require a scenegraph - something which is built into OGRE AFAIR. You can also read the chapter 3 of the upcomming Eberly's book (here).

For roads, this may be somewhat complex. Morrowind uses a texture to render the road but then it cannot handle thin roads - because of the texture resolution. I believe there is an ongoing thread about road rendering in one of the GD forum (I can't remember which, and believe me or not, I'm lazy :))

Regards,

Share this post


Link to post
Share on other sites
You should really start off with static terrain. The problems are simpler... and if you get that working, then try to extend it to dynamic terrain. For instance, Kd-trees are well-known for providing fast collision detection and line-of-sight for static geometry... Stephen White wrote an article about using Nav Meshes to pathfind on static geometry.

Both of those can be extended to dynamic geometry... as long as it's not too dynamic :)

Kd-trees can rebuild nodes that contain modified geometry (if it's not very unfortunately placed), or simply delete and add primitives appropriately to existing leaves... and the GPG article has specific info about how Naughty Dog adapted their pathfinding to dynamic obstacles.

Share this post


Link to post
Share on other sites
I recommend that you start with something simle that just uses bruteforce and then you can optimize later.

You should be able to paint roads etc on the landscape as objects.

Share this post


Link to post
Share on other sites
Quote:
Original post by Metorical
You need to consider the versatility of the terrain in question.

Do you need overhanging cliffs or will the terrain be 2.5D. How much detail do you need e.g. do some bits need to break down in to ultra-fine detail whereas fields might be a few big polygons.


Nope, overhanging cliffs are not necessary. Yes, things would have to be detailed up close but not far away.

Quote:

How are you going to represent these modifcations to the terrain? Are roads going to be simple overlays, a changed of texture, detailed geometry? Are walls going to be models plonked on top or do you want the terrain engine to handle that as well?

We ditched roads due to changing other elements so roads are useless now. But walls will be static meshes placed onto the terrain. The terrain engine should not handle the walls, but then path-finding would have to accomadate for this.

Quote:

How do you want the terrain to change when you 'modify' it. Do you want a gradual transition, a quick pop to the new geometry or wont it be seen at all until the change is complete?

Originally we just wanted crators and bumbs after shells or mines had blasted near them. Now I think we will follow the advice on here and start simple with static terrain.

Quote:

What kind of pathfinding are you doing?

Good question. We haven't really thought much of this. There will be computer-driven vehicles. I'm not sure whether having preset path nodes are useful since walls and other obstructions can be built. I have heard A* is what RTS games use, and it requires tiled-terrain, so thats why I asked how I can figure out an terrain implementation that allows A* to work.

Thanks to all for the help. I will look into the suggested topics and articles. I have read the ROAM article on Gamasutra, and checked out the paper of Seamus from TreadMarks.

Share this post


Link to post
Share on other sites

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