fixed dumb mistake i guess

This commit is contained in:
jenz 2023-01-30 11:03:00 +01:00
parent f4b2c416ba
commit ad01aee1b3

13
ZombieManager/scripting/ZombieManager.sp Normal file → Executable file
View File

@ -248,8 +248,6 @@ public Action ZR_OnClientMotherZombieEligible(int client)
bHasItem = EW_ClientHasItem(client); bHasItem = EW_ClientHasItem(client);
#endif #endif
if(GetClientIdleTime(client) > g_iAFKTime || IsFakeClient(client) || bHasItem || is_autism_bot(client))
{
if (is_autism_bot(client)) if (is_autism_bot(client))
{ {
int valid_humans = 0; int valid_humans = 0;
@ -260,17 +258,20 @@ public Action ZR_OnClientMotherZombieEligible(int client)
{ {
if (!IsValidClient(clienti) || !IsPlayerAlive(clienti) || is_autism_bot(clienti)) continue; if (!IsValidClient(clienti) || !IsPlayerAlive(clienti) || is_autism_bot(clienti)) continue;
valid_humans++; valid_humans++;
if (valid_humans / infection_count.IntValue > 2)
{
break;
}
} }
//if less than two mother zombies can spawn dont infect the bots. requested by william that the bots are considered when infecting //if less than two mother zombies can spawn dont infect the bots. requested by william that the bots are considered when infecting
if (valid_humans / infection_count.IntValue < 2) if (valid_humans / infection_count.IntValue < 2)
{
return Plugin_Handled;
}
else
{ {
return Plugin_Continue; return Plugin_Continue;
} }
} }
if(GetClientIdleTime(client) > g_iAFKTime || IsFakeClient(client) || bHasItem)
{
return Plugin_Handled; return Plugin_Handled;
} }
return Plugin_Continue; return Plugin_Continue;