Jump to content

Heightmap with the physics engine


RaananW
 Share

Recommended Posts

Roller coaster time!  Just one tiny applyImpulse, and the coaster goes for 3 weeks without re-impulse!  WOW! 

 

How many shades of gray are there?  :)  That's how many steps the Slinky/sphere will need to traverse.

 

Actually, I just want to put some marbles in a bowl, for now.

 

Any surface is a (potentially physics-active) heightMap (soon), eh?  Wow.  That's a huge huge statement, Raanan!

 

The insides of tubes, too?  Too fun!

 

Thanks for your work on this, R!  Well done! 

Link to comment
Share on other sites

Both are coming this evening. I'm waiting for the new version and the new cannon to be deployed.

@wingnut - I'm already experimenting with other kinds of structures. But a height map impostor will only fit open objects (a bowl is a good example, or any open surface). The second limitation is that the physics will only be enabled for the upper part of the mesh. below the results are unexpected. I'm still working on making it as easy as possible for the developer and will then commit the changes.

Link to comment
Share on other sites

Demo time!

http://www.babylonjs-playground.com/#EXL6K

a mouse click will throw the balls in a random direction.

 

I will create a better one once I fix the little bug (which is fixed with line 48). Once this is fixed (Shouldn't be long, I know exactly what the problem is) It is ready to be used :-)

Link to comment
Share on other sites

Yei! fun with heightmaps!

http://www.babylonjs-playground.com/#D3LQD

the latest update allows you to use any flat and square surface as a height map. the ribbon in this PG is a wonderful example. A mouse click will release spheres and boxes for your viewing pleasure.

if you have any questions, please let me know.

 

As you can see, rotation etc' can be applied on the meshes, and update physics body position works as well.

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.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...