fixed offset error

This commit is contained in:
Steffen Schröder 2014-05-15 17:30:40 +02:00
parent 40794151b6
commit d37acbd116

View File

@ -117,7 +117,13 @@ class ObstaclePlugin implements CallbackListener, CommandListener, Plugin {
} }
// Send jump callback // Send jump callback
$params = explode(' ', $chatCallback[1][2], 2); $params = explode(' ', $chatCallback[1][2], 2);
$param = $player->login . ";" . $params[1] . ";"; if (count($params) < 2) {
$message = "Usage: '//jumpto login' or '//jumpto checkpointnumber'";
$this->maniaControl->chat->sendUsageInfo($message, $player);
return;
}
$param = $player->login . ";" . $params[1] . ";";
try { try {
$this->maniaControl->client->triggerModeScriptEvent(self::CB_JUMPTO, $param); $this->maniaControl->client->triggerModeScriptEvent(self::CB_JUMPTO, $param);
} catch (GameModeException $e) { } catch (GameModeException $e) {