From 22dade6463ce55945c5059af0dc115318297dc1c Mon Sep 17 00:00:00 2001 From: Robert Adams Date: Thu, 20 Mar 2014 22:10:27 -0700 Subject: varregion: More tweeking to only sending patches within avatar draw distance. Still has problems with child avatars. --- OpenSim/Region/Framework/Scenes/ScenePresence.cs | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) (limited to 'OpenSim/Region/Framework') diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 37353c1..063ac73 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs @@ -873,7 +873,8 @@ namespace OpenSim.Region.Framework.Scenes m_sendCoarseLocationsMethod = SendCoarseLocationsDefault; Animator = new ScenePresenceAnimator(this); PresenceType = type; - DrawDistance = world.DefaultDrawDistance; + // DrawDistance = world.DefaultDrawDistance; + DrawDistance = Constants.RegionSize; RegionHandle = world.RegionInfo.RegionHandle; ControllingClient = client; Firstname = ControllingClient.FirstName; @@ -1918,8 +1919,8 @@ namespace OpenSim.Region.Framework.Scenes // When we get to the point of re-computing neighbors everytime this // changes, then start using the agent's drawdistance rather than the // region's draw distance. - // DrawDistance = agentData.Far; - DrawDistance = Scene.DefaultDrawDistance; + DrawDistance = agentData.Far; + // DrawDistance = Scene.DefaultDrawDistance; m_mouseLook = (flags & AgentManager.ControlFlags.AGENT_CONTROL_MOUSELOOK) != 0; m_leftButtonDown = (flags & AgentManager.ControlFlags.AGENT_CONTROL_LBUTTON_DOWN) != 0; @@ -2277,8 +2278,8 @@ namespace OpenSim.Region.Framework.Scenes // When we get to the point of re-computing neighbors everytime this // changes, then start using the agent's drawdistance rather than the // region's draw distance. - // DrawDistance = agentData.Far; - DrawDistance = Scene.DefaultDrawDistance; + DrawDistance = agentData.Far; + // DrawDistance = Scene.DefaultDrawDistance; // Check if Client has camera in 'follow cam' or 'build' mode. Vector3 camdif = (Vector3.One * Rotation - Vector3.One * CameraRotation); @@ -3824,8 +3825,8 @@ namespace OpenSim.Region.Framework.Scenes // When we get to the point of re-computing neighbors everytime this // changes, then start using the agent's drawdistance rather than the // region's draw distance. - // DrawDistance = cAgentData.Far; - DrawDistance = Scene.DefaultDrawDistance; + DrawDistance = cAgentData.Far; + // DrawDistance = Scene.DefaultDrawDistance; if (cAgentData.Position != marker) // UGH!! m_pos = cAgentData.Position + offset; @@ -3935,8 +3936,8 @@ namespace OpenSim.Region.Framework.Scenes // When we get to the point of re-computing neighbors everytime this // changes, then start using the agent's drawdistance rather than the // region's draw distance. - // DrawDistance = cAgent.Far; - DrawDistance = Scene.DefaultDrawDistance; + DrawDistance = cAgent.Far; + // DrawDistance = Scene.DefaultDrawDistance; if ((cAgent.Throttles != null) && cAgent.Throttles.Length > 0) ControllingClient.SetChildAgentThrottle(cAgent.Throttles); -- cgit v1.1