Why not just?
Code:
#include <sourcemod>
#pragma semicolon 1
bool Ready;
public void OnPluginStart()
{
HookEvent( "player_disconnect", Event_Disconnect, EventHookMode_Pre);
RegConsoleCmd("sm_ready", Cmd_Ready);
}
public Action Cmd_Ready(int client, int args)
{
Ready = true;
}
public Action Event_Disconnect(Event event, const char[] name, bool dbc)
{
new client = GetClientOfUserId(GetEventInt(event, "userid"));
if (Ready)
{
Ready = false;
return;
}
BanClient(client, 1440, BANFLAG_AUTO, "some shit here");
}