diff options
author | Andrei Karas <akaras@inbox.ru> | 2011-03-12 21:59:09 +0200 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2011-03-12 21:59:09 +0200 |
commit | 7f1553890e614d5c7afd7f01a11277b822fd4a05 (patch) | |
tree | 1d6cb7011db199d41efb3060ce9ede0c57a3b810 /src/client.cpp | |
parent | 0c6bf93ee13f0b3344079ebf4e60c5ec8323f0bd (diff) | |
download | mv-7f1553890e614d5c7afd7f01a11277b822fd4a05.tar.gz mv-7f1553890e614d5c7afd7f01a11277b822fd4a05.tar.bz2 mv-7f1553890e614d5c7afd7f01a11277b822fd4a05.tar.xz mv-7f1553890e614d5c7afd7f01a11277b822fd4a05.zip |
Add /uptime chat command to show client uptime.
Diffstat (limited to 'src/client.cpp')
-rw-r--r-- | src/client.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/client.cpp b/src/client.cpp index e1753753e..5c183a17d 100644 --- a/src/client.cpp +++ b/src/client.cpp @@ -152,6 +152,7 @@ volatile int cur_time; volatile bool runCounters; bool isSafeMode = false; int serverVersion; +int start_time; /** * Advances game logic counter. @@ -535,6 +536,8 @@ Client::Client(const Options &options): optionChanged("fpslimit"); + start_time = time(NULL); + // Initialize PlayerInfo PlayerInfo::init(); } |