soft_body_removal
Removing a soft-body (r3RemoveSoftBody) removes everything the engine created for it: its root
body, the proxies of its clusters, the colliders of its surface and of its deformable meshes, as well as the joints
attached to any of them. One cluster can also be removed on its own
(r3SoftBody_RemoveCluster):
- Example 2D
- Example 3D
// Removing a soft-body removes its root body, its proxies, its colliders and the joints
// attached to them.
r2RemoveSoftBody(rope_handle);
// A cluster can be removed on its own.
r2SoftBody_RemoveCluster(jelly_handle, cluster);
// Removing a soft-body removes its root body, its proxies, its colliders and the joints
// attached to them.
r3RemoveSoftBody(rope_handle);
// A cluster can be removed on its own.
r3SoftBody_RemoveCluster(jelly_handle, cluster);
warning
Removing a cluster also removes the particles that only this cluster covered, with their elements and their
attachments. Therefore removing the last cluster of a soft-body removes the soft-body itself. Note that removing the
proxy of a cluster with r3RemoveRigidBody is equivalent to removing the cluster.