Ability to disable emotes. Closes #115

This commit is contained in:
GreYFoX 2011-11-08 14:04:57 +02:00
parent d6845f0502
commit 09232125b4
2 changed files with 6 additions and 1 deletions

View file

@ -125,7 +125,7 @@ MACRO_CONFIG_INT(SvPauseable, sv_pauseable, 1, 0, 1, CFGFLAG_SERVER, "Whether pl
MACRO_CONFIG_INT(SvPauseTime, sv_pause_time, 0, 0, 1, CFGFLAG_SERVER, "Whether '/pause' and 'sv_max_dc_restore' pauses the time of player or not")
MACRO_CONFIG_INT(SvPauseFrequency, sv_pause_frequency, 5, 0, 9999, CFGFLAG_SERVER, "The minimum allowed delay between pauses")
MACRO_CONFIG_INT(SvEmotionalTees, sv_emotional_tees, 1, 0, 1, CFGFLAG_SERVER, "Whether eye change of tees is enabled or not")
MACRO_CONFIG_INT(SvEmotionalTees, sv_emotional_tees, 1, -1, 1, CFGFLAG_SERVER, "Whether eye change of tees is enabled with emoticons = 1, not = 0, -1 not at all")
MACRO_CONFIG_INT(SvEmoticonDelay, sv_emoticon_delay, 3, 0, 9999, CFGFLAG_SERVER, "The time in seconds between over-head emoticons")

View file

@ -452,6 +452,11 @@ void CGameContext::ConToggleEyeEmote(IConsole::IResult *pResult, void *pUserData
void CGameContext::ConEyeEmote(IConsole::IResult *pResult, void *pUserData)
{
CGameContext *pSelf = (CGameContext *)pUserData;
if(g_Config.m_SvEmotionalTees == -1) {
pSelf->Console()->Print(IConsole::OUTPUT_LEVEL_STANDARD, "emote", "Server admin disabled emotes.");
return;
}
if(!CheckClientID(pResult->m_ClientID)) return;
CPlayer *pPlayer = pSelf->m_apPlayers[pResult->m_ClientID];