Sign in to follow this  
Herbert

how can I make this dude stand on the ground after dropping from a height

Recommended Posts

Hey guys
I try to make a simple sport game, so first, I want to make a person stand on a ground  who can run and jump on it, and I have trouble on the jump part,
the dude won't stop by the ground when he is dropping from a height(https://www.babylonjs-playground.com/#1BZJVJ#113)
if the position.y is 0, then the dude can stand fine on the ground

Share this post


Link to post
Share on other sites

If you use a GroundMesh (whatever its name), you can get the ground altitude y at any (x, z) 2D coordinates.

In other terms : if your buddy y position is higher than the altitude at buddy position (x, z) then he's above the ground, he can keeping falling else ... up to you ;)

Share this post


Link to post
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.

Loading...
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.