improved player actions

This commit is contained in:
kremsy
2013-12-23 21:47:39 +01:00
parent 28a9054c0d
commit b72e036cf7
4 changed files with 85 additions and 21 deletions

View File

@ -92,12 +92,8 @@ class PlayerCommands implements CommandListener {
if (isset($params[2])) {
$message = $params[2];
}
$success = $this->maniaControl->client->query('Kick', $target->login, $message);
if (!$success) {
$this->maniaControl->chat->sendError('Error occurred: ' . $this->maniaControl->getClientErrorText(), $player->login);
return;
}
$this->maniaControl->chat->sendInformation('$<' . $player->nickname . '$> kicked $<' . $target->nickname . '$>!');
$this->maniaControl->playerManager->playerActions->kickPlayer($player->login, $target, $message);
}
/**