* minor: Stop presence child status suffering an NRE if the agent uuid given is not represent at all
parent
4b71b88114
commit
2e288fade1
|
@ -72,7 +72,15 @@ namespace OpenSim.Framework
|
||||||
|
|
||||||
string GetSimulatorVersion();
|
string GetSimulatorVersion();
|
||||||
|
|
||||||
bool PresenceChildStatus(UUID avatarID);
|
/// <summary>
|
||||||
|
/// Is the agent denoted by the given agentID a child presence in this scene?
|
||||||
|
/// </summary>
|
||||||
|
///
|
||||||
|
/// Used by ClientView when a 'kick everyone' or 'estate message' occurs
|
||||||
|
///
|
||||||
|
/// <param name="avatarID">AvatarID to lookup</param>
|
||||||
|
/// <returns>true if the presence is a child agent, false if the presence does not exist or is not a child agent</returns>
|
||||||
|
bool PresenceChildStatus(UUID agentId);
|
||||||
|
|
||||||
// Diva: get this out of here!!!
|
// Diva: get this out of here!!!
|
||||||
string GetCapsPath(UUID agentId);
|
string GetCapsPath(UUID agentId);
|
||||||
|
|
|
@ -4130,15 +4130,14 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
return m_sceneGraph.GetScenePresence(avatarID);
|
return m_sceneGraph.GetScenePresence(avatarID);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Request an Avatar's Child Status - used by ClientView when a 'kick everyone' or 'estate message' occurs
|
|
||||||
/// </summary>
|
|
||||||
/// <param name="avatarID">AvatarID to lookup</param>
|
|
||||||
/// <returns></returns>
|
|
||||||
public override bool PresenceChildStatus(UUID avatarID)
|
public override bool PresenceChildStatus(UUID avatarID)
|
||||||
{
|
{
|
||||||
ScenePresence cp = GetScenePresence(avatarID);
|
ScenePresence cp = GetScenePresence(avatarID);
|
||||||
return cp.IsChildAgent;
|
|
||||||
|
if (cp != null)
|
||||||
|
return cp.IsChildAgent;
|
||||||
|
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
Loading…
Reference in New Issue