mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-06 18:11:52 +00:00
Added Plugin List on sendUsage()
This commit is contained in:
parent
f07cd21dd1
commit
23a7847350
@ -222,6 +222,10 @@ class ServerAPI{
|
|||||||
|
|
||||||
public function sendUsage(){
|
public function sendUsage(){
|
||||||
console("[INTERNAL] Sending usage data...", true, true, 3);
|
console("[INTERNAL] Sending usage data...", true, true, 3);
|
||||||
|
$plist = "";
|
||||||
|
foreach($this->plugin->getList() as $p){
|
||||||
|
$plist .= str_replace(array(";", ":"), "", $p["name"]).":".str_replace(array(";", ":"), "", $p["version"]).";";
|
||||||
|
}
|
||||||
Utils::curl_post("http://stats.pocketmine.net/usage.php", array(
|
Utils::curl_post("http://stats.pocketmine.net/usage.php", array(
|
||||||
"serverid" => $this->server->serverID,
|
"serverid" => $this->server->serverID,
|
||||||
"os" => Utils::getOS(),
|
"os" => Utils::getOS(),
|
||||||
@ -229,6 +233,7 @@ class ServerAPI{
|
|||||||
"protocol" => CURRENT_PROTOCOL,
|
"protocol" => CURRENT_PROTOCOL,
|
||||||
"online" => count($this->server->clients),
|
"online" => count($this->server->clients),
|
||||||
"max" => $this->server->maxClients,
|
"max" => $this->server->maxClients,
|
||||||
|
"plugins" => $plist,
|
||||||
), 10);
|
), 10);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user