Making Admins Invulnerable To AntiCheat?
#1

How to make admins not get banned by this anti airbreak? Cause i have a /boost command for admins were they can speed up there car and jump it which can make them get kicked falsely.

Heres the thing my admin system use to check the players level



pawn Код:
if(pInfo[playerid][pLevel] >= 1)
    {
And this is the script

pawn Код:
public antiairbrk(playerid)
{
    new Float:xt,Float:yt,Float:zt;
    GetPlayerPos(playerid,xt,yt,zt);
    if(!IsPlayerInAirPlane(playerid))
    {
        if(xo[playerid] != 0.0 || yo[playerid] != 0.0 || zo[playerid] != 0.0)
        {
            new Float:xs,Float:ys,Float:zs;
            xs = GetPlayerMoveCount(xo[playerid],xt);
            ys = GetPlayerMoveCount(yo[playerid],yt);
            zs = GetPlayerMoveCount(zo[playerid],zt);
            if(xs >= 16.5 || ys >= 16.5 || zs >= 16.5)
            {
                if(xs <= 50.0)
                {
                    SendClientMessage(playerid,RED,"[GAIB] You Have Kicked for using AirBrake!!!");
                    new name[255];
                    GetPlayerName(playerid,name,sizeof(name));
                    new out[800];
                    format(out,sizeof(out),"[GAIB] Player %s has been kicked for using AirBrake!!!",name);
                    SendClientMessageToAll(RED,out);
                    Kick(playerid);
                }
            }
        }
    }
    GetPlayerPos(playerid,xo[playerid],yo[playerid],zo[playerid]);
    return 1;
}
Please I really need help with this!
Reply
#2

Add
pawn Код:
if (pInfo[playerid][pLevel] == 0)
before
pawn Код:
if (!IsPlayerInAirPlane(playerid))
This should work. It will check if the player is a normal player (not admin), then kick or take any action.
Reply
#3

Thats not banning btw try this:
pawn Код:
public antiairbrk(playerid)
{
    new Float:xt,Float:yt,Float:zt;
    GetPlayerPos(playerid,xt,yt,zt);
    if(!IsPlayerInAirPlane(playerid))
    {
        if(xo[playerid] != 0.0 || yo[playerid] != 0.0 || zo[playerid] != 0.0)
        {
            new Float:xs,Float:ys,Float:zs;
            xs = GetPlayerMoveCount(xo[playerid],xt);
            ys = GetPlayerMoveCount(yo[playerid],yt);
            zs = GetPlayerMoveCount(zo[playerid],zt);
            if(xs >= 16.5 || ys >= 16.5 || zs >= 16.5)
            {
                if(xs <= 50.0 && !PlayerInfo[playerid][pAdmin])
                {
                    SendClientMessage(playerid,RED,"[GAIB] You Have Kicked for using AirBrake!!!");
                    new name[255];
                    GetPlayerName(playerid,name,sizeof(name));
                    new out[800];
                    format(out,sizeof(out),"[GAIB] Player %s has been kicked for using AirBrake!!!",name);
                    SendClientMessageToAll(RED,out);
                    Kick(playerid);
                }
            }
        }
    }
    GetPlayerPos(playerid,xo[playerid],yo[playerid],zo[playerid]);
    return 1;
}
Should work, it will check if the player is admin and only kick/ban players.
Reply
#4

^ That doesnt work.
Reply
#5

pawn Код:
public antiairbrk(playerid)
{
    new Float:xt,Float:yt,Float:zt;
    GetPlayerPos(playerid,xt,yt,zt);
    if(!IsPlayerInAirPlane(playerid))
    {
        if(xo[playerid] != 0.0 || yo[playerid] != 0.0 || zo[playerid] != 0.0)
        {
            new Float:xs,Float:ys,Float:zs;
            xs = GetPlayerMoveCount(xo[playerid],xt);
            ys = GetPlayerMoveCount(yo[playerid],yt);
            zs = GetPlayerMoveCount(zo[playerid],zt);
            if(xs >= 16.5 || ys >= 16.5 || zs >= 16.5)
            {
                if(xs <= 50.0)
                {
                    if(PlayerInfo[playerid][pLevel]<1)
                    {
                       SendClientMessage(playerid,RED,"[GAIB] You Have Kicked for using AirBrake!!!");
                       new name[255];
                       GetPlayerName(playerid,name,sizeof(name));
                       new out[800];
                       format(out,sizeof(out),"[GAIB] Player %s has been kicked for using AirBrake!!!",name);
                       SendClientMessageToAll(RED,out);
                       Kick(playerid);
                   }
                }
            }
        }
    }
    GetPlayerPos(playerid,xo[playerid],yo[playerid],zo[playerid]);
    return 1;
}
Also let me know what is the level or what denotes normal player? and is [pLevel] == 1 too admin?
EDITED.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)