Give access to the world-space mass properties of rigid-bodies
This commit is contained in:
@@ -158,8 +158,8 @@ impl RigidBody {
|
|||||||
|
|
||||||
/// The mass-properties of this rigid-body.
|
/// The mass-properties of this rigid-body.
|
||||||
#[inline]
|
#[inline]
|
||||||
pub fn mass_properties(&self) -> &MassProperties {
|
pub fn mass_properties(&self) -> &RigidBodyMassProps {
|
||||||
&self.mprops.local_mprops
|
&self.mprops
|
||||||
}
|
}
|
||||||
|
|
||||||
/// The dominance group of this rigid-body.
|
/// The dominance group of this rigid-body.
|
||||||
|
|||||||
@@ -245,7 +245,7 @@ impl Default for RigidBodyAdditionalMassProps {
|
|||||||
|
|
||||||
#[cfg_attr(feature = "serde-serialize", derive(Serialize, Deserialize))]
|
#[cfg_attr(feature = "serde-serialize", derive(Serialize, Deserialize))]
|
||||||
#[derive(Clone, Debug, PartialEq)]
|
#[derive(Clone, Debug, PartialEq)]
|
||||||
/// The mass properties of this rigid-bodies.
|
/// The mass properties of a rigid-body.
|
||||||
pub struct RigidBodyMassProps {
|
pub struct RigidBodyMassProps {
|
||||||
/// Flags for locking rotation and translation.
|
/// Flags for locking rotation and translation.
|
||||||
pub flags: LockedAxes,
|
pub flags: LockedAxes,
|
||||||
|
|||||||
Reference in New Issue
Block a user