2008-07-25 08:55:36 +00:00
|
|
|
using System;
|
|
|
|
|
|
|
|
|
|
namespace OpenMetaverse.TestClient
|
|
|
|
|
{
|
|
|
|
|
public class GotoLandmarkCommand : Command
|
|
|
|
|
{
|
|
|
|
|
public GotoLandmarkCommand(TestClient testClient)
|
|
|
|
|
{
|
|
|
|
|
Name = "goto_landmark";
|
|
|
|
|
Description = "Teleports to a Landmark. Usage: goto_landmark [UUID]";
|
|
|
|
|
Category = CommandCategory.Movement;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override string Execute(string[] args, UUID fromAgentID)
|
2007-08-01 13:44:27 +00:00
|
|
|
{
|
|
|
|
|
if (args.Length < 1)
|
|
|
|
|
{
|
|
|
|
|
return "Usage: goto_landmark [UUID]";
|
2008-07-25 08:55:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
UUID landmark = new UUID();
|
|
|
|
|
if (!UUID.TryParse(args[0], out landmark))
|
|
|
|
|
{
|
2023-01-27 20:58:07 -06:00
|
|
|
return "Invalid UUID";
|
2008-07-25 08:55:36 +00:00
|
|
|
}
|
2024-07-01 12:17:07 -05:00
|
|
|
|
|
|
|
|
Console.WriteLine("Teleporting to " + landmark);
|
|
|
|
|
return Client.Self.Teleport(landmark) ? "Teleport Successful" : "Teleport Failed";
|
2008-07-25 08:55:36 +00:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|