aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs
diff options
context:
space:
mode:
authorTeravus Ovares2007-11-21 02:17:24 +0000
committerTeravus Ovares2007-11-21 02:17:24 +0000
commit7cb38712d5ad6781e672e4f1c8500ecd88d85f3e (patch)
tree5203c9901fdbba5ec8d9a21880d7895f593af540 /OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs
parentfix for mantis #2 from Justin Casey (IBM) (diff)
downloadopensim-SC_OLD-7cb38712d5ad6781e672e4f1c8500ecd88d85f3e.zip
opensim-SC_OLD-7cb38712d5ad6781e672e4f1c8500ecd88d85f3e.tar.gz
opensim-SC_OLD-7cb38712d5ad6781e672e4f1c8500ecd88d85f3e.tar.bz2
opensim-SC_OLD-7cb38712d5ad6781e672e4f1c8500ecd88d85f3e.tar.xz
* Did some initial work for prim crossing. Just glue so far.
* Added the child_get_tasks OpenSim.ini flag for testing the UDP packet sending code and packet throttler. This flag gets purposely disabled in grid mode. This flag also has the consequence that you can see the prim in neighboring regions without going into them. Be warned, this causes tons of dropped packets.
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs')
-rw-r--r--OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs18
1 files changed, 18 insertions, 0 deletions
diff --git a/OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs b/OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs
index 4d4f78f..ad7ff58 100644
--- a/OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs
+++ b/OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs
@@ -20,6 +20,8 @@ namespace OpenSim.Region.Environment.Scenes
20 public event AgentCrossing OnAvatarCrossingIntoRegion; 20 public event AgentCrossing OnAvatarCrossingIntoRegion;
21 public event ExpectUserDelegate OnExpectUser; 21 public event ExpectUserDelegate OnExpectUser;
22 public event CloseAgentConnection OnCloseAgentConnection; 22 public event CloseAgentConnection OnCloseAgentConnection;
23 public event PrimCrossing OnPrimCrossingIntoRegion;
24
23 25
24 public SceneCommunicationService(CommunicationsManager commsMan) 26 public SceneCommunicationService(CommunicationsManager commsMan)
25 { 27 {
@@ -34,7 +36,10 @@ namespace OpenSim.Region.Environment.Scenes
34 { 36 {
35 regionCommsHost.OnExpectUser += NewUserConnection; 37 regionCommsHost.OnExpectUser += NewUserConnection;
36 regionCommsHost.OnAvatarCrossingIntoRegion += AgentCrossing; 38 regionCommsHost.OnAvatarCrossingIntoRegion += AgentCrossing;
39 regionCommsHost.OnPrimCrossingIntoRegion += PrimCrossing;
37 regionCommsHost.OnCloseAgentConnection += CloseConnection; 40 regionCommsHost.OnCloseAgentConnection += CloseConnection;
41
42
38 } 43 }
39 } 44 }
40 45
@@ -42,6 +47,7 @@ namespace OpenSim.Region.Environment.Scenes
42 { 47 {
43 regionCommsHost.OnExpectUser -= NewUserConnection; 48 regionCommsHost.OnExpectUser -= NewUserConnection;
44 regionCommsHost.OnAvatarCrossingIntoRegion -= AgentCrossing; 49 regionCommsHost.OnAvatarCrossingIntoRegion -= AgentCrossing;
50 regionCommsHost.OnPrimCrossingIntoRegion -= PrimCrossing;
45 regionCommsHost.OnCloseAgentConnection -= CloseConnection; 51 regionCommsHost.OnCloseAgentConnection -= CloseConnection;
46 m_commsProvider.GridService.DeregisterRegion(m_regionInfo); 52 m_commsProvider.GridService.DeregisterRegion(m_regionInfo);
47 regionCommsHost = null; 53 regionCommsHost = null;
@@ -68,6 +74,13 @@ namespace OpenSim.Region.Environment.Scenes
68 OnAvatarCrossingIntoRegion(regionHandle, agentID, position, isFlying); 74 OnAvatarCrossingIntoRegion(regionHandle, agentID, position, isFlying);
69 } 75 }
70 } 76 }
77 protected void PrimCrossing(ulong regionHandle, LLUUID primID, LLVector3 position, bool isPhysical)
78 {
79 if (OnPrimCrossingIntoRegion != null)
80 {
81 OnPrimCrossingIntoRegion(regionHandle, primID, position, isPhysical);
82 }
83 }
71 84
72 protected void CloseConnection(ulong regionHandle, LLUUID agentID) 85 protected void CloseConnection(ulong regionHandle, LLUUID agentID)
73 { 86 {
@@ -222,6 +235,11 @@ namespace OpenSim.Region.Environment.Scenes
222 return m_commsProvider.InterRegion.ExpectAvatarCrossing(regionhandle, agentID, position, isFlying); 235 return m_commsProvider.InterRegion.ExpectAvatarCrossing(regionhandle, agentID, position, isFlying);
223 } 236 }
224 237
238 public bool PrimCrossToNeighboringRegion(ulong regionhandle, LLUUID primID, LLVector3 position, bool isPhysical)
239 {
240 return m_commsProvider.InterRegion.ExpectPrimCrossing(regionhandle, primID, position, isPhysical);
241 }
242
225 public void CloseChildAgentConnections(ScenePresence presence) 243 public void CloseChildAgentConnections(ScenePresence presence)
226 { 244 {
227 foreach (ulong regionHandle in presence.KnownChildRegions) 245 foreach (ulong regionHandle in presence.KnownChildRegions)