diff options
author | Justin Clark-Casey (justincc) | 2014-05-30 22:18:07 +0100 |
---|---|---|
committer | Justin Clark-Casey | 2014-06-10 20:21:48 +0100 |
commit | 26ec918ec88d37916d4a3997b6fd860189ab4cd7 (patch) | |
tree | bd7cde4e481f548864c7c4f4525efcf413578fcf /OpenSim/Region | |
parent | Fix issue with BulletSim avatar level flight jitter by commenting out RawVelo... (diff) | |
download | opensim-SC_OLD-26ec918ec88d37916d4a3997b6fd860189ab4cd7.zip opensim-SC_OLD-26ec918ec88d37916d4a3997b6fd860189ab4cd7.tar.gz opensim-SC_OLD-26ec918ec88d37916d4a3997b6fd860189ab4cd7.tar.bz2 opensim-SC_OLD-26ec918ec88d37916d4a3997b6fd860189ab4cd7.tar.xz |
minor: Add some commented out logging to ScenePresence.SendTerseUpdateToAllClients() which is extremely helpful when investigating presence update triggers.
Diffstat (limited to 'OpenSim/Region')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/ScenePresence.cs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 17f54c2..90c95da 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs | |||
@@ -3259,6 +3259,10 @@ namespace OpenSim.Region.Framework.Scenes | |||
3259 | float speed = Velocity.Length(); | 3259 | float speed = Velocity.Length(); |
3260 | float velocidyDiff = Vector3.Distance(lastVelocitySentToAllClients, Velocity); | 3260 | float velocidyDiff = Vector3.Distance(lastVelocitySentToAllClients, Velocity); |
3261 | 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); | ||
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 |
3264 | float distanceErrorThreshold = speed * 0.01f; | 3268 | float distanceErrorThreshold = speed * 0.01f; |
@@ -3267,6 +3271,10 @@ namespace OpenSim.Region.Framework.Scenes | |||
3267 | || Math.Abs(distanceError) > distanceErrorThreshold | 3271 | || Math.Abs(distanceError) > distanceErrorThreshold |
3268 | || velocidyDiff > 0.01f) // did velocity change from last update? | 3272 | || velocidyDiff > 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; |