added isMuted() function to the player object + some adds what a player cant do when muted (use chatmessages like /gg, add map to queue, start a vote...)

This commit is contained in:
kremsy
2014-08-24 12:28:16 +02:00
parent afa15217a2
commit ffa3506879
7 changed files with 307 additions and 263 deletions

View File

@ -263,6 +263,12 @@ class MapQueue implements CallbackListener, CommandListener {
return;
}
// Check if the Player is muted
if ($player->isMuted()) {
$this->maniaControl->getChat()->sendError('Muted Players are not allowed to queue a map.', $player);
return;
}
//Check if player is allowed to add (another) map
$isModerator = $this->maniaControl->getAuthenticationManager()->checkRight($player, AuthenticationManager::AUTH_LEVEL_MODERATOR);