I have an issue with bullet physics when using triangle mesh as the collision shape.
My scenario is this:
I have a static physics body on a node, and set the collision shape for it to triangle mesh (because I have created a custom geometry).
On top of that body I have a dynamic body, with a collision shape of box.
When the simulation is started the dynamic box moves up a little. In the debug view of the physics world I can see that there is a small gap between the static body and the dynamic body.
But the debug view seems to be showing the shapes correctly.
If I apply some force to the dynamic body it behaves very strange, jittering on top of the static body.
Even if I don’t use my custom geometry, instead use the ordinary Box.mdl with triangle mesh as the shape I get the same strange behaviour.
If I use a convex hull for the static body, I see the little gap between the bodies but I don’t get the strange jittering.
If I change the static body to a box, then all is fine.
Anyone have any clue of what’s going on here?
Btw, I’m using UrhoSharp (but I don’t think it should matter).