From d04e994d1b87212cf2b5781e1985f0c17cbf393c Mon Sep 17 00:00:00 2001 From: Shoghi Cervantes Date: Sun, 21 Sep 2014 01:01:37 +0200 Subject: [PATCH] Added TPS load to /status --- src/pocketmine/command/defaults/StatusCommand.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pocketmine/command/defaults/StatusCommand.php b/src/pocketmine/command/defaults/StatusCommand.php index dd30520c5..e5e638940 100644 --- a/src/pocketmine/command/defaults/StatusCommand.php +++ b/src/pocketmine/command/defaults/StatusCommand.php @@ -43,6 +43,7 @@ class StatusCommand extends VanillaCommand{ $server = $sender->getServer(); $sender->sendMessage(TextFormat::GREEN . "---- " . TextFormat::WHITE . "Server status" . TextFormat::GREEN . " ----"); $sender->sendMessage(TextFormat::GOLD . "TPS: " . TextFormat::WHITE . $server->getTicksPerSecond()); + $sender->sendMessage(TextFormat::GOLD . "TPS Load: " . TextFormat::WHITE . $server->getTickUsage() . "%"); //TODO: implement network speed //$sender->sendMessage(TextFormat::GOLD . "Upload: " . TextFormat::WHITE . round($server->getNetwork()->getUploadSpeed() / 1024, 2) . " kB/s"); //$sender->sendMessage(TextFormat::GOLD . "Download: " . TextFormat::WHITE . round($server->getNetwork()->getDownloadSpeed() / 1024, 2) . " kB/s"); @@ -50,4 +51,4 @@ class StatusCommand extends VanillaCommand{ return true; } -} \ No newline at end of file +}