mirror of
https://github.com/opensim/opensim.git
synced 2026-08-10 03:06:05 +08:00
Implement XMLRPCAdmin command admin_teleport_agent.
This allows someone with access to this command on the XMLRPCAdmin interface to teleport an avatar to an arbitrary region and/or position.
This commit is contained in:
@@ -545,6 +545,23 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
return false;
|
||||
}
|
||||
|
||||
public bool TryGetRootScenePresence(UUID avatarId, out ScenePresence avatar)
|
||||
{
|
||||
lock (m_localScenes)
|
||||
{
|
||||
foreach (Scene scene in m_localScenes)
|
||||
{
|
||||
avatar = scene.GetScenePresence(avatarId);
|
||||
|
||||
if (avatar != null && !avatar.IsChildAgent)
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
avatar = null;
|
||||
return false;
|
||||
}
|
||||
|
||||
public bool TryGetAvatarsScene(UUID avatarId, out Scene scene)
|
||||
{
|
||||
ScenePresence avatar = null;
|
||||
@@ -590,6 +607,22 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
return false;
|
||||
}
|
||||
|
||||
public bool TryGetRootScenePresenceByName(string firstName, string lastName, out ScenePresence sp)
|
||||
{
|
||||
lock (m_localScenes)
|
||||
{
|
||||
foreach (Scene scene in m_localScenes)
|
||||
{
|
||||
sp = scene.GetScenePresence(firstName, lastName);
|
||||
if (sp != null && !sp.IsChildAgent)
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
sp = null;
|
||||
return false;
|
||||
}
|
||||
|
||||
public void ForEachScene(Action<Scene> action)
|
||||
{
|
||||
lock (m_localScenes)
|
||||
|
||||
Reference in New Issue
Block a user