From 55400ff7be55b1c8dbededca68e6fce42cd6ce0f Mon Sep 17 00:00:00 2001 From: teravus Date: Fri, 23 Aug 2013 00:28:36 -0500 Subject: [PATCH] * This increases accuracy when border crossing (the reason is.. the border crossing code will use velocity to predict where the object should be, so setting it to zero. It still looses about 0.0045 per loop. --- OpenSim/Region/Framework/Scenes/KeyframeMotion.cs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/OpenSim/Region/Framework/Scenes/KeyframeMotion.cs b/OpenSim/Region/Framework/Scenes/KeyframeMotion.cs index d773ee7f28..f96b56a54b 100644 --- a/OpenSim/Region/Framework/Scenes/KeyframeMotion.cs +++ b/OpenSim/Region/Framework/Scenes/KeyframeMotion.cs @@ -644,8 +644,8 @@ namespace OpenSim.Region.Framework.Scenes // m_group.AbsolutePosition += motionThisFrame; m_nextPosition = m_group.AbsolutePosition + motionThisFrame; m_group.AbsolutePosition = m_nextPosition; - - //m_group.RootPart.Velocity = v; + if ((m_group.AbsolutePosition.X < 10 || m_group.AbsolutePosition.Y < 10 || m_group.AbsolutePosition.X > Constants.RegionSize - 10 || m_group.AbsolutePosition.Y > Constants.RegionSize - 10)) + m_group.RootPart.Velocity = v; update = true; } @@ -736,12 +736,12 @@ namespace OpenSim.Region.Framework.Scenes m_waitingCrossing = true; // to remove / retune to smoth crossings - if (m_group.RootPart.Velocity != Vector3.Zero) - { - m_group.RootPart.Velocity = Vector3.Zero; - m_group.SendGroupRootTerseUpdate(); + //if (m_group.RootPart.Velocity != Vector3.Zero) + //{ + // m_group.RootPart.Velocity = Vector3.Zero; + // m_group.SendGroupRootTerseUpdate(); // m_group.RootPart.ScheduleTerseUpdate(); - } + //} } public void CrossingFailure()