Update Player.php

This commit is contained in:
kotyara 2022-03-08 14:46:50 +05:00 • committed by GitHub
parent 5581f91b34
commit 9ee61ed3ad
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -2007,7 +2007,11 @@ class Player{
if(trim($packet->message) != "" and strlen($packet->message) <= 255){
$message = $packet->message;
if($message{0} === "/"){ //Command
console("[INFO] " . FORMAT_AQUA . $this->username . FORMAT_RESET . " issued a command: " . FORMAT_AQUA . $message);
if($this instanceof Player){
console("[DEBUG] ".FORMAT_AQUA.$this->username.FORMAT_RESET." issued server command: ".$message);
}else{
console("[DEBUG] ".FORMAT_YELLOW."*".$this.FORMAT_RESET." issued server command: ".$message);
}
$this->server->api->console->run(substr($message, 1), $this);
}else{
$data = array("player" => $this, "message" => $message);