TrackManiaControl/core/Callbacks/Callbacks.php

168 lines
6.9 KiB
PHP
Raw Permalink Normal View History

2014-04-24 17:41:05 +02:00
<?php
2014-05-13 18:26:38 +02:00
2014-06-14 17:10:19 +02:00
namespace ManiaControl\Callbacks;
2014-05-13 18:26:38 +02:00
2014-04-24 17:41:05 +02:00
/**
* Callbacks Interface
*
2014-05-02 17:50:30 +02:00
* @author ManiaControl Team <mail@maniacontrol.com>
2020-01-22 10:39:35 +01:00
* @copyright 2014-2020 ManiaControl Team
2014-04-24 17:41:05 +02:00
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
*/
interface Callbacks {
/*
* ManiaControl Callbacks
*/
const ONINIT = 'Callbacks.OnInit';
const AFTERINIT = 'Callbacks.AfterInit';
const ONSHUTDOWN = 'Callbacks.OnShutdown';
2020-04-24 18:51:38 +02:00
/** @deprecated */
2015-06-26 16:53:41 +02:00
const ONRESTART = 'Callbacks.OnRestart';
2020-04-24 18:51:38 +02:00
const ONREBOOT = 'Callbacks.OnReboot';
2017-06-22 15:07:00 +02:00
const PRELOOP = 'Callbacks.PreLoop';
const AFTERLOOP = 'Callbacks.AfterLoop';
2014-05-13 18:26:38 +02:00
/** Script Callback: CallbackName, CallbackData */
2014-04-24 21:55:47 +02:00
const SCRIPTCALLBACK = 'Callbacks.ScriptCallback';
2014-05-13 18:26:38 +02:00
/*
* Common Callbacks
*/
//NEW Callbacks
const XMLRPC_CALLBACKSLIST = 'XmlRpc.CallbacksList';
const XMLRPC_ENABLEDCALLBACKS = 'XmlRpc.CallbacksList_Enabled';
const XMLRPC_DISABLEDCALLBACKS = 'XmlRpc.CallbacksList_Disabled';
const XMLRPC_CALLBACKHELP = 'XmlRpc.CallbackHelp';
const XMLRPC_METHODSLIST = 'XmlRpc.MethodsList';
const XMLRPC_METHODHELP = 'XmlRpc.MethodHelp';
const XMLRPC_DOCUMENTATION = 'XmlRpc.Documentation';
const XMLRPC_APIVERSION = 'XmlRpc.ApiVersion';
const XMLRPC_ALLAPIVERSIONS = 'XmlRpc.AllApiVersions';
2017-03-25 13:57:42 +01:00
const MP_STARTSERVERSTART = 'Maniaplanet.StartServer_Start';
const MP_STARTSERVEREND = 'Maniaplanet.StartServer_End';
const MP_STARTMATCHSTART = 'Maniaplanet.StartMatch_Start';
const MP_STARTMATCHEND = 'Maniaplanet.StartMatch_End';
//const MP_STARTMAPSTART = 'Maniaplanet.StartMap_Start';
//const MP_STARTMAPEND = 'Maniaplanet.StartMap_End';
const MP_STARTROUNDSTART = 'Maniaplanet.StartRound_Start';
const MP_STARTROUNDEND = 'Maniaplanet.StartRound_End';
const MP_STARTTURNSTART = 'Maniaplanet.StartTurn_Start';
const MP_STARTTURNEND = 'Maniaplanet.StartTurn_End';
const MP_STARTPLAYLOOP = 'Maniaplanet.StartPlayLoop';
const MP_ENDPLAYLOOP = 'Maniaplanet.EndPlayLoop';
const MP_ENDTURNSTART = 'Maniaplanet.EndTurn_Start';
const MP_ENDTURNEND = 'Maniaplanet.EndTurn_End';
const MP_ENDROUNDSTART = 'Maniaplanet.EndRound_Start';
const MP_ENDROUNDEND = 'Maniaplanet.EndRound_End';
//const MP_ENDMAPSTART = 'Maniaplanet.EndMap_Start';
//const MP_ENDMAPEND = 'Maniaplanet.EndMap_End';
const MP_ENDMATCHSTART = 'Maniaplanet.EndMatch_Start';
const MP_ENDMATCHEND = 'Maniaplanet.EndMatch_End';
const MP_ENDSERVERSTART = 'Maniaplanet.EndServer_Start';
const MP_ENDSERVEREND = 'Maniaplanet.EndServer_End';
const MP_LOADINGMAPSTART = 'Maniaplanet.LoadingMap_Start';
const MP_LOADINGMAPEND = 'Maniaplanet.LoadingMap_End';
const MP_UNLOADINGMAPSTART = 'Maniaplanet.UnloadingMap_Start';
const MP_UNLOADINGMAPEND = 'Maniaplanet.UnloadingMap_End';
const MP_PODIUMSTART = 'Maniaplanet.Podium_Start';
const MP_PODIUMEND = 'Maniaplanet.Podium_End';
2017-03-24 22:49:43 +01:00
const MP_WARMUP_START = 'Maniaplanet.WarmUp.Start';
const MP_WARMUP_END = 'Maniaplanet.WarmUp.End';
2017-04-07 17:28:04 +02:00
const MP_WARMUP_STATUS = 'Maniaplanet.WarmUp.Status';
const MP_USES_TEAMMODE = 'Maniaplanet.Mode.UseTeams';
const MP_PAUSE_STATUS = 'Maniaplanet.Pause.Status';
2017-04-14 17:02:00 +02:00
const SM_UIPROPERTIES = 'Shootmania.UI.Properties';
const SM_SCORES = "Shootmania.Scores";
2017-03-25 20:19:45 +01:00
const SM_ONEVENTDEFAULT = "Shootmania.Event.Default";
const SM_ONSHOOT = "Shootmania.Event.OnShoot";
const SM_ONHIT = "Shootmania.Event.OnHit";
const SM_ONNEARMISS = "Shootmania.Event.OnNearMiss";
const SM_ONARMOREMPTY = "Shootmania.Event.OnArmorEmpty";
const SM_ONCAPTURE = "Shootmania.Event.OnCapture";
const SM_ONSHOTDENY = "Shootmania.Event.OnShotDeny";
const SM_ONFALLDAMAGE = "Shootmania.Event.OnFallDamage";
const SM_ONCOMMAND = "Shootmania.Event.OnCommand";
2017-04-13 19:14:23 +02:00
const SM_PLAYERSAFK = "Shootmania.AFK.IsAfk";
const SM_AFKPROPERTIES = "Shootmania.AFK.GetProperties";
2017-04-13 19:14:23 +02:00
/**
* Use the PlayerManager Callback in favour of this
*
* @see \ManiaControl\Players\PlayerManager::CB_PLAYERCONNECT
*/
const SM_ONPLAYERADDED = "Shootmania.Event.OnPlayerAdded";
/**
* Use the PlayerManager Callback in favour of this
*
* @see \ManiaControl\Players\PlayerManager::CB_PLAYERDISCONNECT
*/
const SM_ONPLAYERREMOVED = "Shootmania.Event.OnPlayerRemoved";
2017-03-25 20:19:45 +01:00
const SM_ONPLAYERREQUESTRESPAWN = "Shootmania.Event.OnPlayerRequestRespawn";
2017-03-24 22:49:43 +01:00
const SM_ONACTIONCUSTOMEVENT = "Shootmania.Event.OnActionCustomEvent";
const SM_ONACTIONEVENT = "Shootmania.Event.OnActionEvent";
const SM_ONPLAYERTOUCHESOBJECT = "Shootmania.Event.OnPlayerTouchesObject";
const SM_ONPLAYERTRIGGERSSECTOR = "Shootmania.Event.OnPlayerTriggersSector";
const SM_ONPLAYERTHROWSOBJECT = "Shootmania.Event.OnPlayerThrowsObject";
const SM_ONPLAYERREQUESTACTIONCHANGE = "Shootmania.Event.OnPlayerRequestActionChange";
2017-04-07 17:28:04 +02:00
//SM GameMode Callbacks
const SM_ELITE_STARTTURN = 'Shootmania.Elite.StartTurn';
const SM_ELITE_ENDTURN = 'Shootmania.Elite.EndTurn';
const SM_JOUST_ONRELOAD = 'Shootmania.Joust.OnReload';
2017-04-07 17:28:04 +02:00
const SM_JOUST_SELECTEDPLAYERS = 'Shootmania.Joust.SelectedPlayers';
const SM_JOUST_ROUNDRESULT = 'Shootmania.Joust.RoundResult';
const SM_ROYAL_POINTS = 'Shootmania.Royal.Points';
const SM_ROYAL_PLAYERSPAWN = 'Shootmania.Royal.PlayerSpawn';
const SM_ROYAL_ROUNDWINNER = 'Shootmania.Royal.RoundWinner';
2017-04-01 10:30:18 +02:00
2017-04-07 17:28:04 +02:00
// New TM Callbacks
2017-04-01 10:30:18 +02:00
const TM_ONEVENTDEFAULT = "Trackmania.Event.Default";
const TM_ONEVENTSTARTLINE = "Trackmania.Event.StartLine";
const TM_ONCOMMAND = "Trackmania.Event.OnCommand";
2017-04-13 19:14:23 +02:00
/**
* Use the PlayerManager Callback in favour of this
*
* @see \ManiaControl\Players\PlayerManager::CB_PLAYERCONNECT
*/
const TM_ONPLAYERADDED = "Trackmania.Event.OnPlayerAdded";
/**
* Use the PlayerManager Callback in favour of this
*
* @see \ManiaControl\Players\PlayerManager::CB_PLAYERDISCONNECT
*/
2017-04-14 17:02:00 +02:00
const TM_ONPLAYERREMOVED = "Trackmania.Event.OnPlayerRemoved";
const TM_ONWAYPOINT = "Trackmania.Event.WayPoint";
const TM_ONGIVEUP = "Trackmania.Event.GiveUp";
const TM_ONRESPAWN = "Trackmania.Event.Respawn";
const TM_ONSTUNT = "Trackmania.Event.Stunt";
const TM_ONSTARTCOUNTDOWN = "Trackmania.Event.StartCountdown";
const TM_SCORES = "Trackmania.Scores";
const TM_WARMUPSTART = "Trackmania.WarmUp.Start";
const TM_WARMUPSTARTROUND = "Trackmania.WarmUp.StartRound";
const TM_WARMUPENDROUND = "Trackmania.WarmUp.EndRound";
const TM_WARMUPEND = "Trackmania.WarmUp.End";
const TM_UIPROPERTIES = 'Trackmania.UI.Properties';
const TM_POINTSREPARTITION = 'Trackmania.PointsRepartition';
//ManiaControl Specific TM Callbacks
const TM_ONFINISHLINE = "ManiaControl.Trackmania.Event.OnFinishLine";
const TM_ONLAPFINISH = "ManiaControl.Trackmania.Event.OnLapFinish";
//ManiaControl Callbacks
/** BeginMap Callback: Map */
const BEGINMAP = 'Callbacks.BeginMap';
2017-04-01 11:12:06 +02:00
/** EndMap Callback: Map*/
const ENDMAP = 'Callbacks.EndMap';
2014-05-13 18:26:38 +02:00
}