Hello need help with anti cheat
#1

PHP код:
new Float:animX, Float:animY, Float:animZ;
new 
aNim = GetPlayerAnimationIndex(playerid);
GetPlayerPos(playerid, animX, animY, animZ);
if(!
IsPlayerInWater(playerid))
{    if((
aNim >= 1538) && (aNim <= 1542) && animZ > 5)
    {
    
Player[playerid][pBan]=1;
    
SendClientMessage(playerid, COLOR_YELLOW, "You have been banned from the server. Reason: Sobiet Fly Hack");
    
format(pstring, 128, "Hitler : %s has been banned from the server. Reason: Sobiet Fly Hack", GetName(playerid));
    
SendClientMessageToAll(COLOR_KRED, pstring);
    
SaveIn("BanLog.txt",pstring);
    
SetTimerEx("KickPlayer",1000/2,false,"d", playerid);
}
    return 
1;
}
stock IsPlayerInWater(playerid) {
        new 
anim = GetPlayerAnimationIndex(playerid);
        if (((
anim >=  1538) && (anim <= 1542)) || (anim == 1544) || (anim == 1250) || (anim == 1062)) return 1;
        return 
0;
} 
HELP ME ITS NOT WORKING
Reply
#2

what happens when you compile?
Reply
#3

no error but it not detect cheat
Reply
#4

Have you tried to use GetPlayerVelocity? if I'm not mistaken, you can't really define a certain aspect of water :/
Reply
#5

Can u explain that dude!!
Reply
#6

https://sampwiki.blast.hk/wiki/GetPlayerVelocity <---- if I'm not mistaken, people that use ****** go faster than a normal player, so this could catch them out easily
Reply


Forum Jump:


Users browsing this thread: