Advertisement

Having trouble determining the Y value of my player on uneven terrain..

Started by September 27, 2002 05:55 PM
0 comments, last by Anachronism 22 years, 4 months ago
Hello... I''m trying to program a test program where a character in a game (a plain box in this test) walks around on an uneven terrain. The question is, how do I determine the players y value. Do I first determine what poly the character is in? What would be the fastest way to do this? More importantly, if I find out what poly the character is surrounded by, what sort of formula do I use to determine his Y position, based on the 3 verticies of the triangle when each vertex can have different heights? I''ve tried figuring it out on my own with no luck, and I have looked through a couple of opengl books with no luck. Prob because this is more of a math question. If anyone can point me in a helpful direction, or point me to sample code or tutorials I would appreciate it. Google is being stubborn and being very helpful. Thanks... -Dennis
Hi

i answered a similar question lately which should help in your case too:
http://www.gamedev.net/community/forums/topic.asp?topic_id=115235





Runicsoft -- home of my open source Function Parser and more

This topic is closed to new replies.

Advertisement