Started to fix sandbox mode
parent
7f0ecec464
commit
990680027f
|
@ -165,10 +165,14 @@ namespace OpenSim
|
|||
IGridServer gridServer = GridServers.GridServer;
|
||||
gridServer.SetServerInfo(regionData.GridURL, regionData.GridSendKey, regionData.GridRecvKey);
|
||||
|
||||
if(!m_sandbox) {
|
||||
if(GridServers.GridServer.RequestConnection(regionData.SimUUID,regionData.IPListenAddr,(uint)regionData.IPListenPort)) {
|
||||
if (!m_sandbox)
|
||||
{
|
||||
if (GridServers.GridServer.RequestConnection(regionData.SimUUID, regionData.IPListenAddr, (uint)regionData.IPListenPort))
|
||||
{
|
||||
m_console.WriteLine("Main.cs:Startup() - Got a grid connection OK!");
|
||||
} else {
|
||||
}
|
||||
else
|
||||
{
|
||||
m_console.WriteLine("AAAAAAAAAAAAARRRRRRRRRRGGGGGGGGGGGGHHHHHHHHHHHHHHHHHHHHH!!!!!!!!!!!!!!!!!!!!");
|
||||
m_console.WriteLine("I LOST MY GRID!!!!!!!!!!!!! AAAAAAAARRRRRRRRGGGGGGGGHHHHHHHHHHHHHHHHHH!!!!!!!!!!!!!");
|
||||
Shutdown();
|
||||
|
@ -203,7 +207,8 @@ namespace OpenSim
|
|||
agent_data.lastname = (string)requestData["lastname"];
|
||||
agent_data.AgentID = new LLUUID((string)requestData["agent_id"]);
|
||||
agent_data.circuitcode = Convert.ToUInt32(requestData["circuit_code"]);
|
||||
if(requestData.ContainsKey("child_agent") && requestData["child_agent"].Equals("1")) {
|
||||
if (requestData.ContainsKey("child_agent") && requestData["child_agent"].Equals("1"))
|
||||
{
|
||||
agent_data.child = true;
|
||||
}
|
||||
((RemoteGridBase)gridServer).agentcircuits.Add((uint)agent_data.circuitcode, agent_data);
|
||||
|
@ -305,7 +310,12 @@ namespace OpenSim
|
|||
|
||||
UseCircuitCodePacket useCircuit = (UseCircuitCodePacket)packet;
|
||||
this.clientCircuits.Add(epSender, useCircuit.CircuitCode.Code);
|
||||
SimClient newuser = new SimClient(epSender, useCircuit, LocalWorld, _packetServer.ClientThreads, AssetCache, GridServers.GridServer, this, InventoryCache, m_sandbox,((RemoteGridBase)this.GridServers.GridServer).agentcircuits[useCircuit.CircuitCode.Code].child);
|
||||
bool isChildAgent = false;
|
||||
if (this.GridServers.GridServer.GetName() == "Remote")
|
||||
{
|
||||
isChildAgent = ((RemoteGridBase)this.GridServers.GridServer).agentcircuits[useCircuit.CircuitCode.Code].child;
|
||||
}
|
||||
SimClient newuser = new SimClient(epSender, useCircuit, LocalWorld, _packetServer.ClientThreads, AssetCache, GridServers.GridServer, this, InventoryCache, m_sandbox, isChildAgent);
|
||||
if ((this.GridServers.UserServer != null) && (user_accounts))
|
||||
{
|
||||
newuser.UserServer = this.GridServers.UserServer;
|
||||
|
@ -313,12 +323,15 @@ namespace OpenSim
|
|||
//OpenSimRoot.Instance.ClientThreads.Add(epSender, newuser);
|
||||
this._packetServer.ClientThreads.Add(useCircuit.CircuitCode.Code, newuser);
|
||||
|
||||
if(!((RemoteGridBase)GridServers.GridServer).agentcircuits[useCircuit.CircuitCode.Code].child) {
|
||||
//if (!((RemoteGridBase)GridServers.GridServer).agentcircuits[useCircuit.CircuitCode.Code].child)
|
||||
if ((this.GridServers.GridServer.GetName() == "Remote") && (!isChildAgent))
|
||||
{
|
||||
Hashtable SimParams;
|
||||
ArrayList SendParams;
|
||||
XmlRpcRequest GridReq;
|
||||
XmlRpcResponse GridResp;
|
||||
foreach (Hashtable neighbour in ((RemoteGridBase)this.GridServers.GridServer).neighbours) {
|
||||
foreach (Hashtable neighbour in ((RemoteGridBase)this.GridServers.GridServer).neighbours)
|
||||
{
|
||||
m_console.WriteLine("http://" + neighbour["sim_ip"] + ":" + neighbour["sim_port"]);
|
||||
SimParams = new Hashtable();
|
||||
SimParams["session_id"] = ((RemoteGridBase)this.GridServers.GridServer).agentcircuits[useCircuit.CircuitCode.Code].SessionID.ToString();
|
||||
|
|
Loading…
Reference in New Issue