aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim.RegionServer/OpenSimMain.cs
diff options
context:
space:
mode:
authorMW2007-05-14 21:04:14 +0000
committerMW2007-05-14 21:04:14 +0000
commita889caf20028c8f9680afb27335ec6cac8f1e9f1 (patch)
treefde4ee9bfd9af2dc6c204c81ba0ac907cebbec31 /OpenSim.RegionServer/OpenSimMain.cs
parentset the default region x,y and sim port to 0 in UserProfileManager. XmlRpcLog... (diff)
downloadopensim-SC_OLD-a889caf20028c8f9680afb27335ec6cac8f1e9f1.zip
opensim-SC_OLD-a889caf20028c8f9680afb27335ec6cac8f1e9f1.tar.gz
opensim-SC_OLD-a889caf20028c8f9680afb27335ec6cac8f1e9f1.tar.bz2
opensim-SC_OLD-a889caf20028c8f9680afb27335ec6cac8f1e9f1.tar.xz
moved the EnableNeighbours code to after the client has completed the move to the region
Diffstat (limited to 'OpenSim.RegionServer/OpenSimMain.cs')
-rw-r--r--OpenSim.RegionServer/OpenSimMain.cs37
1 files changed, 1 insertions, 36 deletions
diff --git a/OpenSim.RegionServer/OpenSimMain.cs b/OpenSim.RegionServer/OpenSimMain.cs
index 9fb7c4e..52abf63 100644
--- a/OpenSim.RegionServer/OpenSimMain.cs
+++ b/OpenSim.RegionServer/OpenSimMain.cs
@@ -543,42 +543,7 @@ namespace OpenSim
543 this._packetServer.ClientThreads.Add(useCircuit.CircuitCode.Code, newuser); 543 this._packetServer.ClientThreads.Add(useCircuit.CircuitCode.Code, newuser);
544 544
545 //if (!((RemoteGridBase)GridServers.GridServer).agentcircuits[useCircuit.CircuitCode.Code].child) 545 //if (!((RemoteGridBase)GridServers.GridServer).agentcircuits[useCircuit.CircuitCode.Code].child)
546 if ((this.GridServers.GridServer.GetName() == "Remote") && (!isChildAgent)) 546
547 {
548 Hashtable SimParams;
549 ArrayList SendParams;
550 XmlRpcRequest GridReq;
551 XmlRpcResponse GridResp;
552 foreach (Hashtable neighbour in ((RemoteGridBase)this.GridServers.GridServer).neighbours)
553 {
554 m_console.WriteLine(OpenSim.Framework.Console.LogPriority.VERBOSE,"http://" + neighbour["sim_ip"] + ":" + neighbour["sim_port"]);
555 SimParams = new Hashtable();
556 SimParams["session_id"] = ((RemoteGridBase)this.GridServers.GridServer).agentcircuits[useCircuit.CircuitCode.Code].SessionID.ToString();
557 SimParams["secure_session_id"] = ((RemoteGridBase)this.GridServers.GridServer).agentcircuits[useCircuit.CircuitCode.Code].SecureSessionID.ToString();
558 SimParams["firstname"] = ((RemoteGridBase)this.GridServers.GridServer).agentcircuits[useCircuit.CircuitCode.Code].firstname;
559 SimParams["lastname"] = ((RemoteGridBase)this.GridServers.GridServer).agentcircuits[useCircuit.CircuitCode.Code].lastname;
560 SimParams["agent_id"] = ((RemoteGridBase)this.GridServers.GridServer).agentcircuits[useCircuit.CircuitCode.Code].AgentID.ToString();
561 SimParams["circuit_code"] = (Int32)useCircuit.CircuitCode.Code;
562 SimParams["child_agent"] = "1";
563 SendParams = new ArrayList();
564 SendParams.Add(SimParams);
565
566 GridReq = new XmlRpcRequest("expect_user", SendParams);
567 GridResp = GridReq.Send("http://" + neighbour["sim_ip"] + ":" + neighbour["sim_port"], 3000);
568 EnableSimulatorPacket enablesimpacket = new EnableSimulatorPacket();
569 enablesimpacket.SimulatorInfo = new EnableSimulatorPacket.SimulatorInfoBlock();
570 enablesimpacket.SimulatorInfo.Handle = Helpers.UIntsToLong((uint)(Convert.ToInt32(neighbour["region_locx"]) * 256), (uint)(Convert.ToInt32(neighbour["region_locy"]) * 256));
571 System.Net.IPAddress neighbourIP = System.Net.IPAddress.Parse((string)neighbour["sim_ip"]);
572 byte[] byteIP = neighbourIP.GetAddressBytes();
573 enablesimpacket.SimulatorInfo.IP = (uint)byteIP[3] << 24;
574 enablesimpacket.SimulatorInfo.IP += (uint)byteIP[2] << 16;
575 enablesimpacket.SimulatorInfo.IP += (uint)byteIP[1] << 8;
576 enablesimpacket.SimulatorInfo.IP += (uint)byteIP[0];
577 enablesimpacket.SimulatorInfo.Port = (ushort)Convert.ToInt32(neighbour["sim_port"]);
578 Thread.Sleep(3000);
579 _packetServer.ClientThreads[useCircuit.CircuitCode.Code].OutPacket(enablesimpacket);
580 }
581 }
582 547
583 } 548 }
584 else 549 else