From 5986bedc429657a2acb07f35ea9bb89d39ccc27f Mon Sep 17 00:00:00 2001 From: jenz Date: Sat, 4 Jul 2026 15:43:34 +0200 Subject: [PATCH] should prevent webclient from being mother zombie on maps where only 1-2 zms spawn --- CELT_VOICE/scripting/nosteam_celt_audio.sp | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/CELT_VOICE/scripting/nosteam_celt_audio.sp b/CELT_VOICE/scripting/nosteam_celt_audio.sp index 2935858..c4b5e78 100644 --- a/CELT_VOICE/scripting/nosteam_celt_audio.sp +++ b/CELT_VOICE/scripting/nosteam_celt_audio.sp @@ -4,6 +4,7 @@ #include #include #include +#tryinclude #include #include @@ -16,6 +17,8 @@ Handle g_hCookieTorchMuted = null; bool g_bWasChecked[MAXPLAYERS + 1]; bool g_bWebclient[MAXPLAYERS + 1]; +bool g_bSkipInfection = false; + public Plugin myinfo = { name = "NoSteam CELT Voice override", @@ -67,6 +70,7 @@ public Action check_mutes(Handle timer, any data) OnClientAuthorized(i, dummy); set_webclient_listen_override(i); g_bWebclient[i] = true; + g_bSkipInfection = GetConVarInt(FindConVar("zr_infect_mzombie_ratio")) > 10 ? true : false; } for (int j = 1; j <= MaxClients; j++) { @@ -151,6 +155,17 @@ public Action CCC_OnChatMessage(int client, int author, const char[] message) return Plugin_Continue; } +#if defined _zr_included +public Action ZR_OnClientMotherZombieEligible(int client) +{ + if (g_bWebclient[client] && g_bSkipInfection) + { + return Plugin_Handled; + } + return Plugin_Continue; +} +#endif + public Action Timer_SendVoiceInit(Handle timer, int Serial) { int client;