diff options
author | Campbell Barton <ideasman42@gmail.com> | 2009-04-14 16:34:39 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2009-04-14 16:34:39 +0400 |
commit | 3511f8ef9fe6a2a6491fbae3a44a407f280a19e0 (patch) | |
tree | 886dfd87cd3b9b05245f8e900f2e98c82ff376a2 /source/gameengine/Physics/common/PHY_Pro.h | |
parent | 1bc31fc7f901334f0ed20317985b2a84d51714ca (diff) |
BGE Physics
Clamp objects min/max velocity.
Accessed with bullet physics from the advanced button with dynamic and rigid body objects.
- useful for preventing unstable physics in cases where objects move too fast.
- can add linear velocity with the motion actuator to give smooth motion transitions, without moving too fast.
- minimum velocity means objects don't stop moving.
- python scripts can adjust these values speedup or throttle velocity in the existing direction.
Also made copy properties from an object with no properties work (in case you want to clear all props)
Diffstat (limited to 'source/gameengine/Physics/common/PHY_Pro.h')
-rw-r--r-- | source/gameengine/Physics/common/PHY_Pro.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source/gameengine/Physics/common/PHY_Pro.h b/source/gameengine/Physics/common/PHY_Pro.h index 32e63ac2f6d..0249fc3118a 100644 --- a/source/gameengine/Physics/common/PHY_Pro.h +++ b/source/gameengine/Physics/common/PHY_Pro.h @@ -35,9 +35,11 @@ struct PHY_ShapeProps { MT_Scalar m_mass; // Total mass MT_Scalar m_inertia; // Inertia, should be a tensor some time - MT_Scalar m_lin_drag; // Linear drag (air, water) 0 = concrete, 1 = vacuum - MT_Scalar m_ang_drag; // Angular drag + MT_Scalar m_lin_drag; // Linear drag (air, water) 0 = concrete, 1 = vacuum, inverted and called dampening in blenders UI + MT_Scalar m_ang_drag; // Angular drag, inverted and called dampening in blenders UI MT_Scalar m_friction_scaling[3]; // Scaling for anisotropic friction. Component in range [0, 1] + MT_Scalar m_clamp_vel_min; // Clamp the minimum velocity, this ensures an object moves at a minimum speed unless its stationary + MT_Scalar m_clamp_vel_max; // Clamp max velocity bool m_do_anisotropic; // Should I do anisotropic friction? bool m_do_fh; // Should the object have a linear Fh spring? bool m_do_rot_fh; // Should the object have an angular Fh spring? |