2006-11-22 00:09:31 +00:00
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Text;
|
|
|
|
|
using libsecondlife;
|
|
|
|
|
using libsecondlife.Packets;
|
|
|
|
|
|
2006-11-24 22:27:15 +00:00
|
|
|
namespace libsecondlife.TestClient
|
2006-11-22 00:09:31 +00:00
|
|
|
{
|
2006-12-16 16:51:04 +00:00
|
|
|
public class UptimeCommand : Command
|
2006-11-22 00:09:31 +00:00
|
|
|
{
|
2006-12-16 16:51:04 +00:00
|
|
|
public DateTime Created = DateTime.Now;
|
2006-11-22 00:09:31 +00:00
|
|
|
|
2006-12-21 08:53:08 +00:00
|
|
|
public UptimeCommand(TestClient testClient)
|
2006-12-16 16:51:04 +00:00
|
|
|
{
|
|
|
|
|
Name = "uptime";
|
|
|
|
|
Description = "Shows the login name, login time and length of time logged on.";
|
|
|
|
|
}
|
2006-11-22 00:09:31 +00:00
|
|
|
|
2006-12-21 08:53:08 +00:00
|
|
|
public override string Execute(string[] args, LLUUID fromAgentID)
|
2006-12-16 16:51:04 +00:00
|
|
|
{
|
|
|
|
|
string name = Client.ToString();
|
|
|
|
|
return "I am " + name + ", Up Since: " + Created + " (" + (DateTime.Now - Created) + ")";
|
|
|
|
|
}
|
2006-11-22 00:09:31 +00:00
|
|
|
}
|
2006-12-16 16:51:04 +00:00
|
|
|
}
|