aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs24
1 files changed, 24 insertions, 0 deletions
diff --git a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs
index b9d5d32..098e5cb 100644
--- a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs
+++ b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs
@@ -1705,6 +1705,30 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
1705 uint x = 0, y = 0; 1705 uint x = 0, y = 0;
1706 Utils.LongToUInts(newRegionHandle, out x, out y); 1706 Utils.LongToUInts(newRegionHandle, out x, out y);
1707 GridRegion destination = scene.GridService.GetRegionByPosition(scene.RegionInfo.ScopeID, (int)x, (int)y); 1707 GridRegion destination = scene.GridService.GetRegionByPosition(scene.RegionInfo.ScopeID, (int)x, (int)y);
1708
1709 if (destination == null || !CrossPrimGroupIntoNewRegion(destination, grp, silent))
1710 {
1711 m_log.InfoFormat("[ENTITY TRANSFER MODULE] cross region transfer failed for object {0}",grp.UUID);
1712
1713 // We are going to move the object back to the old position so long as the old position
1714 // is in the region
1715 oldGroupPosition.X = Util.Clamp<float>(oldGroupPosition.X,1.0f,(float)Constants.RegionSize-1);
1716 oldGroupPosition.Y = Util.Clamp<float>(oldGroupPosition.Y,1.0f,(float)Constants.RegionSize-1);
1717 oldGroupPosition.Z = Util.Clamp<float>(oldGroupPosition.Z,1.0f,4096.0f);
1718
1719 grp.RootPart.GroupPosition = oldGroupPosition;
1720
1721 // Need to turn off the physics flags, otherwise the object will continue to attempt to
1722 // move out of the region creating an infinite loop of failed attempts to cross
1723 grp.UpdatePrimFlags(grp.RootPart.LocalId,false,grp.IsTemporary,grp.IsPhantom,false);
1724
1725 grp.ScheduleGroupForFullUpdate();
1726 }
1727
1728
1729
1730
1731
1708 if (destination != null && !CrossPrimGroupIntoNewRegion(destination, grp, silent)) 1732 if (destination != null && !CrossPrimGroupIntoNewRegion(destination, grp, silent))
1709 { 1733 {
1710 grp.RootPart.GroupPosition = oldGroupPosition; 1734 grp.RootPart.GroupPosition = oldGroupPosition;