I want to execute anti-cheat for admins
#1

Hello guys, I have this command and it's like a god mode that increases your health and armour to 9999, but the problem is that I got an anti-cheat that if your armour exceeds 96, you get automatically banned, but I don't want this to occur with administrators, so how can I make it to execute admins, so it doesn't ban admins. Here is the command
pawn Код:
CMD:3310(playerid, params[])
{
    if(pInfo[playerid][pAdminLevel] >= 6)
    {
        if(GetPVarType(playerid, "p3310Mode"))
        {
            DeletePVar(playerid, "p3310Mode");
            SetPlayerHealth(playerid, 100.0);
            SetPlayerArmour(playerid, 100.0);
            SendClientMessage(playerid, COL_3310GREEN, "Indestructible Nokia 3310 Mode Disabled");
        }
        else
        {
            SetPlayerHealth(playerid, 9999.9);
            SetPlayerArmour(playerid, 9999.9);
            SetPVarInt(playerid, "p3310Mode", 1);
            SendClientMessage(playerid, COL_3310RED, "Indestructible Nokia 3310 Mode Enabled");
        }
    }   else {
             PlayerPlaySound(playerid,1054,0.0,0.0,0.0),
             SendClientMessage(playerid,-1,""chat" Unknown command, try /help or /cmds");
    }return 1;
}
and here is the anti-cheat thingy for the armour hacking
pawn Код:
function OnServerUpdate()
{
    foreach(Player, i)
    {
        if(GetPlayerMoney(i) >= 1) return ResetPlayerMoney(i);
        SetPlayerScore(i,pInfo[i][pXP]);
        UpdateXPTextdraw(i);

        if(GetPlayerSpecialAction(i) == SPECIAL_ACTION_USEJETPACK)
        {
            new Admin[24] = "Anti-cheat";
            new reason3[128] = "Jetpack";
            BanPlayer(i,reason3,Admin);
        }

        new Float:armor;
        GetPlayerArmour(i,armor);
        if(armor >= 96)
        {
            new Admin[24] = "Anti-cheat";
            new reason3[128] = "Armour Hack (Exceeded over 96f)";
            BanPlayer(i,reason3,Admin);
        }
Thank you in advance.
Reply


Messages In This Thread
I want to execute anti-cheat for admins - by Red_Dragon. - 10.05.2013, 21:47
AW: I want to execute anti-cheat for admins - by HurtLocker - 10.05.2013, 21:50
Re : I want to execute anti-cheat for admins - by yusei - 10.05.2013, 21:59
Re: I want to execute anti-cheat for admins - by Red_Dragon. - 10.05.2013, 22:06
AW: I want to execute anti-cheat for admins - by HurtLocker - 10.05.2013, 22:12
Re: I want to execute anti-cheat for admins - by Onfroi - 10.05.2013, 22:18
Re: I want to execute anti-cheat for admins - by Red_Dragon. - 10.05.2013, 22:26
Re: I want to execute anti-cheat for admins - by Onfroi - 10.05.2013, 22:28
Re : I want to execute anti-cheat for admins - by yusei - 10.05.2013, 22:30

Forum Jump:


Users browsing this thread: 1 Guest(s)