3#ifndef GAME_SERVER_GAMECONTEXT_H
4#define GAME_SERVER_GAMECONTEXT_H
145 void AddVote(
const char *pDescription,
const char *pCommand);
146 static int MapScan(
const char *pName,
int IsDir,
int DirType,
void *pUserData);
202 void StartVote(
const char *pDesc,
const char *pCommand,
const char *pReason,
const char *pSixupDesc);
253 bool SnapLaserObject(
const CSnapContext &Context,
int SnapId,
const vec2 &To,
const vec2 &From,
int StartTick,
int Owner = -1,
int LaserType = -1,
int Subtype = -1,
int SwitchNumber = -1)
const;
263 void CallVote(
int ClientId,
const char *pDesc,
const char *pCmd,
const char *pReason,
const char *pChatmsg,
const char *pSixupDesc = 0);
268 void SendEmoticon(
int ClientId,
int Emoticon,
int TargetClientId)
const;
272 void SendBroadcast(
const char *pText,
int ClientId,
bool IsImportant =
true);
274 void List(
int ClientId,
const char *pFilter);
287 void OnInit(
const void *pPersistentData)
override;
291 void OnMapChange(
char *pNewMapName,
int MapNameSize)
override;
292 void OnShutdown(
void *pPersistentData)
override;
296 void OnSnap(
int ClientId)
override;
302 void CensorMessage(
char *pCensoredMessage,
const char *pMessage,
int Size);
321 void OnClientDrop(
int ClientId,
const char *pReason)
override;
341 const char *
GameType()
const override;
342 const char *
Version()
const override;
359 void ForceVote(
int EnforcerId,
bool Success);
411 void MoveCharacter(
int ClientId,
int X,
int Y,
bool Raw =
false);
552 bool TryMute(
const NETADDR *pAddr,
int Secs,
const char *pReason,
bool InitialChatDelay);
553 void Mute(
const NETADDR *pAddr,
int Secs,
const char *pDisplayName,
const char *pReason =
"",
bool InitialChatDelay =
false);
555 void VoteMute(
const NETADDR *pAddr,
int Secs,
const char *pReason,
const char *pDisplayName,
int AuthedId);
557 void Whisper(
int ClientId,
char *pStr);
558 void WhisperId(
int ClientId,
int VictimId,
const char *pMessage);
559 void Converse(
int ClientId,
char *pStr);
561 void UnlockTeam(
int ClientId,
int Team)
const;
581 void LogEvent(
const char *Description,
int ClientId);
601 void OnSetAuthed(
int ClientId,
int Level)
override;
Definition: character.h:30
int Team()
Definition: character.cpp:631
Definition: collision.h:34
Definition: eventhandler.h:11
Definition: gamecontext.h:79
static void ConAntibot(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:932
static void ConUnNinja(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:108
static void ConLaser(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:266
void CreatePlayerSpawn(vec2 Pos, CClientMask Mask=CClientMask().set())
Definition: gamecontext.cpp:349
static void ConTuneZone(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:2967
int m_NumVoteMutes
Definition: gamecontext.h:551
void CreateFinishEffect(vec2 Pos, CClientMask Mask=CClientMask().set())
Definition: gamecontext.cpp:380
static void ConDumpLog(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:938
static void ConGoRight(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:25
static void ConRules(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:263
static void ConMutes(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:761
void OnClientDrop(int ClientId, const char *pReason) override
Definition: gamecontext.cpp:1705
static void ConMap(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:529
void OnStartInfoNetMessage(const CNetMsg_Cl_StartInfo *pMsg, int ClientId)
Definition: gamecontext.cpp:2821
static void ConPracticeGrenade(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2149
static void ConSetJumps(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:288
CTeeHistorian m_TeeHistorian
Definition: gamecontext.h:96
void OnTick() override
Definition: gamecontext.cpp:1013
bool SnapPickup(const CSnapContext &Context, int SnapId, const vec2 &Pos, int Type, int SubType, int SwitchNumber) const
Definition: gamecontext.cpp:512
CHeap * m_pVoteOptionHeap
Definition: gamecontext.h:237
static void ConTogglePause(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:387
void TeehistorianRecordPlayerJoin(int ClientId, bool Sixup) override
Definition: gamecontext.cpp:1758
void LogEvent(const char *Description, int ClientId)
Definition: ddracecommands.cpp:971
static void ConTimeCP(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2341
void SendChatTarget(int To, const char *pText, int VersionFlags=FLAG_SIX|FLAG_SIXUP) const
Definition: gamecontext.cpp:582
static void ConTeam(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1243
static void ConPracticeUnGrenade(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2198
static void ConEyeEmote(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1380
IConsole * m_pConsole
Definition: gamecontext.h:83
static void ConForcePause(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:468
void AttemptJoinTeam(int ClientId, int Team)
Definition: ddracechat.cpp:1020
void Teleport(CCharacter *pChr, vec2 Pos)
Definition: ddracecommands.cpp:383
void ForceVote(int EnforcerId, bool Success)
Definition: gamecontext.cpp:4838
static void ConUnmuteId(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:733
static void ConGrenade(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:260
int64_t m_VoteCloseTime
Definition: gamecontext.h:210
static void ConToggleInvincible(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:163
void DeleteTempfile()
Definition: gamecontext.cpp:4144
static void ConMove(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:55
void OnMapChange(char *pNewMapName, int MapNameSize) override
Definition: gamecontext.cpp:4153
static void ConchainSpecialMotdupdate(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: gamecontext.cpp:3595
static void ConPause(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3104
static void ConGoLeft(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:15
static void ConNinjaJetpack(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1443
static void ConSetEyeEmote(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1346
int m_NumMutes
Definition: gamecontext.h:549
~CGameContext()
Definition: gamecontext.cpp:163
IAntibot * Antibot()
Definition: gamecontext.h:169
IStorage * m_pStorage
Definition: gamecontext.h:85
void SendMotd(int ClientId) const
Definition: gamecontext.cpp:727
CScore * m_pScore
Definition: gamecontext.h:374
static void ConWhispers(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:515
static void ConUnEndlessJump(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:328
void OnSayNetMessage(const CNetMsg_Cl_Say *pMsg, int ClientId, const CUnpacker *pUnpacker)
Definition: gamecontext.cpp:2093
static void ConPracticeWeapons(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2184
void OnIsDDNetLegacyNetMessage(const CNetMsg_Cl_IsDDNetLegacy *pMsg, int ClientId, CUnpacker *pUnpacker)
Definition: gamecontext.cpp:2541
void SendTuningParams(int ClientId, int Zone=0)
Definition: gamecontext.cpp:919
static void ConPracticeToTeleporter(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2005
static void ConDumpAntibot(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:926
bool IsVersionBanned(int Version)
Definition: gamecontext.cpp:4767
CVoteOptionServer * m_pVoteOptionLast
Definition: gamecontext.h:239
bool IsKickVote() const
Definition: gamecontext.h:597
int64_t m_LastMapVote
Definition: gamecontext.h:353
CNetObj_PlayerInput m_aLastPlayerInput[MAX_CLIENTS]
Definition: gamecontext.h:182
static void ConPracticeEndlessJump(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2170
static void ConPracticeJetpack(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2163
static void ConPracticeLiveFreeze(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2132
void ModifyWeapons(IConsole::IResult *pResult, void *pUserData, int Weapon, bool Remove)
Definition: ddracecommands.cpp:354
CLayers m_Layers
Definition: gamecontext.h:87
void CreateDamageInd(vec2 Pos, float AngleMod, int Amount, CClientMask Mask=CClientMask().set())
Definition: gamecontext.cpp:262
CGameWorld m_World
Definition: gamecontext.h:194
static void ConUninvite(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:836
void VoteMute(const NETADDR *pAddr, int Secs, const char *pReason, const char *pDisplayName, int AuthedId)
Definition: ddracecommands.cpp:510
void OnSetTeamNetMessage(const CNetMsg_Cl_SetTeam *pMsg, int ClientId)
Definition: gamecontext.cpp:2494
char m_aVoteCommand[VOTE_CMD_LENGTH]
Definition: gamecontext.h:215
static void ConPracticeUnEndlessHook(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2254
bool m_aPlayerHasInput[MAX_CLIENTS]
Definition: gamecontext.h:183
CMute m_aVoteMutes[MAX_VOTE_MUTES]
Definition: gamecontext.h:550
static void ConPracticeSetJumps(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2177
static void ConDrySave(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:886
void RegisterDDRaceCommands()
Definition: gamecontext.cpp:3669
void OnClientPredictedInput(int ClientId, void *pInput) override
Definition: gamecontext.cpp:1336
CTuningParams m_Tuning
Definition: gamecontext.h:91
CCollision * Collision()
Definition: gamecontext.h:166
static void ConToggleSpecVoted(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:382
static void ConMuteId(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:679
static void ConUnWeapons(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:336
void SendWeaponPickup(int ClientId, int Weapon) const
Definition: gamecontext.cpp:720
static void ConUnJetpack(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:320
CEventHandler m_Events
Definition: gamecontext.h:179
void OnInit(const void *pPersistentData) override
Definition: gamecontext.cpp:3838
static void ConDND(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:501
void ResetTuning()
Definition: gamecontext.cpp:4551
void OnPostSnap() override
Definition: gamecontext.cpp:4371
static void ConLoad(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:878
void ReadCensorList()
Definition: gamecontext.cpp:5000
void CensorMessage(char *pCensoredMessage, const char *pMessage, int Size)
Definition: gamecontext.cpp:2006
static void ConVotes(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3563
bool OnClientDDNetVersionKnown(int ClientId)
Definition: gamecontext.cpp:1806
static void ConGoDown(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:35
void TeehistorianRecordPlayerRejoin(int ClientId) override
Definition: gamecontext.cpp:1774
static void ConJoin(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1286
static void ConPracticeSolo(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2073
CClientMask ClientsMaskExcludeClientVersionAndHigher(int Version) const
Definition: gamecontext.cpp:4821
void CreateDeath(vec2 Pos, int ClientId, CClientMask Mask=CClientMask().set())
Definition: gamecontext.cpp:359
void OnKillNetMessage(const CNetMsg_Cl_Kill *pMsg, int ClientId)
Definition: gamecontext.cpp:2788
void OnMessage(int MsgId, CUnpacker *pUnpacker, int ClientId) override
Definition: gamecontext.cpp:2028
IServer * m_pServer
Definition: gamecontext.h:80
static void ConPracticeDeep(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2112
void UpdatePlayerMaps()
Definition: gamecontext.cpp:4377
CLog m_aLogs[MAX_LOGS]
Definition: gamecontext.h:578
static void ConPracticeLaser(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2156
static void ConPracticeToCheckTeleporter(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2025
CUuid GameUuid() const override
Definition: gamecontext.cpp:4448
static void ConConverse(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1336
static void ConMapInfo(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:558
static void ConToTeleporter(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:391
static void ConWeapons(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:296
CSaveTee * m_apSavedTees[MAX_CLIENTS]
Definition: gamecontext.h:185
bool EmulateBug(int Bug)
Definition: gamecontext.cpp:215
static void ConHotReload(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3211
static void ConClearVotes(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3447
void SendRecord(int ClientId)
Definition: gamecontext.cpp:4481
static void ConUnGrenade(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:308
static void ConPracticeUnSolo(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2045
static void ConUnLaser(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:314
void OnPreTickTeehistorian() override
Definition: gamecontext.cpp:995
void OnClientPredictedEarlyInput(int ClientId, void *pInput) override
Definition: gamecontext.cpp:1353
static void ConTeam0Mode(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1163
static void ConPracticeRemoveWeapon(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2275
void MoveCharacter(int ClientId, int X, int Y, bool Raw=false)
Definition: ddracecommands.cpp:73
bool IsSpecVote() const
Definition: gamecontext.h:598
static void ConTunes(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:2954
static void ConWhisper(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1341
CMute m_aMutes[MAX_MUTES]
Definition: gamecontext.h:548
bool m_Resetting
Definition: gamecontext.h:102
void SendChat(int ClientId, int Team, const char *pText, int SpamProtectionClientId=-1, int VersionFlags=FLAG_SIX|FLAG_SIXUP)
Definition: gamecontext.cpp:620
bool VoteUnmute(const NETADDR *pAddr, const char *pDisplayName, int AuthedId)
Definition: ddracecommands.cpp:527
static void ConUnDeep(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:221
static void ConPracticeUnNinja(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2240
static void ConSetTimerType(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1620
void OnSnap(int ClientId) override
Definition: gamecontext.cpp:4343
void OnConsoleInit() override
Definition: gamecontext.cpp:3615
void OnClientPrepareInput(int ClientId, void *pInput) override
Definition: gamecontext.cpp:1317
static void ConReloadCensorlist(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:914
void * PreProcessMsg(int *pMsgId, CUnpacker *pUnpacker, int ClientId)
Definition: gamecontext.cpp:1856
void Destruct(int Resetting)
Definition: gamecontext.cpp:127
static void ConRank(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:917
void ProgressVoteOptions(int ClientId)
Definition: gamecontext.cpp:1397
static void ConRemoveWeapon(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:348
static void ConBroadcast(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3146
static void ConPracticeNinja(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2233
int GetDDRaceTeam(int ClientId) const
Definition: gamecontext.cpp:4546
void OnCallVoteNetMessage(const CNetMsg_Cl_CallVote *pMsg, int ClientId)
Definition: gamecontext.cpp:2212
void TeehistorianRecordPlayerDrop(int ClientId, const char *pReason) override
Definition: gamecontext.cpp:1766
static void ConRandomUnfinishedMap(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3126
void AddVote(const char *pDescription, const char *pCommand)
Definition: gamecontext.cpp:3251
CUuid m_GameUuid
Definition: gamecontext.h:98
static void ConAddVote(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3242
static void ConTuneSetZoneMsgLeave(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3047
static void ConPracticeEndlessHook(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2247
void OnShowOthersLegacyNetMessage(const CNetMsg_Cl_ShowOthersLegacy *pMsg, int ClientId)
Definition: gamecontext.cpp:2557
void TeehistorianRecordTeamFinish(int TeamId, int TimeTicks) override
Definition: gamecontext.cpp:1798
static void ConPracticeShotgun(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2142
static void ConVoteMute(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:600
static void ConTimes(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:462
bool TryMute(const NETADDR *pAddr, int Secs, const char *pReason, bool InitialChatDelay)
Definition: ddracecommands.cpp:548
void SnapSwitchers(int SnappingClient)
Definition: gamecontext.cpp:423
static void ConPracticeUnDeep(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2101
static void ConSetTeam(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3177
bool RateLimitPlayerVote(int ClientId)
Definition: gamecontext.cpp:4854
void CreateExplosion(vec2 Pos, int Owner, int Weapon, bool NoDamage, int ActivatedTeam, CClientMask Mask=CClientMask().set())
Definition: gamecontext.cpp:291
void SendStartWarning(int ClientId, const char *pMessage)
Definition: gamecontext.cpp:702
CNetObj_PlayerInput GetLastPlayerInput(int ClientId) const
Definition: gamecontext.cpp:202
IEngine * Engine()
Definition: gamecontext.h:164
static void ConUnFreeze(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:201
static void ConFreezeHammer(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:844
ASYNCIO * m_pTeeHistorianFile
Definition: gamecontext.h:97
CPlayer * m_apPlayers[MAX_CLIENTS]
Definition: gamecontext.h:180
static void ConSpecTeam(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1509
static void ConLock(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:938
static void ConSwap(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:735
static void ConTuneParam(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:2869
int PersistentDataSize() const override
Definition: gamecontext.h:337
void CreateSoundGlobal(int Sound, int Target=-1) const
Definition: gamecontext.cpp:405
const char * Version() const override
Definition: gamecontext.cpp:4450
CSaveTee * m_apSavedTeleTees[MAX_CLIENTS]
Definition: gamecontext.h:186
static void ConInfo(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:66
static void ConSetTeamAll(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3197
static void ConchainSettingUpdate(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: gamecontext.cpp:3605
static void ConUnlock(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:987
IConfigManager * m_pConfigManager
Definition: gamecontext.h:81
static void ConPracticeCmdList(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:711
int m_VoteEnforce
Definition: gamecontext.h:218
static void ConVote(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3553
CScore * Score()
Definition: gamecontext.h:585
IServer * Server() const
Definition: gamecontext.h:160
void TeehistorianRecordPlayerFinish(int ClientId, int TimeTicks) override
Definition: gamecontext.cpp:1790
static void ConGoUp(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:45
void StartVote(const char *pDesc, const char *pCommand, const char *pReason, const char *pSixupDesc)
Definition: gamecontext.cpp:778
void CreateAllEntities(bool Initial)
Definition: gamecontext.cpp:4043
void LoadMapSettings()
Definition: gamecontext.cpp:4307
static void ConSetDDRTeam(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:810
CTuningParams m_aTuningList[NUM_TUNEZONES]
Definition: gamecontext.h:92
void SendVoteSet(int ClientId)
Definition: gamecontext.cpp:807
static void ConTuneResetZone(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3007
void RegisterChatCommands()
Definition: gamecontext.cpp:3738
void Clear()
Definition: gamecontext.cpp:168
const char * GameType() const override
Definition: gamecontext.cpp:4449
static void ConVoteMutes(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:643
int m_aTeamMapping[MAX_CLIENTS]
Definition: gamecontext.h:187
bool ProcessSpamProtection(int ClientId, bool RespectChatInitialDelay=true)
Definition: gamecontext.cpp:4494
CConfig * Config()
Definition: gamecontext.h:162
CTuningParams * TuningList()
Definition: gamecontext.h:168
static void ConPoints(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2301
CConfig * m_pConfig
Definition: gamecontext.h:82
static void ConReloadAnnouncement(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:920
static void ConPracticeToggleInvincible(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2261
static void ConTeamTop5(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:397
static void ConNinja(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:102
CCollision m_Collision
Definition: gamecontext.h:88
static void ConUnFreezeHammer(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:862
CMapBugs m_MapBugs
Definition: gamecontext.h:99
static void ConJetpack(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:272
void OnClientDirectInput(int ClientId, void *pInput) override
Definition: gamecontext.cpp:1324
CCharacter * GetPracticeCharacter(IConsole::IResult *pResult)
Definition: ddracechat.cpp:1984
bool IsOptionVote() const
Definition: gamecontext.h:596
void CallVote(int ClientId, const char *pDesc, const char *pCmd, const char *pReason, const char *pChatmsg, const char *pSixupDesc=0)
Definition: gamecontext.cpp:559
bool m_VoteUpdate
Definition: gamecontext.h:211
static void ConTogglePauseVoted(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:392
CGameContext()
Definition: gamecontext.cpp:153
void WhisperId(int ClientId, int VictimId, const char *pMessage)
Definition: gamecontext.cpp:4673
void OnShowDistanceNetMessage(const CNetMsg_Cl_ShowDistance *pMsg, int ClientId)
Definition: gamecontext.cpp:2575
int PersistentClientDataSize() const override
Definition: gamecontext.h:338
static void ConMuteIp(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:700
static void ConPracticeUnLaser(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2205
IConfigManager * ConfigManager() const
Definition: gamecontext.h:161
char m_aSixupVoteDescription[VOTE_DESC_LENGTH]
Definition: gamecontext.h:214
IAntibot * m_pAntibot
Definition: gamecontext.h:86
static void ConAddWeapon(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:342
static void ConRestart(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3137
static void ConTuneSetZoneMsgEnter(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3034
void CreateSound(vec2 Pos, int Sound, CClientMask Mask=CClientMask().set())
Definition: gamecontext.cpp:390
void Converse(int ClientId, char *pStr)
Definition: gamecontext.cpp:4750
static void ConSayTimeAll(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1573
char m_aVoteDescription[VOTE_DESC_LENGTH]
Definition: gamecontext.h:213
const char * NetVersion() const override
Definition: gamecontext.cpp:4451
static void ConToCheckTeleporter(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:407
std::vector< std::string > m_vCensorlist
Definition: gamecontext.h:93
void SendVoteStatus(int ClientId, int Total, int Yes, int No)
Definition: gamecontext.cpp:867
static void ConMute(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:669
static void ConShowOthers(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1458
uint32_t NextUniqueClientId
Definition: gamecontext.h:372
bool PlayerExists(int ClientId) const override
Definition: gamecontext.h:356
void OnShowOthersNetMessage(const CNetMsg_Cl_ShowOthers *pMsg, int ClientId)
Definition: gamecontext.cpp:2566
static void ConModerate(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:787
static void ConShowAll(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1481
void AbortVoteKickOnDisconnect(int ClientId)
Definition: gamecontext.cpp:893
static void ConTeleXY(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1825
int64_t m_NonEmptySince
Definition: gamecontext.h:352
static void ConSayTime(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1530
@ FLAG_SIXUP
Definition: gamecontext.h:259
@ FLAG_SIX
Definition: gamecontext.h:258
void OnClientConnected(int ClientId, void *pData) override
Definition: gamecontext.cpp:1662
static void ConForceVote(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3377
static void ConEndlessHook(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:114
static void ConVoteNo(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:879
void OnPreSnap() override
Definition: gamecontext.cpp:4370
void OnUpdatePlayerServerInfo(CJsonStringWriter *pJSonWriter, int Id) override
Definition: gamecontext.cpp:4941
static void ConRescueMode(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1707
protocol7::CNetObjHandler m_NetObjHandler7
Definition: gamecontext.h:89
static void ConLastTele(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1956
static void ConKill(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:454
static void CommandCallback(int ClientId, int FlagMask, const char *pCmd, IConsole::IResult *pResult, void *pUser)
Definition: gamecontext.cpp:193
IGameController * m_pController
Definition: gamecontext.h:193
IConsole * Console()
Definition: gamecontext.h:163
static void ConPracticeUnWeapons(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2226
std::shared_ptr< CScoreRandomMapResult > m_SqlRandomMapResult
Definition: gamecontext.h:368
bool RateLimitPlayerMapVote(int ClientId) const
Definition: gamecontext.cpp:4928
void OnClientEnter(int ClientId) override
Definition: gamecontext.cpp:1483
static void ConInvite(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1099
static void ConUnSuper(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:151
CLayers * Layers()
Definition: gamecontext.h:584
static int MapScan(const char *pName, int IsDir, int DirType, void *pUserData)
Definition: gamecontext.cpp:3537
static void ConPracticeUnJetpack(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2212
static void ConLiveFreeze(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:234
void OnChangeInfoNetMessage(const CNetMsg_Cl_ChangeInfo *pMsg, int ClientId)
Definition: gamecontext.cpp:2603
void CreateBirthdayEffect(vec2 Pos, CClientMask Mask=CClientMask().set())
Definition: gamecontext.cpp:370
void EndVote()
Definition: gamecontext.cpp:801
void TeehistorianRecordPlayerName(int ClientId, const char *pName) override
Definition: gamecontext.cpp:1782
int m_VotePos
Definition: gamecontext.h:212
bool m_TeeHistorianActive
Definition: gamecontext.h:95
static void ConToggleTuneParam(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:2903
@ VOTE_ENFORCE_NO
Definition: gamecontext.h:230
@ VOTE_ENFORCE_NO_ADMIN
Definition: gamecontext.h:232
@ VOTE_ENFORCE_YES_ADMIN
Definition: gamecontext.h:233
@ VOTE_ENFORCE_UNKNOWN
Definition: gamecontext.h:229
@ VOTE_ENFORCE_CANCEL
Definition: gamecontext.h:235
@ VOTE_ENFORCE_ABORT
Definition: gamecontext.h:234
@ VOTE_ENFORCE_YES
Definition: gamecontext.h:231
char m_aDeleteTempfile[128]
Definition: gamecontext.h:224
void Whisper(int ClientId, char *pStr)
Definition: gamecontext.cpp:4568
static void ConPracticeUnLiveFreeze(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2122
static void ConTopPoints(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2322
char m_aaZoneLeaveMsg[NUM_TUNEZONES][256]
Definition: gamecontext.h:220
static void ConTeleTo(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1764
void Construct(int Resetting)
Definition: gamecontext.cpp:77
static void ConPractice(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:614
static void ConSuper(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:138
static void ConUnmute(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:714
static void ConTeamRank(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:896
int m_VoteType
Definition: gamecontext.h:209
static void ConRandomMap(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3117
static void ConUnEndlessHook(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:126
IStorage * Storage()
Definition: gamecontext.h:165
static void ConMapbug(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3060
static void ConShotgun(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:254
static void ConToggleSpec(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:377
static void ConSwitchOpen(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3090
static void ConDeep(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:211
int m_VoteVictim
Definition: gamecontext.h:594
CPrng m_Prng
Definition: gamecontext.h:100
CSaveTeam * m_apSavedTeams[MAX_CLIENTS]
Definition: gamecontext.h:184
void OnVoteNetMessage(const CNetMsg_Cl_Vote *pMsg, int ClientId)
Definition: gamecontext.cpp:2461
static void ConSay(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3171
IEngine * m_pEngine
Definition: gamecontext.h:84
void CreateHammerHit(vec2 Pos, CClientMask Mask=CClientMask().set())
Definition: gamecontext.cpp:281
void SendBroadcast(const char *pText, int ClientId, bool IsImportant=true)
Definition: gamecontext.cpp:746
void List(int ClientId, const char *pFilter)
Definition: gamecontext.cpp:4775
bool m_VoteWillPass
Definition: gamecontext.h:373
bool TryVoteMute(const NETADDR *pAddr, int Secs, const char *pReason)
Definition: ddracecommands.cpp:483
int m_VoteCreator
Definition: gamecontext.h:208
int m_NumVoteOptions
Definition: gamecontext.h:217
CTuningParams * Tuning()
Definition: gamecontext.h:167
void CheckPureTuning()
Definition: gamecontext.cpp:900
void OnSetAuthed(int ClientId, int Level) override
Definition: gamecontext.cpp:4455
static void ConTimeout(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:574
void TeehistorianRecordAntibot(const void *pData, int DataSize) override
Definition: gamecontext.cpp:1750
static void ConPracticeUnShotgun(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2191
void SendChatTeam(int Team, const char *pText) const
Definition: gamecontext.cpp:613
static void ConTeleCursor(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1903
bool SnapLaserObject(const CSnapContext &Context, int SnapId, const vec2 &To, const vec2 &From, int StartTick, int Owner=-1, int LaserType=-1, int Subtype=-1, int SwitchNumber=-1) const
Definition: gamecontext.cpp:477
@ MAX_VOTE_MUTES
Definition: gamecontext.h:538
@ MAX_MUTES
Definition: gamecontext.h:537
static void ConSave(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:859
void SendSettings(int ClientId) const
Definition: gamecontext.cpp:734
const CVoteOptionServer * GetVoteOption(int Index) const
Definition: gamecontext.cpp:1384
static void ConTeleport(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:424
static void ConPracticeUnEndlessJump(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2219
void SendEmoticon(int ClientId, int Emoticon, int TargetClientId) const
Definition: gamecontext.cpp:712
static void ConTuneDumpZone(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:2990
int GetClientVersion(int ClientId) const
Definition: gamecontext.cpp:4816
static void ConProtectedKill(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2282
@ MAX_LOG_SECONDS
Definition: gamecontext.h:566
@ MAX_LOGS
Definition: gamecontext.h:567
static void ConKillPlayer(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:84
static void ConUnSolo(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:181
bool TeeHistorianActive() const
Definition: gamecontext.h:171
void UnlockTeam(int ClientId, int Team) const
Definition: ddracechat.cpp:1011
static void ConTop(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:443
@ VOTE_TYPE_SPECTATE
Definition: gamecontext.h:592
@ VOTE_TYPE_KICK
Definition: gamecontext.h:591
@ VOTE_TYPE_UNKNOWN
Definition: gamecontext.h:589
@ VOTE_TYPE_OPTION
Definition: gamecontext.h:590
static void ConMe(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1316
static void ConTime(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1597
static void ConFreeze(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:191
static void ConEndlessJump(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:280
void Mute(const NETADDR *pAddr, int Secs, const char *pDisplayName, const char *pReason="", bool InitialChatDelay=false)
Definition: ddracecommands.cpp:581
void OnShutdown(void *pPersistentData) override
Definition: gamecontext.cpp:4270
CNetObjHandler m_NetObjHandler
Definition: gamecontext.h:90
static void ConVoteUnmute(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:619
static void ConTuneReset(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:2927
static void ConMoveRaw(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:64
CTeeHistorian * TeeHistorian()
Definition: gamecontext.h:170
static void ConChangeMap(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3111
bool OnClientDataPersist(int ClientId, void *pData) override
Definition: gamecontext.cpp:1650
static void ConRemoveVote(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3308
static void ConCredits(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:18
static void ConList(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:85
char m_aVoteReason[VOTE_REASON_LENGTH]
Definition: gamecontext.h:216
int m_LatestLog
Definition: gamecontext.h:579
static void ConSolo(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:171
char m_aaZoneEnterMsg[NUM_TUNEZONES][256]
Definition: gamecontext.h:219
static void ConAddMapVotes(IConsole::IResult *pResult, void *pUserData)
Definition: gamecontext.cpp:3483
static void ConRescue(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:1672
bool IsClientReady(int ClientId) const override
Definition: gamecontext.cpp:4438
std::vector< SSwitchers > & Switchers()
Definition: gamecontext.h:199
static void ConUnShotgun(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:302
static void ConHelp(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:99
CVoteOptionServer * m_pVoteOptionFirst
Definition: gamecontext.h:238
static void ConUnLiveFreeze(IConsole::IResult *pResult, void *pUserData)
Definition: ddracecommands.cpp:244
static void ConPracticeAddWeapon(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:2268
bool IsClientPlayer(int ClientId) const override
Definition: gamecontext.cpp:4443
static void TeeHistorianWrite(const void *pData, int DataSize, void *pUser)
Definition: gamecontext.cpp:187
bool PlayerModerating() const
Definition: gamecontext.cpp:4833
void OnEmoticonNetMessage(const CNetMsg_Cl_Emoticon *pMsg, int ClientId)
Definition: gamecontext.cpp:2709
void FillAntibot(CAntibotRoundData *pData) override
Definition: gamecontext.cpp:220
class CCharacter * GetPlayerChar(int ClientId)
Definition: gamecontext.cpp:208
static void ConSettings(IConsole::IResult *pResult, void *pUserData)
Definition: ddracechat.cpp:138
void OnSetSpectatorModeNetMessage(const CNetMsg_Cl_SetSpectatorMode *pMsg, int ClientId)
Definition: gamecontext.cpp:2581
Definition: gameworld.h:17
CWorldCore m_Core
Definition: gameworld.h:34
Definition: jsonwriter.h:105
Definition: protocol.h:1261
Definition: teehistorian.h:16
Definition: gamecore.h:41
std::vector< SSwitchers > m_vSwitchers
Definition: gamecore.h:172
void(* FCommandCallback)(IResult *pResult, void *pUserData)
Definition: console.h:92
Definition: gamecontroller.h:19
Definition: protocol7.h:1229
std::bitset< MAX_CLIENTS > CClientMask
Definition: protocol.h:132
@ MAX_CLIENTS
Definition: protocol.h:88
@ MAX_NAME_LENGTH
Definition: protocol.h:97
@ NUM_TUNEZONES
Definition: gamecontext.h:46
Definition: system.cpp:452
Definition: antibot_data.h:98
Definition: gamecontext.h:570
char m_aClientName[MAX_NAME_LENGTH]
Definition: gamecontext.h:575
char m_aDescription[128]
Definition: gamecontext.h:573
bool m_FromServer
Definition: gamecontext.h:572
int64_t m_Timestamp
Definition: gamecontext.h:571
int m_ClientVersion
Definition: gamecontext.h:574
char m_aClientAddrStr[NETADDR_MAXSTRSIZE]
Definition: gamecontext.h:576
Definition: gamecontext.h:541
int m_Expire
Definition: gamecontext.h:543
char m_aReason[128]
Definition: gamecontext.h:544
NETADDR m_Addr
Definition: gamecontext.h:542
bool m_InitialChatDelay
Definition: gamecontext.h:545
Definition: gamecontext.h:154
bool m_IsSpectator
Definition: gamecontext.h:155
bool m_IsAfk
Definition: gamecontext.h:156
Definition: gamecontext.h:149
CUuid m_PrevGameUuid
Definition: gamecontext.h:150
Definition: protocol.h:1025
Definition: protocol.h:967
Definition: protocol.h:1001
Definition: protocol.h:1041
Definition: protocol.h:991
Definition: protocol.h:905
Definition: protocol.h:931
Definition: protocol.h:919
Definition: protocol.h:1125
Definition: protocol.h:1101
Definition: protocol.h:1139
Definition: protocol.h:943
Definition: protocol.h:1013
Definition: scoreworker.h:104
Definition: gamecontext.h:64
bool m_Sixup
Definition: gamecontext.h:75
int GetClientVersion() const
Definition: gamecontext.h:70
bool IsSixup() const
Definition: gamecontext.h:71
CSnapContext(int Version, bool Sixup=false)
Definition: gamecontext.h:65
int m_ClientVersion
Definition: gamecontext.h:74
Definition: uuid_manager.h:17
@ NETADDR_MAXSTRSIZE
Definition: types.h:45
@ VOTE_DESC_LENGTH
Definition: voting.h:8
@ VOTE_CMD_LENGTH
Definition: voting.h:9
@ VOTE_REASON_LENGTH
Definition: voting.h:10