From 0af8886400e56cfbc2efc0d6a8ab01eb289b4e52 Mon Sep 17 00:00:00 2001
From: Justin Clark-Casey (justincc)
Date: Wed, 2 Apr 2014 00:58:33 +0100
Subject: Fix problem where moving an object to another region on the same
simulator was failing, with the object returning to its original position.
Root cause was that PrimLimitsModule was not properly handling the case where the parcel it was asked to check was outside the current region's bounds.
If this is the case, we can abort the check since the receiving region will perform it.
Added a regression test for this case.
---
OpenSim/Region/Framework/Scenes/SceneGraph.cs | 19 +++++++++++++++----
1 file changed, 15 insertions(+), 4 deletions(-)
(limited to 'OpenSim/Region/Framework/Scenes/SceneGraph.cs')
diff --git a/OpenSim/Region/Framework/Scenes/SceneGraph.cs b/OpenSim/Region/Framework/Scenes/SceneGraph.cs
index 1aecce5..558f108 100644
--- a/OpenSim/Region/Framework/Scenes/SceneGraph.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneGraph.cs
@@ -1326,12 +1326,23 @@ namespace OpenSim.Region.Framework.Scenes
///
/// Update the position of the given group.
///
- ///
+ ///
///
///
- public void UpdatePrimGroupPosition(uint localID, Vector3 pos, IClientAPI remoteClient)
+ public void UpdatePrimGroupPosition(uint localId, Vector3 pos, IClientAPI remoteClient)
{
- SceneObjectGroup group = GetGroupByPrim(localID);
+ UpdatePrimGroupPosition(localId, pos, remoteClient.AgentId);
+ }
+
+ ///
+ /// Update the position of the given group.
+ ///
+ ///
+ ///
+ ///
+ public void UpdatePrimGroupPosition(uint localId, Vector3 pos, UUID updatingAgentId)
+ {
+ SceneObjectGroup group = GetGroupByPrim(localId);
if (group != null)
{
@@ -1342,7 +1353,7 @@ namespace OpenSim.Region.Framework.Scenes
}
else
{
- if (m_parentScene.Permissions.CanMoveObject(group.UUID, remoteClient.AgentId)
+ if (m_parentScene.Permissions.CanMoveObject(group.UUID, updatingAgentId)
&& m_parentScene.Permissions.CanObjectEntry(group.UUID, false, pos))
{
group.UpdateGroupPosition(pos);
--
cgit v1.1