aboutsummaryrefslogtreecommitdiff
path: root/src/dynamics/rigid_body.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/dynamics/rigid_body.rs')
-rw-r--r--src/dynamics/rigid_body.rs10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/dynamics/rigid_body.rs b/src/dynamics/rigid_body.rs
index 78132b2..cd1a0dc 100644
--- a/src/dynamics/rigid_body.rs
+++ b/src/dynamics/rigid_body.rs
@@ -158,8 +158,8 @@ impl RigidBody {
/// The mass-properties of this rigid-body.
#[inline]
- pub fn mass_properties(&self) -> &MassProperties {
- &self.mprops.local_mprops
+ pub fn mass_properties(&self) -> &RigidBodyMassProps {
+ &self.mprops
}
/// The dominance group of this rigid-body.
@@ -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) {