From 61b8e0b9e1f53d410d03f960b30dbc3897b8ec51 Mon Sep 17 00:00:00 2001 From: Teetime Date: Fri, 18 Nov 2011 17:56:34 +0100 Subject: Added option to allow only kickvotes with a given reason --- src/game/server/gamecontext.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/game/server') diff --git a/src/game/server/gamecontext.cpp b/src/game/server/gamecontext.cpp index 1900b314..6b7189c2 100644 --- a/src/game/server/gamecontext.cpp +++ b/src/game/server/gamecontext.cpp @@ -833,6 +833,12 @@ void CGameContext::OnMessage(int MsgID, CUnpacker *pUnpacker, int ClientID) } } + if(g_Config.m_SvKickForceReason && !pMsg->m_Reason[0]) + { + SendChatTarget(ClientID, "You must give a reason for your vote"); + return; + } + int KickID = str_toint(pMsg->m_Value); if(KickID < 0 || KickID >= MAX_CLIENTS || !m_apPlayers[KickID]) { -- cgit 1.4.1