Finding the ground (part II)

Discuss any questions about BEPUphysics or problems encountered.
Post Reply
jbosch
Posts: 43
Joined: Sat May 29, 2010 4:42 pm
Contact:

Finding the ground (part II)

Post by jbosch »

Hi,

I think I've found a polstergeit in my code. I initialize 2 cylinders over a plane, this way:

Code: Select all

bowl[0] = new Cylinder(new Vector3(-5.0f, 0.15f, -50.0f), 1.0f, 0.5f, 0.1f);
bowl[1] = new Cylinder(new Vector3(-3.0f, 0.15f, -50.0f), 1.0f, 0.5f, 0.1f);
It works fine! But when I do this...

Code: Select all

bowl[0] = new Cylinder(new Vector3(-5.0f, 0.15f, -50.0f), 1.0f, 0.5f, 0.1f);
bowl[1] = new Cylinder(new Vector3(5.0f, 0.15f, -50.0f), 1.0f, 0.5f, 0.1f);
The bowl[1] jumps and has a strange behaviour!

You can see it here: http://www.verticaling.com/video.avi
Jesús Bosch
XNA BLOG: http://geeks.ms/blogs/jbosch
jbosch
Posts: 43
Joined: Sat May 29, 2010 4:42 pm
Contact:

Re: Finding the ground (part II)

Post by jbosch »

changing the height of the cilinders (make them higher) works well... is that a bug?
Jesús Bosch
XNA BLOG: http://geeks.ms/blogs/jbosch
Norbo
Site Admin
Posts: 4929
Joined: Tue Jul 04, 2006 4:45 am

Re: Finding the ground (part II)

Post by Norbo »

In the video, it looks as if they are both stuck in the ground. The one in the middle of a triangle rises smoothly upward, while the one on a triangle edge gets pushed around resulting in a pop. If the triangles are at a height of 0, then the cylinders (with height 1) would need to be at around 0.54-0.58.

I have plans to improve the inter-triangle collisions in meshes, as well.
Post Reply