aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework
diff options
context:
space:
mode:
authorDiva Canto2014-07-04 11:45:30 -0700
committerDiva Canto2014-07-04 11:45:30 -0700
commit60ad72357e1b810d1d5d34ac98367da46c81447d (patch)
treecd8f632a29aa68083cb10b321682bb63d4d63c28 /OpenSim/Region/Framework
parentIt turns out that child agent management has had a bug for a while: there was... (diff)
downloadopensim-SC_OLD-60ad72357e1b810d1d5d34ac98367da46c81447d.zip
opensim-SC_OLD-60ad72357e1b810d1d5d34ac98367da46c81447d.tar.gz
opensim-SC_OLD-60ad72357e1b810d1d5d34ac98367da46c81447d.tar.bz2
opensim-SC_OLD-60ad72357e1b810d1d5d34ac98367da46c81447d.tar.xz
This fixes the bug related to rebooting neighboring varregions while avatars are logged in; the avies would not see the region anymore until they relogged. Same problem as before: inconsistent calculation of scope.
Diffstat (limited to 'OpenSim/Region/Framework')
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.cs24
1 files changed, 14 insertions, 10 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs
index 3957ba6..27042a3 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.cs
@@ -1069,18 +1069,22 @@ namespace OpenSim.Region.Framework.Scenes
1069 /// <returns>True after all operations complete, throws exceptions otherwise.</returns> 1069 /// <returns>True after all operations complete, throws exceptions otherwise.</returns>
1070 public override void OtherRegionUp(GridRegion otherRegion) 1070 public override void OtherRegionUp(GridRegion otherRegion)
1071 { 1071 {
1072 uint xcell = Util.WorldToRegionLoc((uint)otherRegion.RegionLocX);
1073 uint ycell = Util.WorldToRegionLoc((uint)otherRegion.RegionLocY);
1074
1075 //m_log.InfoFormat("[SCENE]: (on region {0}): Region {1} up in coords {2}-{3}",
1076 // RegionInfo.RegionName, otherRegion.RegionName, xcell, ycell);
1077
1078 if (RegionInfo.RegionHandle != otherRegion.RegionHandle) 1072 if (RegionInfo.RegionHandle != otherRegion.RegionHandle)
1079 { 1073 {
1080 // If these are cast to INT because long + negative values + abs returns invalid data 1074 //// If these are cast to INT because long + negative values + abs returns invalid data
1081 int resultX = Math.Abs((int)xcell - (int)RegionInfo.RegionLocX); 1075 //int resultX = Math.Abs((int)xcell - (int)RegionInfo.RegionLocX);
1082 int resultY = Math.Abs((int)ycell - (int)RegionInfo.RegionLocY); 1076 //int resultY = Math.Abs((int)ycell - (int)RegionInfo.RegionLocY);
1083 if (resultX <= 1 && resultY <= 1) 1077 //if (resultX <= 1 && resultY <= 1)
1078 float dist = (float)Math.Max(DefaultDrawDistance,
1079 (float)Math.Max(RegionInfo.RegionSizeX, RegionInfo.RegionSizeY));
1080 uint newRegionX, newRegionY, thisRegionX, thisRegionY;
1081 Util.RegionHandleToRegionLoc(otherRegion.RegionHandle, out newRegionX, out newRegionY);
1082 Util.RegionHandleToRegionLoc(RegionInfo.RegionHandle, out thisRegionX, out thisRegionY);
1083
1084 //m_log.InfoFormat("[SCENE]: (on region {0}): Region {1} up in coords {2}-{3}",
1085 // RegionInfo.RegionName, otherRegion.RegionName, newRegionX, newRegionY);
1086
1087 if (!Util.IsOutsideView(dist, thisRegionX, newRegionX, thisRegionY, newRegionY))
1084 { 1088 {
1085 // Let the grid service module know, so this can be cached 1089 // Let the grid service module know, so this can be cached
1086 m_eventManager.TriggerOnRegionUp(otherRegion); 1090 m_eventManager.TriggerOnRegionUp(otherRegion);