Ramps

Discuss any questions about BEPUphysics or problems encountered.
Post Reply
BabaJustin
Posts: 30
Joined: Mon Apr 25, 2011 6:07 pm

Ramps

Post by BabaJustin »

I am trying to get a puck to be able to go off a ramp. Currently, my puck just collides with the base of the ramp and either comes to a dead stop, or flips wildly into the air. Not quite the "launching" effect I was going for.

My ramp is a Convex hull (I've tried making it dynamic and non-dynamic).
I've tried using a Cylinder for the puck, and also a slightly rounded Convex hull.

What would be the best way to go about creating a ramp that is a separate entity from my environment?
Norbo
Site Admin
Posts: 4929
Joined: Tue Jul 04, 2006 4:45 am

Re: Ramps

Post by Norbo »

Sinking the ramp into the ground a bit might help. If it's just ramming into the base of the ramp, sinking it will avoid exposing that part and should provide a smoother launch.

Triangle meshes have better boundary handling, so if it's possible to have an environment with the ramp built in, that would probably be the best bet.

In either case, using CCD might also be a good idea (entity.PositionUpdateMode = PositionUpdateMode.Continuous). That will prevent it from penetrating too deeply and getting a possibly weird collision normal depending on the speed (or flying through the ramp, in the case of a mesh).
BabaJustin
Posts: 30
Joined: Mon Apr 25, 2011 6:07 pm

Re: Ramps

Post by BabaJustin »

Thanks!

Making the ramp a StaticMesh ended up being the solution.
Post Reply