aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/ScenePresence.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/ScenePresence.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/ScenePresence.cs6
1 files changed, 5 insertions, 1 deletions
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
index ae4bd17..f6295b1 100644
--- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs
+++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
@@ -2430,8 +2430,12 @@ namespace OpenSim.Region.Framework.Scenes
2430 float speed = Velocity.Length(); 2430 float speed = Velocity.Length();
2431 float velocidyDiff = Vector3.Distance(lastVelocitySentToAllClients, Velocity); 2431 float velocidyDiff = Vector3.Distance(lastVelocitySentToAllClients, Velocity);
2432 2432
2433 // assuming 5 ms. worst case precision for timer, use 2x that
2434 // for distance error threshold
2435 float distanceErrorThreshold = speed * 0.01f;
2436
2433 if (speed < 0.01f // allow rotation updates if avatar position is unchanged 2437 if (speed < 0.01f // allow rotation updates if avatar position is unchanged
2434 || Math.Abs(distanceError) > 0.25f // arbitrary distance error threshold 2438 || Math.Abs(distanceError) > distanceErrorThreshold
2435 || velocidyDiff > 0.01f) // did velocity change from last update? 2439 || velocidyDiff > 0.01f) // did velocity change from last update?
2436 { 2440 {
2437 m_perfMonMS = currentTick; 2441 m_perfMonMS = currentTick;