mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-05-17 11:18:52 +00:00
Seperated kick/ban messages
This commit is contained in:
parent
fb87165cd5
commit
78525e1f74
@ -2909,7 +2909,11 @@ class Player extends Human implements CommandSender, InventoryHolder, ChunkLoade
|
|||||||
$this->server->getPluginManager()->callEvent($ev = new PlayerKickEvent($this, $reason, $this->getLeaveMessage()));
|
$this->server->getPluginManager()->callEvent($ev = new PlayerKickEvent($this, $reason, $this->getLeaveMessage()));
|
||||||
if(!$ev->isCancelled()){
|
if(!$ev->isCancelled()){
|
||||||
if($isAdmin){
|
if($isAdmin){
|
||||||
$message = "Kicked by admin." . ($reason !== "" ? " Reason: " . $reason : "");
|
if(!$this->isBanned()) {
|
||||||
|
$message = "Kicked by admin." . ($reason !== "" ? " Reason: " . $reason : "");
|
||||||
|
}else{
|
||||||
|
$message = $reason;
|
||||||
|
}
|
||||||
}else{
|
}else{
|
||||||
if($reason === ""){
|
if($reason === ""){
|
||||||
$message = "disconnectionScreen.noReason";
|
$message = "disconnectionScreen.noReason";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user