diff options
author | Teravus Ovares | 2008-01-21 23:04:42 +0000 |
---|---|---|
committer | Teravus Ovares | 2008-01-21 23:04:42 +0000 |
commit | 3fe6b2280d0b335ef8d9f2b0dc3406a47e6c0b53 (patch) | |
tree | bb8cbf0b5918448c92f6b0f42fec5013450d7e25 /OpenSim/Region/Communications/OGS1/OGS1InterSimComms.cs | |
parent | Another attempt to squash the animation bug. Wish I could get this to fail at... (diff) | |
download | opensim-SC_OLD-3fe6b2280d0b335ef8d9f2b0dc3406a47e6c0b53.zip opensim-SC_OLD-3fe6b2280d0b335ef8d9f2b0dc3406a47e6c0b53.tar.gz opensim-SC_OLD-3fe6b2280d0b335ef8d9f2b0dc3406a47e6c0b53.tar.bz2 opensim-SC_OLD-3fe6b2280d0b335ef8d9f2b0dc3406a47e6c0b53.tar.xz |
* Shutting down child agents properly in neighbor regions.
Diffstat (limited to 'OpenSim/Region/Communications/OGS1/OGS1InterSimComms.cs')
-rw-r--r-- | OpenSim/Region/Communications/OGS1/OGS1InterSimComms.cs | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/OpenSim/Region/Communications/OGS1/OGS1InterSimComms.cs b/OpenSim/Region/Communications/OGS1/OGS1InterSimComms.cs index a0da07e..b39e0b7 100644 --- a/OpenSim/Region/Communications/OGS1/OGS1InterSimComms.cs +++ b/OpenSim/Region/Communications/OGS1/OGS1InterSimComms.cs | |||
@@ -45,6 +45,8 @@ namespace OpenSim.Region.Communications.OGS1 | |||
45 | 45 | ||
46 | public delegate bool ChildAgentUpdate(ulong regionHandle, ChildAgentDataUpdate childUpdate); | 46 | public delegate bool ChildAgentUpdate(ulong regionHandle, ChildAgentDataUpdate childUpdate); |
47 | 47 | ||
48 | public delegate bool TellRegionToCloseChildConnection(ulong regionHandle, LLUUID agentID); | ||
49 | |||
48 | public sealed class InterRegionSingleton | 50 | public sealed class InterRegionSingleton |
49 | { | 51 | { |
50 | private static readonly InterRegionSingleton instance = new InterRegionSingleton(); | 52 | private static readonly InterRegionSingleton instance = new InterRegionSingleton(); |
@@ -55,6 +57,8 @@ namespace OpenSim.Region.Communications.OGS1 | |||
55 | public event PrimGroupArrival OnPrimGroupArrival; | 57 | public event PrimGroupArrival OnPrimGroupArrival; |
56 | public event RegionUp OnRegionUp; | 58 | public event RegionUp OnRegionUp; |
57 | public event ChildAgentUpdate OnChildAgentUpdate; | 59 | public event ChildAgentUpdate OnChildAgentUpdate; |
60 | public event TellRegionToCloseChildConnection OnTellRegionToCloseChildConnection; | ||
61 | |||
58 | 62 | ||
59 | 63 | ||
60 | static InterRegionSingleton() | 64 | static InterRegionSingleton() |
@@ -123,6 +127,16 @@ namespace OpenSim.Region.Communications.OGS1 | |||
123 | } | 127 | } |
124 | return false; | 128 | return false; |
125 | } | 129 | } |
130 | |||
131 | public bool TellRegionToCloseChildConnection(ulong regionHandle, LLUUID agentID) | ||
132 | { | ||
133 | if (OnTellRegionToCloseChildConnection != null) | ||
134 | { | ||
135 | |||
136 | return OnTellRegionToCloseChildConnection(regionHandle, agentID); | ||
137 | } | ||
138 | return false; | ||
139 | } | ||
126 | } | 140 | } |
127 | 141 | ||
128 | public class OGS1InterRegionRemoting : MarshalByRefObject | 142 | public class OGS1InterRegionRemoting : MarshalByRefObject |
@@ -171,6 +185,7 @@ namespace OpenSim.Region.Communications.OGS1 | |||
171 | } | 185 | } |
172 | } | 186 | } |
173 | 187 | ||
188 | |||
174 | public bool ExpectAvatarCrossing(ulong regionHandle, Guid agentID, sLLVector3 position, bool isFlying) | 189 | public bool ExpectAvatarCrossing(ulong regionHandle, Guid agentID, sLLVector3 position, bool isFlying) |
175 | { | 190 | { |
176 | try | 191 | try |
@@ -215,5 +230,18 @@ namespace OpenSim.Region.Communications.OGS1 | |||
215 | return false; | 230 | return false; |
216 | } | 231 | } |
217 | } | 232 | } |
233 | public bool TellRegionToCloseChildConnection(ulong regionHandle, Guid agentID) | ||
234 | { | ||
235 | try | ||
236 | { | ||
237 | return InterRegionSingleton.Instance.TellRegionToCloseChildConnection(regionHandle, new LLUUID(agentID)); | ||
238 | |||
239 | } | ||
240 | catch (RemotingException) | ||
241 | { | ||
242 | OpenSim.Framework.Console.MainLog.Instance.Verbose("INTERREGION", "Remoting Error: Unable to connect to remote region: " + regionHandle.ToString()); | ||
243 | return false; | ||
244 | } | ||
245 | } | ||
218 | } | 246 | } |
219 | } \ No newline at end of file | 247 | } \ No newline at end of file |