Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Advanced Terrain - Get TERRAIN Ground Height help

Author
Message
Harlequin
14
Years of Service
User Offline
Joined: 22nd Mar 2010
Location: Melbourne (AU)
Posted: 7th Jul 2014 02:12 Edited at: 7th Jul 2014 02:18
Hi everyone,

I have been playing with Advanced terrain and noticed that the command "Get TERRAIN Ground Height" does not work as expected (or at least like the Matrix version. I always get zero height returned.
Terrain displays, and I swan a camera above the terrain, but when i move the camera, it appears at Ground height zero....
I am using a heightmap and a texture (no details though), so is this the problem?


sample code of the functions i am using attached.

thanks

It's late, I'm tired, out of coffee and now I'm wet.

Attachments

Login to view attachments
pcRaider
16
Years of Service
User Offline
Joined: 30th May 2007
Location:
Posted: 7th Jul 2014 04:00 Edited at: 7th Jul 2014 04:02
it's work

windowsXp

Attachments

Login to view attachments
Harlequin
14
Years of Service
User Offline
Joined: 22nd Mar 2010
Location: Melbourne (AU)
Posted: 7th Jul 2014 10:44
thanks pcRaider,

stepping though your code and my code I found the reason.

"Automatic Camera Collision PlayerCamera, PlayerCollisionRadius, 0"

Apparently the collision I had was bumping the camera below the terrain level after the first collision.

thanks.

It's late, I'm tired, out of coffee and now I'm wet.

Login to post a reply

Server time is: 2024-03-29 11:56:58
Your offset time is: 2024-03-29 11:56:58