BulletSim: stop avatar from sliding VERY slowly after walking by

only zeroing the movement motor in the UpdateProperties routine.
This commit is contained in:
Robert Adams
2012-12-25 23:54:10 -08:00
parent bbc5a5089f
commit 5f71ee57c4

View File

@@ -260,7 +260,6 @@ public sealed class BSCharacter : BSPhysObject
public override void ZeroMotion(bool inTaintTime)
{
_velocity = OMV.Vector3.Zero;
_velocityMotor.Zero();
_acceleration = OMV.Vector3.Zero;
_rotationalVelocity = OMV.Vector3.Zero;
@@ -772,9 +771,9 @@ public sealed class BSCharacter : BSPhysObject
// the motor can be turned off. Set the velocity to zero so the zero motion is sent to the viewer.
if (_velocityMotor.TargetValue.ApproxEquals(OMV.Vector3.Zero, 0.01f) && _velocityMotor.ErrorIsZero)
{
_velocityMotor.Enabled = false;
stepVelocity = OMV.Vector3.Zero;
ZeroMotion(true);
stepVelocity = OMV.Vector3.Zero;
_velocityMotor.Enabled = false;
DetailLog("{0},BSCharacter.UpdateProperties,taint,disableVelocityMotor,m={1}", LocalID, _velocityMotor);
}