Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

okonomiyaki

Imitating Walking/Movement- interaction with ground

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

It''s easy to implement controls to move the camera around, but I''m wondering what''s the best way to implement a first-person feeling of walking around on the ground. The ground is, lets say, bumpy, so one cannot simply extract the y value of the coordinate from a vertex or such. Does it require interpolation between vertices, and if so, how would one do that in 3-dimensions? To clarify, say that there''s a 5x5 heightfield that is rendered. I want to be able to feel like I''m walking on that. The x-value and z-value of the camera isn''t an issue; I need the y value to correspond to the terrain right below the camera (assuming the camera is about 5 units above the terrain to act like eye level). So at some points, the camera will be standing in the middle of one triangle. Am I supposed to interpolate between the three vertices to obtain the y-value corresponding to the point in the middle of the triangle/on that plane?

Share this post


Link to post
Share on other sites
Advertisement

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!