Reset the rigid-bodies internal links properly.

This commit is contained in:
Crozet Sébastien
2020-11-03 15:08:06 +01:00
parent 477411c656
commit 71611d3e30
3 changed files with 8 additions and 8 deletions

View File

@@ -216,8 +216,8 @@ pub struct Collider {
impl Collider {
pub(crate) fn reset_internal_references(&mut self) {
self.parent = RigidBodySet::invalid_handle();
self.contact_graph_index = ColliderGraphIndex::new(crate::INVALID_U32);
self.proximity_graph_index = ColliderGraphIndex::new(crate::INVALID_U32);
self.contact_graph_index = InteractionGraph::<Contact>::invalid_graph_index();
self.proximity_graph_index = InteractionGraph::<Proximity>::invalid_graph_index();
self.proxy_index = crate::INVALID_USIZE;
}