From 4a5c556e66d98a6941787d7e90d73b9fed38a524 Mon Sep 17 00:00:00 2001 From: jenz Date: Mon, 12 Feb 2024 22:57:28 +0100 Subject: [PATCH] fixed rare bug where guy in spectate would prevent zombies from spawning --- ZombieRiot/scripting/unloze_zr.sp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ZombieRiot/scripting/unloze_zr.sp b/ZombieRiot/scripting/unloze_zr.sp index ead7fc8b..ee0d3005 100644 --- a/ZombieRiot/scripting/unloze_zr.sp +++ b/ZombieRiot/scripting/unloze_zr.sp @@ -235,7 +235,8 @@ public void checkIfRestartNeeded() int activePlayers = 0; for (int i = 1; i < MaxClients; i++) { - if (!IsValidClient(i) || IsClientSourceTV(i)) + //if a guy sits in spec it does not restart the round. needed IsPlayerAlive. + if (!IsValidClient(i) || IsClientSourceTV(i) || !IsPlayerAlive(i)) { continue; }