fixed bug

This commit is contained in:
kremsy 2014-03-01 19:54:44 +01:00 committed by Steffen Schröder
parent 317d6c506b
commit b18e736c57
2 changed files with 5 additions and 1 deletions

View File

@ -164,7 +164,7 @@ class PlayerActions {
}
$target = $this->maniaControl->playerManager->getPlayer($targetLogin);
if (!$admin || !$target) {
if (!$admin || !$target || $target->isSpectator) {
return;
}

View File

@ -352,6 +352,10 @@ class ChatMessagePlugin implements CommandListener, Plugin {
$this->maniaControl->chat->sendChat($msg, null, false);
if ($this->maniaControl->settingManager->getSetting($this, self::SETTING_AFK_FORCE_SPEC)) {
if($player->isSpectator){
return;
}
// force into spec
try {
$this->maniaControl->client->forceSpectator($player->login, 3);