diff options
author | Vadim Savchuk <vsavchuk@productengine.com> | 2010-07-05 16:55:05 +0300 |
---|---|---|
committer | Vadim Savchuk <vsavchuk@productengine.com> | 2010-07-05 16:55:05 +0300 |
commit | 510958f6c4f4f1c1377fec0e484d7ef4d1d95030 (patch) | |
tree | de0cf19126d32f23e05e0c2909a90ce49f34eaf2 /indra/llcharacter/llkeyframewalkmotion.cpp | |
parent | 863e6ea4035683610e35bfa90171b7a35b9dce64 (diff) | |
parent | 3de5be44adb91d3a7e1ff3ca8b415964a722ce49 (diff) |
Merge from default branch
--HG--
branch : product-engine
Diffstat (limited to 'indra/llcharacter/llkeyframewalkmotion.cpp')
-rw-r--r-- | indra/llcharacter/llkeyframewalkmotion.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/indra/llcharacter/llkeyframewalkmotion.cpp b/indra/llcharacter/llkeyframewalkmotion.cpp index 0587e5642c..4a1aca62bc 100644 --- a/indra/llcharacter/llkeyframewalkmotion.cpp +++ b/indra/llcharacter/llkeyframewalkmotion.cpp @@ -289,7 +289,8 @@ BOOL LLWalkAdjustMotion::onUpdate(F32 time, U8* joint_mask) F32 foot_speed = speed - ((foot_slip_vector * avatar_movement_dir) / delta_time); // multiply animation playback rate so that foot speed matches avatar speed - F32 desired_speed_multiplier = llclamp(speed / foot_speed, 0.f, ANIM_SPEED_MAX); + F32 min_speed_multiplier = clamp_rescale(speed, 0.f, 1.f, 0.f, 0.1f); + F32 desired_speed_multiplier = llclamp(speed / foot_speed, min_speed_multiplier, ANIM_SPEED_MAX); // blend towards new speed adjustment value F32 new_speed_adjust = lerp(mAdjustedSpeed, desired_speed_multiplier, LLCriticalDamp::getInterpolant(SPEED_ADJUST_TIME_CONSTANT)); |