SA-MP Forums Archive
Anti mass Fakekill - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Anti mass Fakekill (/showthread.php?tid=482033)



Anti mass Fakekill - cuemur - 19.12.2013

I need newest anticheat to prevent players using Fakekill and killing whole server.


Re: Anti mass Fakekill - Pottus - 19.12.2013

Use the search there are plenty of scripts.


Respuesta: Anti mass Fakekill - Gryphus One - 19.12.2013

Try this:

pawn Код:
new stock bool:HasDied[MAX_PLAYERS];

public OnPlayerDeath(playerid, killerid,  reason)
{
    if(HasDied[playerid])
    {
        new string[128];
        GetPlayerName( playerid, string, sizeof(string) );
        format(string, sizeof(string), "%s (id: %i) has been kicked for fake kill cheat", string, playerid);
        SendClientMessageToAll(-1, string);
        print(string);
        Kick(playerid);
    }
    HasDied[playerid] = true;
    return 1;
}

public OnPlayerSpawn(playerid)
{
    HasDied[playerid] = false;
    return 1;
}