Moving examples, mapgenerator, and VisualParamGenerator to Programs folder (SVN is seriously ruined still, don't check out yet)
git-svn-id: http://libopenmetaverse.googlecode.com/svn/trunk@1961 52acb1d6-8a22-11de-b505-999d5b087335
This commit is contained in:
25
Programs/examples/TestClient/Commands/Stats/UptimeCommand.cs
Normal file
25
Programs/examples/TestClient/Commands/Stats/UptimeCommand.cs
Normal file
@@ -0,0 +1,25 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using OpenMetaverse;
|
||||
using OpenMetaverse.Packets;
|
||||
|
||||
namespace OpenMetaverse.TestClient
|
||||
{
|
||||
public class UptimeCommand : Command
|
||||
{
|
||||
public DateTime Created = DateTime.Now;
|
||||
|
||||
public UptimeCommand(TestClient testClient)
|
||||
{
|
||||
Name = "uptime";
|
||||
Description = "Shows the login name, login time and length of time logged on.";
|
||||
}
|
||||
|
||||
public override string Execute(string[] args, LLUUID fromAgentID)
|
||||
{
|
||||
string name = Client.ToString();
|
||||
return "I am " + name + ", Up Since: " + Created + " (" + (DateTime.Now - Created) + ")";
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user