I imported a mesh from a modeling tool, and gave it a colider. It collides correctly with other objects when I run my app.
I then changed the vertex x,y,z position of some points in that mesh via a script (runs once in awake). I move the vertex as it is done in the unity3d procedural mesh example “crumple mesh”.
The modified mesh no longer handles collison correctly. The collisions act as if I never moved any of the vertex. As if the collision and physics are engines are not aware I changed the shape.
Is there a way I can tell unity to update the collision data it is using (because my code changed the mesh shape) and use the new modified shape?
Unless I am mistaken, the best way to do what you want to do is with multiple bodies with sphere colliders connected by joints (ragdoll). Unless your object doesn’t have to deform constantly, like for example if it only deforms when it is hit by a rocket.