mirror of
https://github.com/opensim/opensim.git
synced 2026-08-07 17:55:48 +08:00
Plumb a code path for the entity transfer module to ask a destination scene
whether or not an agent is allowed there as a root agent.
This commit is contained in:
@@ -115,6 +115,11 @@ namespace OpenSim.Server.Handlers.Simulation
|
||||
DoChildAgentDelete(request, responsedata, agentID, action, regionID);
|
||||
return responsedata;
|
||||
}
|
||||
else if (method.Equals("QUERYACCESSS"))
|
||||
{
|
||||
DoQueryAccess(request, responsedata, agentID, regionID);
|
||||
return responsedata;
|
||||
}
|
||||
else
|
||||
{
|
||||
m_log.InfoFormat("[AGENT HANDLER]: method {0} not supported in agent message", method);
|
||||
@@ -305,6 +310,27 @@ namespace OpenSim.Server.Handlers.Simulation
|
||||
return m_SimulationService.UpdateAgent(destination, agent);
|
||||
}
|
||||
|
||||
protected virtual void DoQueryAccess(Hashtable request, Hashtable responsedata, UUID id, UUID regionID)
|
||||
{
|
||||
if (m_SimulationService == null)
|
||||
{
|
||||
m_log.Debug("[AGENT HANDLER]: Agent QUERY called. Harmless but useless.");
|
||||
responsedata["content_type"] = "application/json";
|
||||
responsedata["int_response_code"] = HttpStatusCode.NotImplemented;
|
||||
responsedata["str_response_string"] = string.Empty;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
GridRegion destination = new GridRegion();
|
||||
destination.RegionID = regionID;
|
||||
|
||||
bool result = m_SimulationService.QueryAccess(destination, id);
|
||||
|
||||
responsedata["int_response_code"] = HttpStatusCode.OK;
|
||||
responsedata["str_response_string"] = result.ToString();
|
||||
}
|
||||
|
||||
protected virtual void DoAgentGet(Hashtable request, Hashtable responsedata, UUID id, UUID regionID)
|
||||
{
|
||||
if (m_SimulationService == null)
|
||||
|
||||
Reference in New Issue
Block a user