mirror of
https://github.com/opensim/opensim.git
synced 2026-08-04 16:22:50 +08:00
Mantis#2725. Thank you kindly, Diva, for a patch that:
Adds missing protocol pieces for EstablishAgentCommunication event which allows the client to activate CAPS and the EQ for child agents.
This commit is contained in:
@@ -202,6 +202,7 @@ namespace OpenSim.Region.Environment.Modules.Framework
|
||||
{
|
||||
m_AvatarQueueUUIDMapping.Remove(ky);
|
||||
m_scene.RemoveHTTPHandler("","/CAPS/EQG/" + ky.ToString() + "/");
|
||||
m_log.Debug("[EVENTQUEUE]: Removing " + "/CAPS/EQG/" + ky.ToString() + "/");
|
||||
}
|
||||
|
||||
}
|
||||
@@ -225,6 +226,7 @@ namespace OpenSim.Region.Environment.Modules.Framework
|
||||
m_QueueUUIDAvatarMapping.Remove(ky);
|
||||
|
||||
}
|
||||
|
||||
m_log.DebugFormat("[EVENTQUEUE]: Client {0} deregistered in region {1}.", AgentID, m_scene.RegionInfo.RegionName);
|
||||
}
|
||||
|
||||
@@ -326,13 +328,14 @@ namespace OpenSim.Region.Environment.Modules.Framework
|
||||
|
||||
if (element == null)
|
||||
{
|
||||
// m_log.ErrorFormat("[EVENTQUEUE]: Failed to process queue");
|
||||
//m_log.ErrorFormat("[EVENTQUEUE]: Nothing to process in " + m_scene.RegionInfo.RegionName);
|
||||
if (thisID == -1) // close-request
|
||||
{
|
||||
responsedata["int_response_code"] = 404;
|
||||
m_log.ErrorFormat("[EVENTQUEUE]: 404 in " + m_scene.RegionInfo.RegionName);
|
||||
responsedata["int_response_code"] = 404; //501; //410; //404;
|
||||
responsedata["content_type"] = "text/plain";
|
||||
responsedata["keepalive"] = false;
|
||||
responsedata["str_response_string"] = "";
|
||||
responsedata["str_response_string"] = "Closed EQG";
|
||||
return responsedata;
|
||||
}
|
||||
responsedata["int_response_code"] = 502;
|
||||
|
||||
@@ -80,15 +80,15 @@ namespace OpenSim.Region.Environment
|
||||
|
||||
public static OSD DisableSimulator(ulong Handle)
|
||||
{
|
||||
OSDMap llsdSimInfo = new OSDMap(1);
|
||||
//OSDMap llsdSimInfo = new OSDMap(1);
|
||||
|
||||
llsdSimInfo.Add("Handle", new OSDBinary(regionHandleToByteArray(Handle)));
|
||||
//llsdSimInfo.Add("Handle", new OSDBinary(regionHandleToByteArray(Handle)));
|
||||
|
||||
OSDArray arr = new OSDArray(1);
|
||||
arr.Add(llsdSimInfo);
|
||||
//OSDArray arr = new OSDArray(1);
|
||||
//arr.Add(llsdSimInfo);
|
||||
|
||||
OSDMap llsdBody = new OSDMap(1);
|
||||
llsdBody.Add("SimulatorInfo", arr);
|
||||
OSDMap llsdBody = new OSDMap(0);
|
||||
//llsdBody.Add("SimulatorInfo", arr);
|
||||
|
||||
return buildEvent("DisableSimulator", llsdBody);
|
||||
}
|
||||
@@ -178,6 +178,16 @@ namespace OpenSim.Region.Environment
|
||||
return buildEvent("ScriptRunningReply", body);
|
||||
}
|
||||
|
||||
public static OSD EstablishAgentCommunication(UUID agentID, string simIpAndPort, string seedcap)
|
||||
{
|
||||
OSDMap body = new OSDMap(3);
|
||||
body.Add("agent-id", new OSDUUID(agentID));
|
||||
body.Add("sim-ip-and-port", new OSDString(simIpAndPort));
|
||||
body.Add("seed-capability", new OSDString(seedcap));
|
||||
|
||||
return buildEvent("EstablishAgentCommunication", body);
|
||||
}
|
||||
|
||||
public static OSD KeepAliveEvent()
|
||||
{
|
||||
return buildEvent("FAKEEVENT", new OSDMap());
|
||||
|
||||
Reference in New Issue
Block a user