Add accessor to get the locked axes of a rigid-body

This commit is contained in:
Sébastien Crozet
2023-01-15 12:23:32 +01:00
parent 9b5ccb95e7
commit d2ebb25c22

View File

@@ -184,6 +184,12 @@ impl RigidBody {
}
}
/// The axes along which this rigid-body cannot translate or rotate.
#[inline]
pub fn locked_axes(&self) -> LockedAxes {
self.mprops.flags
}
#[inline]
/// Locks or unlocks all the rotations of this rigid-body.
pub fn lock_rotations(&mut self, locked: bool, wake_up: bool) {