removed oninits from the plugins

This commit is contained in:
kremsy
2014-01-18 10:26:32 +01:00
committed by Steffen Schröder
parent 30baf3e00d
commit 90b0579c17
5 changed files with 18 additions and 26 deletions

View File

@ -101,7 +101,6 @@ class CustomVotesPlugin implements CommandListener, CallbackListener, ManialinkP
$this->maniaControl->callbackManager->registerCallbackListener(CallbackManager::CB_MP_PLAYERMANIALINKPAGEANSWER, $this, 'handleManialinkPageAnswer');
$this->maniaControl->callbackManager->registerCallbackListener(self::CB_CUSTOM_VOTE_FINISHED, $this, 'handleVoteFinished');
$this->maniaControl->callbackManager->registerCallbackListener(CallbackManager::CB_MC_ONINIT, $this, 'handleOnInit');
$this->maniaControl->callbackManager->registerCallbackListener(PlayerManager::CB_PLAYERJOINED, $this, 'handlePlayerConnect');
//Settings
@ -127,6 +126,7 @@ class CustomVotesPlugin implements CommandListener, CallbackListener, ManialinkP
$this->defineVote("restartmap", "Restart Map");
$this->defineVote("pausegame", "Pause Game");
$this->constructMenu();
return true;
}
@ -183,7 +183,7 @@ class CustomVotesPlugin implements CommandListener, CallbackListener, ManialinkP
*
* @param array $callback
*/
public function handleOnInit(array $callback) {
private function constructMenu() {
// Menu RestartMap
$itemQuad = new Quad_UIConstruction_Buttons();
$itemQuad->setSubStyle($itemQuad::SUBSTYLE_Reload);