Add methods to read the mass or volume of a collider.

This commit is contained in:
Sébastien Crozet
2022-07-05 15:15:17 +02:00
parent ba081fb6f5
commit 7831ebfc31
5 changed files with 32 additions and 11 deletions

View File

@@ -137,7 +137,7 @@ impl ColliderSet {
if let Some(parent_handle) = curr_parent {
if let Some(rb) = bodies.get_mut(parent_handle) {
rb.remove_collider_internal(handle, &*collider);
rb.remove_collider_internal(handle);
}
}
@@ -189,7 +189,7 @@ impl ColliderSet {
if let Some(parent_rb) =
bodies.get_mut_internal_with_modification_tracking(parent.handle)
{
parent_rb.remove_collider_internal(handle, &collider);
parent_rb.remove_collider_internal(handle);
if wake_up {
islands.wake_up(bodies, parent.handle, true);