[Include] Nex-AC - Anticheat system

Nice !
Reply

New Version v1.9.15
Changes:
* Anti-parkour mod and anti-fake NPC is now disabled by default

Fixes:
* Fixed a bug in the protection against NOP RemovePlayerFromVehicle

Download: See the first post
Reply

New Version v1.9.16
Fixes:
* Tweaked SetPlayerPos, SetPlayerPosFindZ and SetVehiclePos functions

Download: See the first post
Reply

Hello!
After long investigation I found how to reconcile shoebill and nex-ac
I found in your code following:

PHP код:
ac_fpublic ac_AntiCheatGetAnimationIndex(playerid) return ACInfo[playerid][acAnim];
ac_fpublic ac_AntiCheatGetDialog(playerid) return ACInfo[playerid][acDialog];
ac_fpublic ac_AntiCheatGetMoney(playerid) return ACInfo[playerid][acMoney];
ac_fpublic ac_AntiCheatGetClass(playerid) return ACInfo[playerid][acClassid];
ac_fpublic ac_AntiCheatGetEnterVehicle(playerid) return ACInfo[playerid][acEnterVeh]; 
If your code can get all variables via API I can implement shoebill function to fill your parameters.
In other words, every time when you are going to hook any event you should take data not from enum directly but from function (you have almost done this as far as I see). And add this data getters into a separate file, so I can overwrite it.
Reply

There is an issue with textdraw in the latest version of anti-cheat.
I can't select my menu
Reply

****** by SlonoBoyko 24.11.2016 - this cheat is transparent for Nex-AC versions: 1.16-1.9
(tried pure nex-ac without any gamemode)
UPD: sorry everything with this cheat is ok
Reply

Quote:
Originally Posted by diclofoss
Посмотреть сообщение
If your code can get all variables via API I can implement shoebill function to fill your parameters.
In other words, every time when you are going to hook any event you should take data not from enum directly but from function (you have almost done this as far as I see). And add this data getters into a separate file, so I can overwrite it.
What functions are still causing problems and what functions also would be necessary to rewrite?

Quote:
Originally Posted by diclofoss
Посмотреть сообщение
There is an issue with textdraw in the latest version of anti-cheat.
I can't select my menu
So I checked it with my dialogs that use textdraws (video)
As you can see it works. At the end I was flooding in order to show that anticheat is connected and all anti-cheat codes are enabled
Reply

Finally I found a workaround for shoebill project
I need to override OnCheadDetected variable and controll everything on Shoebill side.
Hope somebody helps this.
Reply

Quote:
Originally Posted by OstGot
Посмотреть сообщение
What functions are still causing problems and what functions also would be necessary to rewrite?

For now I find good solution for me. I use only physical calculation on NEX-AC side, and controll all flags on the shoebill side. So problem is closed. Sorry for disturbing and thank you for your support

So I checked it with my dialogs that use textdraws (video)
As you can see it works. At the end I was flooding in order to show that anticheat is connected and all anti-cheat codes are enabled
Maybe the root cause the same: I create my textdraw directly with GDK
Reply

Just want to say again than you so much for your job.
I wish you all the best.
Reply

PHP код:
public OnCheatDetected(playeridip_address[], typecode)
 
Called when the tripped one of the anti-cheats
 playerid 
ID of the cheater
 ip_address
[] - IP-address of the cheater
 type 
Type of cheating (when 0 it returns the IDwhen 1 IP)
 
