From e6d0dcd4e80275b96322eb10b31a2b339e4a2d17 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Thu, 3 Apr 2014 00:19:53 +0100 Subject: Fix bug where crossing to a neighbouring region and back again would trigger an exception, and a second recross would stop the user moving until relog Also fixes an issue where sitting avatar counts became inaccurate after any cross. Part of the problem was due to cloning code using MemberwiseClone() but not resetting certain collection structures. Adds regression test for this case. In relation to http://opensimulator.org/mantis/view.php?id=7050 --- OpenSim/Region/Framework/Scenes/ScenePresence.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'OpenSim/Region/Framework/Scenes/ScenePresence.cs') diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 080cdb4..6386a45 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs @@ -1023,6 +1023,7 @@ namespace OpenSim.Region.Framework.Scenes else { part.ParentGroup.AddAvatar(UUID); + part.AddSittingAvatar(UUID); if (part.SitTargetPosition != Vector3.Zero) part.SitTargetAvatar = UUID; // ParentPosition = part.GetWorldPosition(); @@ -2848,7 +2849,6 @@ namespace OpenSim.Region.Framework.Scenes part.ParentGroup.TriggerScriptChangedEvent(Changed.LINK); } - public void HandleAgentSit(IClientAPI remoteClient, UUID agentID) { if (IsChildAgent) -- cgit v1.1