Fixed mapchooser not checking for an existing vote with mp_fraglimit (bug 3503)

This commit is contained in:
Matt Woodrow 2009-02-19 20:35:41 +13:00
parent 792204bd06
commit 10ba5809d2

View File

@ -469,8 +469,19 @@ public Event_PlayerDeath(Handle:event, const String:name[], bool:dontBroadcast)
return;
}
if (g_MapVoteCompleted)
{
return;
}
new fragger = GetClientOfUserId(GetEventInt(event, "attacker"));
if (fragger && GetClientFrags(fragger) >= (GetConVarInt(g_Cvar_Fraglimit) - GetConVarInt(g_Cvar_StartFrags)))
if (!fragger)
{
return;
}
if (GetClientFrags(fragger) >= (GetConVarInt(g_Cvar_Fraglimit) - GetConVarInt(g_Cvar_StartFrags)))
{
InitiateVote(MapChange_MapEnd, INVALID_HANDLE);
}