code Code (IDof the anti-cheat 
how to use these only for money hack ?
plz show me an example ??
Reply

Quote:
Originally Posted by bugmenotlol
Посмотреть сообщение
PHP код:
public OnCheatDetected(playeridip_address[], typecode)
 
Called when the tripped one of the anti-cheats
 playerid 
ID of the cheater
 ip_address
[] - IP-address of the cheater
 type 
Type of cheating (when 0 it returns the IDwhen 1 IP)
 
code Code (IDof the anti-cheat 
how to use these only for money hack ?
plz show me an example ??
PHP код:
forward OnCheatDetected(playeridip_address[], typecode);
public 
OnCheatDetected(playeridip_address[], typecode)
{
    if(
typeBlockIpAddress(ip_address0); //Responded to IP (for example for rcon brute) - block him
    
else //Responded to the player ID
    
{
        switch(
code//What cheat code?
        
{
            case 
5: return 1//Teleport unoccupied cars (ac in any case will return it to its original pos, the punishment shouldn't do)
            
case 11//Repair car, it is better to return the old hp (if cheater will not set old hp - anti-nop will detect him)
            
{
                new 
vehid GetPlayerVehicleID(playerid), Float:vhealth;
                
AntiCheatGetVehicleHealth(vehidvhealth);
                
SetVehicleHealth(vehidvhealth);
                return 
1;
            }
            case 
14//Money
            
{
                
//Here is your code
                /*
                //Return the old money
                new a = AntiCheatGetMoney(playerid);
                ResetPlayerMoney(playerid);
                GivePlayerMoney(playerid, a);
                return 1; //We don't need another punishment
                */
            
}
            case 
32: return ClearAnimations(playerid1); //CarJack, remove player from vehicle
            
case 40SendClientMessage(playerid, -1MAX_CONNECTS_MSG); //Sandbox (connect 2 or more people from the same IP), say goodbye
            
case 41SendClientMessage(playerid, -1UNKNOWN_CLIENT_MSG); //Unknown client version, say goodbye to him
            
case 43..47//Crashers
            
{
                
Kick(playerid); //It is HIGHLY recommended to kick without delay, otherwise IT will have time to crash players
                
return 1;
            }
            default: 
//All others cheats
            
{
                static 
strtmp[sizeof KICK_MSG];
                
format(strtmpsizeof strtmpKICK_MSGcode); //Another way to say goodbye
                
SendClientMessage(playerid, -1strtmp);
            }
        }
        new 
pPing GetPlayerPing(playerid) + 150;
        
SetTimerEx("ac_KickTimer", (pPing 500 500 pPing), false"i"playerid); //ac_KickTimer is already in anticheat and successfully will be called
    
}
    return 
1;

Reply

Quote:
Originally Posted by OstGot
Посмотреть сообщение
PHP код:
forward OnCheatDetected(playeridip_address[], typecode);
public 
OnCheatDetected(playeridip_address[], typecode)
{
    if(
typeBlockIpAddress(ip_address0); //Responded to IP (for example for rcon brute) - block him
    
else //Responded to the player ID
    
{
        switch(
code//What cheat code?
        
{
            case 
5: return 1//Teleport unoccupied cars (ac in any case will return it to its original pos, the punishment shouldn't do)
            
case 11//Repair car, it is better to return the old hp (if cheater will not set old hp - anti-nop will detect him)
            
{
                new 
vehid GetPlayerVehicleID(playerid), Float:vhealth;
                
AntiCheatGetVehicleHealth(vehidvhealth);
                
SetVehicleHealth(vehidvhealth);
                return 
1;
            }
            case 
14//Money
            
{
                
//Here is your code
                /*
                //Return the old money
                new a = AntiCheatGetMoney(playerid);
                ResetPlayerMoney(playerid);
                GivePlayerMoney(playerid, a);
                return 1; //We don't need another punishment
                */
            
}
            case 
32: return ClearAnimations(playerid1); //CarJack, remove player from vehicle
            
case 40SendClientMessage(playerid, -1MAX_CONNECTS_MSG); //Sandbox (connect 2 or more people from the same IP), say goodbye
            
case 41SendClientMessage(playerid, -1UNKNOWN_CLIENT_MSG); //Unknown client version, say goodbye to him
            
case 43..47//Crashers
            
{
                
Kick(playerid); //It is HIGHLY recommended to kick without delay, otherwise IT will have time to crash players
                
return 1;
            }
            default: 
//All others cheats
            
{
                static 
strtmp[sizeof KICK_MSG];
                
format(strtmpsizeof strtmpKICK_MSGcode); //Another way to say goodbye
                
SendClientMessage(playerid, -1strtmp);
            }
        }
        new 
pPing GetPlayerPing(playerid) + 150;
        
SetTimerEx("ac_KickTimer", (pPing 500 500 pPing), false"i"playerid); //ac_KickTimer is already in anticheat and successfully will be called
    
}
    return 
1;

SO we can Add banningSystem under this ?
Код:
GivePlayerMoney(playerid, a);
return 1; //We don't need another punishment
Reply

Quote:
Originally Posted by bugmenotlol
Посмотреть сообщение
SO we can Add banningSystem under this ?
Код:
GivePlayerMoney(playerid, a);
return 1; //We don't need another punishment
No, would be better to just have serverside money (stored in player statistics).
Reply

When PLAYER1 is spectating PLAYER2 and PLAYER2 gets kicked for whatever reason (in this case hacks) then PLAYER1 will be kicked out of the server (this line reacts even anticheats are off);
Quote:

default: //All others cheats
{
static strtmp[sizeof KICK_MSG];
format(strtmp, sizeof strtmp, KICK_MSG, code); //Another way to say goodbye
SendClientMessage(playerid, -1, strtmp);
}

How can I fix that?
Reply

Quote:
Originally Posted by Juonis
Посмотреть сообщение
When PLAYER1 is spectating PLAYER2 and PLAYER2 gets kicked for whatever reason (in this case hacks) then PLAYER1 will be kicked out of the server (this line reacts even anticheats are off);



How can I fix that?
If you are using in your gm public OnCheatDetected, you can add to switch the following case:
PHP код:
case 21: return 1//Unless, of course, triggered exactly code 21? 
Although better if you describe your problem specifically. For example, what writes to the console at the time of kick?
Reply

Quote:
Originally Posted by OstGot
Посмотреть сообщение
If you are using in your gm public OnCheatDetected, you can add to switch the following case:
PHP код:
[B]case 21: return 1//Unless, of course, triggered exactly code 21?[/B] 
Although better if you describe your problem specifically. For example, what writes to the console at the time of kick?
Thanks this helped. Also if player takes guns from pickup in server he/she gets kicked, can I turn off all the 'anticheats' for specific period of time, what should I do to prevent kicking player for taking guns from pickup? Players for taking guns using a pickup are kicked with "add ammo" anticheat.
Also innocent players are kicked for NOP even though they are not cheating; when player enter a vehicle and then leaves (not always, sometimes).

Also if you are using shotgun and switch to AK or M4 and shoot (with a short period of time) you will be punished for rapid.


So, how do I give weapons in order not to be kicked? I am using GetPlayerWeaponEx now.
Reply

Quote:
Originally Posted by Juonis
Посмотреть сообщение
Thanks this helped. Also if player takes guns from pickup in server he/she gets kicked, can I turn off all the 'anticheats' for specific period of time, what should I do to prevent kicking player for taking guns from pickup? Players for taking guns using a pickup are kicked with "add ammo" anticheat.
Also innocent players are kicked for NOP even though they are not cheating; when player enter a vehicle and then leaves (not always, sometimes).

Also if you are using shotgun and switch to AK or M4 and shoot (with a short period of time) you will be punished for rapid.


So, how do I give weapons in order not to be kicked? I am using GetPlayerWeaponEx now.
About pickups and entering vehicles: may you show me the server log with kick messages in that period in debug mode?
You also can use "EnableAntiCheatForPlayer" function to enable or disable specifically anti-cheat code for player, just use it when you want to disable it and after some time enable it again, if you want.
As about rapid fire, I tested it, but unfortunately didn't saw anything


New Version v1.9.17
Changes:
* Added check for the validity of the pickup when a player picks it up
* Increased the minimum distance of detection AirBreak onfoot

Fixes:
* Fixed anti-CJ run with a kick for landing on parachute (holding 'S' key)
* Fixed anti-FlyHack with parachutist animation

Download: See the first post
Reply

Can you help me how to fix?
http://imgur.com/a/taqg6
Reply

Why don't you use Git properly? You create a ton of folders for each version of the include. You are using GitHub, but you aren't using Git version control, that does exactly what you want, but better in visual and organization. We can't see exaclty what you modified in each version, not without wasting time checking every file or putting them in an online text diff (which can't detect all diffs). You can use "release" feature to manage releases.
And... look at this:

We have to find the latest version.

Don't get me wrong, I'm just trying to help you help the users.
This is a huge anti-cheater lib, thanks for share. Maybe I use it.
Reply


Forum Jump:


Users browsing this thread: 30 Guest(s)