|
|
|
@ -43,7 +43,9 @@ extern int g_teamplay;
@@ -43,7 +43,9 @@ extern int g_teamplay;
|
|
|
|
|
|
|
|
|
|
float g_flIntermissionStartTime = 0; |
|
|
|
|
|
|
|
|
|
#ifndef NO_VOICEGAMEMGR |
|
|
|
|
CVoiceGameMgr g_VoiceGameMgr; |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
class CMultiplayGameMgrHelper : public IVoiceGameMgrHelper |
|
|
|
|
{ |
|
|
|
@ -63,13 +65,16 @@ public:
@@ -63,13 +65,16 @@ public:
|
|
|
|
|
}; |
|
|
|
|
static CMultiplayGameMgrHelper g_GameMgrHelper; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//*********************************************************
|
|
|
|
|
// Rules for the half-life multiplayer game.
|
|
|
|
|
//*********************************************************
|
|
|
|
|
|
|
|
|
|
CHalfLifeMultiplay :: CHalfLifeMultiplay() |
|
|
|
|
{ |
|
|
|
|
#ifndef NO_VOICEGAMEMGR |
|
|
|
|
g_VoiceGameMgr.Init(&g_GameMgrHelper, gpGlobals->maxClients); |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
RefreshSkillData(); |
|
|
|
|
m_flIntermissionEndTime = 0; |
|
|
|
@ -116,8 +121,10 @@ CHalfLifeMultiplay :: CHalfLifeMultiplay()
@@ -116,8 +121,10 @@ CHalfLifeMultiplay :: CHalfLifeMultiplay()
|
|
|
|
|
|
|
|
|
|
BOOL CHalfLifeMultiplay::ClientCommand( CBasePlayer *pPlayer, const char *pcmd ) |
|
|
|
|
{ |
|
|
|
|
#ifndef NO_VOICEGAMEMGR |
|
|
|
|
if(g_VoiceGameMgr.ClientCommand(pPlayer, pcmd)) |
|
|
|
|
return TRUE; |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
return CGameRules::ClientCommand(pPlayer, pcmd); |
|
|
|
|
} |
|
|
|
@ -186,7 +193,9 @@ extern cvar_t mp_chattime;
@@ -186,7 +193,9 @@ extern cvar_t mp_chattime;
|
|
|
|
|
//=========================================================
|
|
|
|
|
void CHalfLifeMultiplay :: Think ( void ) |
|
|
|
|
{ |
|
|
|
|
#ifndef NO_VOICEGAMEMGR |
|
|
|
|
g_VoiceGameMgr.Update(gpGlobals->frametime); |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
///// Check game rules /////
|
|
|
|
|
static int last_frags; |
|
|
|
@ -397,7 +406,9 @@ BOOL CHalfLifeMultiplay :: GetNextBestWeapon( CBasePlayer *pPlayer, CBasePlayerI
@@ -397,7 +406,9 @@ BOOL CHalfLifeMultiplay :: GetNextBestWeapon( CBasePlayer *pPlayer, CBasePlayerI
|
|
|
|
|
//=========================================================
|
|
|
|
|
BOOL CHalfLifeMultiplay :: ClientConnected( edict_t *pEntity, const char *pszName, const char *pszAddress, char szRejectReason[ 128 ] ) |
|
|
|
|
{ |
|
|
|
|
#ifndef NO_VOICEGAMEMGR |
|
|
|
|
g_VoiceGameMgr.ClientConnected(pEntity); |
|
|
|
|
#endif |
|
|
|
|
return TRUE; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|