diff options
author | UbitUmarov | 2019-01-14 18:39:16 +0000 |
---|---|---|
committer | UbitUmarov | 2019-01-14 18:39:16 +0000 |
commit | df14ed7d312e2f38e21912447835d9f078b97a95 (patch) | |
tree | c7cbab202987ea93b381a10c4c96edd167e0abd0 /OpenSim/Region/CoreModules/Framework/EntityTransfer | |
parent | fix te media (diff) | |
download | opensim-SC-df14ed7d312e2f38e21912447835d9f078b97a95.zip opensim-SC-df14ed7d312e2f38e21912447835d9f078b97a95.tar.gz opensim-SC-df14ed7d312e2f38e21912447835d9f078b97a95.tar.bz2 opensim-SC-df14ed7d312e2f38e21912447835d9f078b97a95.tar.xz |
more on TP
Diffstat (limited to 'OpenSim/Region/CoreModules/Framework/EntityTransfer')
-rw-r--r-- | OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs index 75e7916..d770d45 100644 --- a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs +++ b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs | |||
@@ -1099,7 +1099,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1099 | ulong destinationHandle = finalDestination.RegionHandle; | 1099 | ulong destinationHandle = finalDestination.RegionHandle; |
1100 | 1100 | ||
1101 | List<ulong> childRegionsToClose = null; | 1101 | List<ulong> childRegionsToClose = null; |
1102 | if (ctx.OutboundVersion < 0.7) | 1102 | if (ctx.OutboundVersion < 0.7f) |
1103 | { | 1103 | { |
1104 | childRegionsToClose = sp.GetChildAgentsToClose(destinationHandle, finalDestination.RegionSizeX, finalDestination.RegionSizeY); | 1104 | childRegionsToClose = sp.GetChildAgentsToClose(destinationHandle, finalDestination.RegionSizeX, finalDestination.RegionSizeY); |
1105 | 1105 | ||
@@ -1226,7 +1226,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1226 | // Now let's make it officially a child agent | 1226 | // Now let's make it officially a child agent |
1227 | sp.MakeChildAgent(destinationHandle); | 1227 | sp.MakeChildAgent(destinationHandle); |
1228 | 1228 | ||
1229 | if(ctx.OutboundVersion < 0.7) | 1229 | if(ctx.OutboundVersion < 0.7f) |
1230 | { | 1230 | { |
1231 | if (logout) | 1231 | if (logout) |
1232 | sp.closeAllChildAgents(); | 1232 | sp.closeAllChildAgents(); |
@@ -1249,8 +1249,8 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1249 | "[ENTITY TRANSFER MODULE]: Closing agent {0} in {1} after teleport", sp.Name, Scene.Name); | 1249 | "[ENTITY TRANSFER MODULE]: Closing agent {0} in {1} after teleport", sp.Name, Scene.Name); |
1250 | sp.Scene.CloseAgent(sp.UUID, false); | 1250 | sp.Scene.CloseAgent(sp.UUID, false); |
1251 | } | 1251 | } |
1252 | sp.IsInTransit = false; | ||
1252 | } | 1253 | } |
1253 | sp.IsInTransit = false; | ||
1254 | } | 1254 | } |
1255 | 1255 | ||
1256 | /// <summary> | 1256 | /// <summary> |
@@ -2077,7 +2077,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
2077 | List<AgentCircuitData> cagents = new List<AgentCircuitData>(); | 2077 | List<AgentCircuitData> cagents = new List<AgentCircuitData>(); |
2078 | List<ulong> newneighbours = new List<ulong>(); | 2078 | List<ulong> newneighbours = new List<ulong>(); |
2079 | 2079 | ||
2080 | bool notHG = (sp.TeleportFlags & Constants.TeleportFlags.ViaHGLogin) != 0; | 2080 | bool notHG = (sp.TeleportFlags & Constants.TeleportFlags.ViaHGLogin) == 0; |
2081 | 2081 | ||
2082 | foreach (GridRegion neighbour in neighbours) | 2082 | foreach (GridRegion neighbour in neighbours) |
2083 | { | 2083 | { |
@@ -2120,12 +2120,18 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
2120 | cagents.Add(agent); | 2120 | cagents.Add(agent); |
2121 | } | 2121 | } |
2122 | 2122 | ||
2123 | if (previousRegionNeighbourHandles.Contains(currentRegionHandler)) | ||
2124 | previousRegionNeighbourHandles.Remove(currentRegionHandler); | ||
2125 | |||
2126 | // previousRegionNeighbourHandles now contains regions to forget | 2123 | // previousRegionNeighbourHandles now contains regions to forget |
2127 | foreach (ulong handler in previousRegionNeighbourHandles) | 2124 | if (previousRegionNeighbourHandles.Count > 0) |
2128 | seeds.Remove(handler); | 2125 | { |
2126 | if (previousRegionNeighbourHandles.Contains(currentRegionHandler)) | ||
2127 | previousRegionNeighbourHandles.Remove(currentRegionHandler); | ||
2128 | |||
2129 | foreach (ulong handler in previousRegionNeighbourHandles) | ||
2130 | seeds.Remove(handler); | ||
2131 | |||
2132 | List<ulong> toclose = new List<ulong>(previousRegionNeighbourHandles); | ||
2133 | sp.CloseChildAgents(toclose); | ||
2134 | } | ||
2129 | 2135 | ||
2130 | /// Update all child agent with everyone's seeds | 2136 | /// Update all child agent with everyone's seeds |
2131 | // foreach (AgentCircuitData a in cagents) | 2137 | // foreach (AgentCircuitData a in cagents) |
@@ -2137,7 +2143,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
2137 | sp.KnownRegions = seeds; | 2143 | sp.KnownRegions = seeds; |
2138 | sp.SetNeighbourRegionSizeInfo(neighbours); | 2144 | sp.SetNeighbourRegionSizeInfo(neighbours); |
2139 | 2145 | ||
2140 | if(neighbours.Count > 0) | 2146 | if (neighbours.Count > 0) |
2141 | { | 2147 | { |
2142 | AgentPosition agentpos = new AgentPosition(); | 2148 | AgentPosition agentpos = new AgentPosition(); |
2143 | agentpos.AgentID = new UUID(sp.UUID.Guid); | 2149 | agentpos.AgentID = new UUID(sp.UUID.Guid); |
@@ -2158,12 +2164,6 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
2158 | Thread.Sleep(200); // the original delay that was at InformClientOfNeighbourAsync start | 2164 | Thread.Sleep(200); // the original delay that was at InformClientOfNeighbourAsync start |
2159 | int count = 0; | 2165 | int count = 0; |
2160 | IPEndPoint ipe; | 2166 | IPEndPoint ipe; |
2161 | |||
2162 | if(previousRegionNeighbourHandles.Count > 0) | ||
2163 | { | ||
2164 | List<ulong> toclose = new List<ulong>(previousRegionNeighbourHandles); | ||
2165 | sp.CloseChildAgents(toclose); | ||
2166 | } | ||
2167 | 2167 | ||
2168 | foreach (GridRegion neighbour in neighbours) | 2168 | foreach (GridRegion neighbour in neighbours) |
2169 | { | 2169 | { |