mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-22 04:29:43 +00:00
Better online player list
This commit is contained in:
parent
2438c9535b
commit
bbbdaa30d1
1 changed files with 5 additions and 1 deletions
|
|
@ -200,7 +200,11 @@ class PlayerAPI{
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case "list":
|
case "list":
|
||||||
$output .= "Player list:\n";
|
if(count($this->server->clients) == 0){
|
||||||
|
$output .= "No online players.\n";
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
$output .= "Online players: ";
|
||||||
foreach($this->server->clients as $c){
|
foreach($this->server->clients as $c){
|
||||||
$output .= $c->username.", ";
|
$output .= $c->username.", ";
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue