Jump to content

Getting Terrain Data


Shard
 Share

Recommended Posts

Hey everyone, I'm doing the raycast check for my A* to determine if the square is open or not and I needed a little help figuring some variables out.

 

I'm looking to get the following variables:

- The max step height

- The terrain height

- The terrain slope

 

I did take a look at the wiki but it seems the wiki only accepts an x and y coordinate for parameters. I can only assume this is based of the resolution of the map. In which case, how do I get the resolution of the map? And how would I go about converting a TVec3 into x and y coordinates?

simpleSigPNG.png

 

Programmer/Engineer/Student

www.reikumar.com

 

2.6 GHz Intel Core Duo - nVidia GeForce 8600 GT - Windows 7 64-bit - 4 Gigs RAM

C++ - Visual Studio Express - Dark GDK - Leadwerks SDK

Link to comment
Share on other sites

You might be interested in: http://leadwerks.com/werkspace/index.php?/topic/1250-plane-to-hug-terrain/page__view__findpost__p__11632

You can get the slope by either reading out multiple heights and calcuationg it or by using TerrainNormal().

 

Unfortunately, there's no command to get the resolution of the terrain...

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...