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.cs12
1 files changed, 10 insertions, 2 deletions
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
index 17f54c2..37353c1 100644
--- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs
+++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
@@ -3257,7 +3257,11 @@ namespace OpenSim.Region.Framework.Scenes
3257 float distanceError = Vector3.Distance(OffsetPosition, expectedPosition); 3257 float distanceError = Vector3.Distance(OffsetPosition, expectedPosition);
3258 3258
3259 float speed = Velocity.Length(); 3259 float speed = Velocity.Length();
3260 float velocidyDiff = Vector3.Distance(lastVelocitySentToAllClients, Velocity); 3260 float velocityDiff = Vector3.Distance(lastVelocitySentToAllClients, Velocity);
3261
3262// m_log.DebugFormat(
3263// "[SCENE PRESENCE]: Delta-v {0}, lastVelocity {1}, Velocity {2} for {3} in {4}",
3264// velocidyDiff, lastVelocitySentToAllClients, Velocity, Name, Scene.Name);
3261 3265
3262 // assuming 5 ms. worst case precision for timer, use 2x that 3266 // assuming 5 ms. worst case precision for timer, use 2x that
3263 // for distance error threshold 3267 // for distance error threshold
@@ -3265,8 +3269,12 @@ namespace OpenSim.Region.Framework.Scenes
3265 3269
3266 if (speed < 0.01f // allow rotation updates if avatar position is unchanged 3270 if (speed < 0.01f // allow rotation updates if avatar position is unchanged
3267 || Math.Abs(distanceError) > distanceErrorThreshold 3271 || Math.Abs(distanceError) > distanceErrorThreshold
3268 || velocidyDiff > 0.01f) // did velocity change from last update? 3272 || velocityDiff > 0.01f) // did velocity change from last update?
3269 { 3273 {
3274// m_log.DebugFormat(
3275// "[SCENE PRESENCE]: Update triggered with speed {0}, distanceError {1}, distanceThreshold {2}, delta-v {3} for {4} in {5}",
3276// speed, distanceError, distanceErrorThreshold, velocidyDiff, Name, Scene.Name);
3277
3270 lastVelocitySentToAllClients = Velocity; 3278 lastVelocitySentToAllClients = Velocity;
3271 lastTerseUpdateToAllClientsTick = currentTick; 3279 lastTerseUpdateToAllClientsTick = currentTick;
3272 lastPositionSentToAllClients = OffsetPosition; 3280 lastPositionSentToAllClients = OffsetPosition;