From 23b1ab8b05f1ab9d81b44c2afb5a38b47b2b9431 Mon Sep 17 00:00:00 2001 From: s1lentq Date: Tue, 23 Aug 2016 14:09:21 +0700 Subject: [PATCH] Bugfix: a crash command `votemap` in case mapcycle is empty. Fix: typo with localized string. --- regamedll/dlls/multiplay_gamerules.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/regamedll/dlls/multiplay_gamerules.cpp b/regamedll/dlls/multiplay_gamerules.cpp index c96a6cc6..8f3685ab 100644 --- a/regamedll/dlls/multiplay_gamerules.cpp +++ b/regamedll/dlls/multiplay_gamerules.cpp @@ -3610,8 +3610,11 @@ void CHalfLifeMultiplay::__API_VHOOK(PlayerKilled)(CBasePlayer *pVictim, entvars if (autokick.value && killer->m_iTeamKills == 3) #endif { +#ifdef REGAMEDLL_FIXES + ClientPrint(killer->pev, HUD_PRINTCONSOLE, "#Banned_For_Killing_Teammates"); +#else ClientPrint(killer->pev, HUD_PRINTCONSOLE, "#Banned_For_Killing_Teamates"); - +#endif int iUserID = GETPLAYERUSERID(killer->edict()); if (iUserID != -1) { @@ -4439,6 +4442,9 @@ int GetMapCount() do { + if (!item) + break; + ++nCount; item = item->next; } while (item != mapcycle.next_item);