From c066f13b27fed5b02d6128588f8ecd71c40d15f8 Mon Sep 17 00:00:00 2001 From: Cedric Mercier Date: Tue, 6 Oct 2026 16:36:11 +0200 Subject: [PATCH] fix: ignore clients not in game in OnClientDisconnect VIP_IsClientVIP throws a native error ('Client N is not connected') when the client never reached in-game state, flooding the logs. --- addons/sourcemod/scripting/VIP_FreeVIPGiveaway.sp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/sourcemod/scripting/VIP_FreeVIPGiveaway.sp b/addons/sourcemod/scripting/VIP_FreeVIPGiveaway.sp index 6a47988..f935cfc 100644 --- a/addons/sourcemod/scripting/VIP_FreeVIPGiveaway.sp +++ b/addons/sourcemod/scripting/VIP_FreeVIPGiveaway.sp @@ -32,7 +32,7 @@ public Plugin myinfo = name = "[VIP] Free VIP Giveaway", author = "inGame, maxime1907, Dolly", description = "Gives Free VIP for players that are active on server", - version = "2.1" + version = "2.1.1" }; public void OnPluginStart() @@ -266,7 +266,7 @@ void SetVIP(int client) public void OnClientDisconnect(int client) { - if(IsClientSourceTV(client) || IsFakeClient(client)) + if(!IsClientInGame(client) || IsClientSourceTV(client) || IsFakeClient(client)) return; char testVipGroup[16];