aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Common/OpenGrid.Framework.Communications/TestLocalCommsManager.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Common/OpenGrid.Framework.Communications/TestLocalCommsManager.cs')
-rw-r--r--Common/OpenGrid.Framework.Communications/TestLocalCommsManager.cs17
1 files changed, 9 insertions, 8 deletions
diff --git a/Common/OpenGrid.Framework.Communications/TestLocalCommsManager.cs b/Common/OpenGrid.Framework.Communications/TestLocalCommsManager.cs
index 57049fc..b4fe696 100644
--- a/Common/OpenGrid.Framework.Communications/TestLocalCommsManager.cs
+++ b/Common/OpenGrid.Framework.Communications/TestLocalCommsManager.cs
@@ -11,8 +11,8 @@ namespace OpenGrid.Framework.Communications
11{ 11{
12 public class TestLocalCommsManager : RegionServerCommsManager 12 public class TestLocalCommsManager : RegionServerCommsManager
13 { 13 {
14 protected Dictionary<uint , RegionInfo> regions = new Dictionary<uint,RegionInfo>(); 14 protected Dictionary<ulong, RegionInfo> regions = new Dictionary<ulong,RegionInfo>();
15 protected Dictionary<uint, RegionCommsHostBase> regionHosts = new Dictionary<uint, RegionCommsHostBase>(); 15 protected Dictionary<ulong, RegionCommsHostBase> regionHosts = new Dictionary<ulong, RegionCommsHostBase>();
16 16
17 public TestLocalCommsManager() 17 public TestLocalCommsManager()
18 { 18 {
@@ -28,9 +28,9 @@ namespace OpenGrid.Framework.Communications
28 { 28 {
29 if (!this.regions.ContainsKey((uint)regionInfo.RegionHandle)) 29 if (!this.regions.ContainsKey((uint)regionInfo.RegionHandle))
30 { 30 {
31 this.regions.Add((uint)regionInfo.RegionHandle, regionInfo); 31 this.regions.Add(regionInfo.RegionHandle, regionInfo);
32 RegionCommsHostBase regionHost = new RegionCommsHostBase(); 32 RegionCommsHostBase regionHost = new RegionCommsHostBase();
33 this.regionHosts.Add((uint)regionInfo.RegionHandle, regionHost); 33 this.regionHosts.Add(regionInfo.RegionHandle, regionHost);
34 34
35 return regionHost; 35 return regionHost;
36 } 36 }
@@ -59,13 +59,14 @@ namespace OpenGrid.Framework.Communications
59 } 59 }
60 60
61 /// <summary> 61 /// <summary>
62 /// 62 /// Is a Sandbox mode method, used by the local Login server to inform a region of a connection user/session
63 /// </summary> 63 /// </summary>
64 /// <param name="regionHandle"></param> 64 /// <param name="regionHandle"></param>
65 /// <param name="loginData"></param> 65 /// <param name="loginData"></param>
66 /// <returns></returns> 66 /// <returns></returns>
67 public bool AddNewSession(uint regionHandle, Login loginData) 67 public bool AddNewSession(ulong regionHandle, Login loginData)
68 { 68 {
69 Console.WriteLine(" comms manager been told to expect new user");
69 AgentCircuitData agent = new AgentCircuitData(); 70 AgentCircuitData agent = new AgentCircuitData();
70 agent.AgentID = loginData.Agent; 71 agent.AgentID = loginData.Agent;
71 agent.firstname = loginData.First; 72 agent.firstname = loginData.First;
@@ -77,9 +78,9 @@ namespace OpenGrid.Framework.Communications
77 agent.InventoryFolder = loginData.InventoryFolder; 78 agent.InventoryFolder = loginData.InventoryFolder;
78 agent.startpos = new LLVector3(128, 128, 70); 79 agent.startpos = new LLVector3(128, 128, 70);
79 80
80 if (this.regionHosts.ContainsKey((uint)regionHandle)) 81 if (this.regionHosts.ContainsKey(regionHandle))
81 { 82 {
82 this.regionHosts[(uint)regionHandle].TriggerExpectUser(agent); 83 this.regionHosts[regionHandle].TriggerExpectUser(regionHandle, agent);
83 return true; 84 return true;
84 } 85 }
85 86