View Single Post
Neuro Toxin
Veteran Member
Join Date: Oct 2013
Location: { closing the void; }
Old 06-02-2015 , 21:54   Re: [CS:GO] Knives 1.0.0
Reply With Quote #7

Code:
public void OnConfigsExecuted()
{
    int hookedcount = 0;

    // Late loading here is the best place
    for (int client = 1; client < MaxClients; client++)
    {
        if (!IsClientConnected(client))
            continue;
            
        OnClientConnected(client);
        
        if (!IsClientInGame(client))
            continue;
            
        OnClientPutInServer(client);
        hookedcount++;
    }
    
    PrintToChatAll("\x01[SM] \x04%d clients have been hooked!", hookedcount); 
}
PrintToChatAll always shows the correct number of clients being hooked on late load
__________________
Neuro Toxin is offline