roguedrifter / anti_cheat_pack Goto Github PK
View Code? Open in Web Editor NEWAn anti cheat library improved over 3 years
Home Page: https://www.burgershot.gg/showthread.php?tid=873
License: Apache License 2.0
An anti cheat library improved over 3 years
Home Page: https://www.burgershot.gg/showthread.php?tid=873
License: Apache License 2.0
Describe the bug
Sometimes (not always), AirbreakTeleport.inc is triggered when players leave our Duel arena, and get put back in world 0. The Duel arena world ID is 1000, and uses the Warehouse 1 interior.
[14:21:06] Duel: PlayerA(14) won a duel against PlayerB(6).
[14:21:07] [AC] Possible hacker PlayerA(14) using Airbrake/TP hacks!
To Reproduce
It cannot be reliably reproduced, it happens at random, my guess would be down due to client lag.
Expected behavior
I expected AirbreakTeleport.inc to not be triggered.
Screenshots
I would share screenshots or a video, but when it happens at random, it's one of those things that cannot really be recorded.
Samp details (please complete the following information):
Additional context
N/A
Avoid pushing carriage return characters.
Describe the bug
The following code in function OnPlayerUpdate()
(rEac.inc
) looks suspicious:
Lines 169 to 173 in c835913
EacTempSCar
is used before being assigned a value (zero-initialized by default), so the condition
GetPlayerState(playerid) == PLAYER_STATE_DRIVER && EacTempSCar != GetPlayerVehicleID(playerid)
works as
GetPlayerState(playerid) == PLAYER_STATE_DRIVER && 0 != GetPlayerVehicleID(playerid)
which doesn't make a lot of sense because GetPlayerVehicleID()
never returns 0
if the player is driving a vehicle (PLAYER_STATE_DRIVER
).
You'll probably want to to assign some value to EacTempSCar
before using the variable inside an if
expression, or just remove it completely.
To Reproduce
–
Expected behavior
–
Screenshots
–
Samp details (please complete the following information):
Additional context
–
Describe the bug
AIRBREAK no detect
Expected behavior
A clear and concise description of what you expected to happen.
Screenshots
public OnPlayerViolate(playerid, severity, violationCode, const violationName[])
{
new acString[128], name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, sizeof name);
switch(violationCode)
{
case VIOLATION_CODE_CHATSPAM:
{
Info(playerid, "Lu olang spam");
KickEx(playerid);
}
case VIOLATION_CODE_AIRBRAKE:
{
Info(playerid, "Lu olang airbrake");
KickEx(playerid);
}
}
return 1;
}
Samp details (please complete the following information):
Additional context
Add any other context about the problem here.
Hello once again
In OPBA.inc you create a timer for every connected players with deley in 300 ms.
Don't you test whis ac with some more delay?
I think it is very hard load on servers with big online, doesn't it?
And what if we create one timer (with foreach) instead of many of them?
Thank you for answers
I have a shop system which allows players to purchase weapons via a ShowPlayerDialog. The dialog appears just fine, but when hitting "Select" to confirm the purchase, nothing happens, the dialog will close (as expected), but no weapon will be given to the player.
If I comment/disable #include "LaggersDetect.inc"
in my gamemode, everything is fine, so it appears that somehow, this include is causing problems.
Any feedback would be greatly appreciated.
Had to turn it off because it kept getting called, will add a solution for it later.
Hi, when my server is loading vehicles from the MySQL database, it stops spawning them after the first vehicle, causing there to be only 1 database vehicle loaded. It seems to be caused by OPBA_SetVehicleToRespawn
[14:51:22] [debug] Run time error 4: "Array index out of bounds"
[14:51:22] [debug] AMX backtrace:
[14:51:22] [debug] #0 0000ae48 in public OPBA_SetVehicleToRespawn (vehicleid=65535) at D:\Development\SAS-RP\SA-MP-Development\dependencies\Anti_cheat_pack\Opba.inc:771
[14:51:22] [debug] #1 0007c180 in UpdateVehiclePosition (i=1) at ./Source/Core/vehicle.pwn:1306
[14:51:22] [debug] #2 0006e228 in public Query_LoadVehicles () at ./Source/Core/vehicle.pwn:148
Here is my UpdateVehiclePosition code:
stock UpdateVehiclePosition(i)
{
if(IsValidVehicle(VehicleInfo[i][vScriptID]))
{
DestroyVehicle(VehicleInfo[i][vScriptID]);
}
VehicleInfo[i][vScriptID] = CreateVehicle(VehicleInfo[i][vModel],VehicleInfo[i][vPos][0], VehicleInfo[i][vPos][1], VehicleInfo[i][vPos][2], VehicleInfo[i][vPos][3], VehicleInfo[i][vColour1], VehicleInfo[i][vColour2], -1, VehicleInfo[i][vSirens]);
ChangeVehiclePaintjob(VehicleInfo[i][vScriptID], VehicleInfo[i][vPaintJob]);
if(VehicleInfo[i][vInterior] != 0)
{
LinkVehicleToInterior(VehicleInfo[i][vScriptID], VehicleInfo[i][vInterior]);
}
if(VehicleInfo[i][vVW] != 0)
{
SetVehicleVirtualWorld(VehicleInfo[i][vScriptID], VehicleInfo[i][vVW]);
}
if(!isnull(VehicleInfo[i][vPlates]))
{
SetVehicleNumberPlate(VehicleInfo[i][vScriptID], VehicleInfo[i][vPlates]);
}
else SetVehicleNumberPlate(VehicleInfo[i][vScriptID], " ");
if(!VehicleInfo[i][vValue])
{
VehicleInfo[i][vValue] = 1;
}
SetVehicleToRespawn(VehicleInfo[i][vScriptID]);
if(VehicleInfo[i][vImpounded] == 1)
{
SetVehiclePos(VehicleInfo[i][vScriptID], VehicleInfo[i][vImpoundPos][0], VehicleInfo[i][vImpoundPos][1], VehicleInfo[i][vImpoundPos][2]);
SetVehicleZAngle(VehicleInfo[i][vScriptID], VehicleInfo[i][vImpoundPos][3]);
}
}
Here is Query_LoadVehicles:
function Query_LoadVehicles()
{
if(!cache_num_rows())
return printf("* No vehicles were loaded from the database...");
new rows = cache_num_rows();
new endCount = 0;
for (new i = 0; i < rows && i < MAX_DYN_VEH; i ++)
{
VehicleInfo[i][vExists] = true;
cache_get_value_int(i, "ID", VehicleInfo[i][vID]);
cache_get_value_int(i, "OwnerID", VehicleInfo[i][vOwnerID]);
cache_get_value_int(i, "FactionID", VehicleInfo[i][vFactionID]);
cache_get_value_int(i, "Model", VehicleInfo[i][vModel]);
cache_get_value_int(i, "Colour1", VehicleInfo[i][vColour1]);
cache_get_value_int(i, "Colour2", VehicleInfo[i][vColour2]);
cache_get_value_float(i, "PosX", VehicleInfo[i][vPos][0]);
cache_get_value_float(i, "PosY", VehicleInfo[i][vPos][1]);
cache_get_value_float(i, "PosZ", VehicleInfo[i][vPos][2]);
cache_get_value_float(i, "PosA", VehicleInfo[i][vPos][3]);
cache_get_value_int(i, "Interior", VehicleInfo[i][vInterior]);
cache_get_value_int(i, "VW", VehicleInfo[i][vVW]);
cache_get_value(i, "Plates", VehicleInfo[i][vPlates], 32);
cache_get_value_int(i, "Locked", VehicleInfo[i][vLocked]);
cache_get_value_int(i, "Impounded", VehicleInfo[i][vImpounded]);
cache_get_value_float(i, "ImpoundPosX", VehicleInfo[i][vImpoundPos][0]);
cache_get_value_float(i, "ImpoundPosY", VehicleInfo[i][vImpoundPos][1]);
cache_get_value_float(i, "ImpoundPosZ", VehicleInfo[i][vImpoundPos][2]);
cache_get_value_float(i, "ImpoundPosA", VehicleInfo[i][vImpoundPos][3]);
cache_get_value_float(i, "Fuel", VehicleInfo[i][vFuel]);
cache_get_value_int(i, "Sirens", VehicleInfo[i][vSirens]);
cache_get_value(i, "FineReason", VehicleInfo[i][vFineReason], 32);
cache_get_value_int(i, "FineAmount", VehicleInfo[i][vFineAmount]);
cache_get_value_int(i, "FineOfficerID", VehicleInfo[i][vFineOfficerID]);
cache_get_value_int(i, "FineFactionID", VehicleInfo[i][vFineFactionID]);
cache_get_value_int(i, "FineTime", VehicleInfo[i][vFineTime]);
cache_get_value_int(i, "DMVVehicle", VehicleInfo[i][vDMVVehicle]);
cache_get_value_int(i, "Value", VehicleInfo[i][vValue]);
VehicleInfo[i][vScriptID] = CreateVehicle(VehicleInfo[i][vModel],
VehicleInfo[i][vPos][0],
VehicleInfo[i][vPos][1],
VehicleInfo[i][vPos][2],
VehicleInfo[i][vPos][3],
VehicleInfo[i][vColour1],
VehicleInfo[i][vColour2],
-1,
VehicleInfo[i][vSirens]);
ToggleVehicleLocked(VehicleInfo[i][vScriptID], 0);
UpdateVehiclePosition(i);
endCount++;
}
printf("* %d vehicles were loaded from the database...", endCount);
return 1;
}
Hello all!
I have a question
Install your OPBA anticheat - airbreak is detected.
But not teleport
I began to debug a code and noticed than after SetTimerEx("OPBA_CheckRealTP"...) in the end of OPBA_AirbrakeTeleport coordinates are rewrited. So in OPBA_CheckRealTP we have cheated coordinates, not fair.
Don't we have to add any condition to GetPlayerPos(playerid, OPBA_Player[playerid][RacX], OPBA_Player[playerid][RacY], OPBA_Player[playerid][RacZ]); in the end of OPBA_AirbrakeTeleport which will prevent it in case if OPBA_Player[playerid][RacHoldCheck] == true?
Thanks
Sorry for my English.
Run -> Enter vehicle while sprinting causes No.5 to get called falsely at times.
Describe the bug
I implemet this include on bare gamemde, and the scripts seems didn't do anything
Describe the bug
When using the whole package detection won't channel through OnPlayerViolate due to issues from the #if/else brackets
To Reproduce
Include the package and do no callbacks from your end, no detections will happen
= The fix i will implement: It just can't be fixed so i enforced my usage of it as it is the most recommended option
Is your feature request related to a problem? Please describe.
No
Describe the solution you'd like
I would like you to make a anticheat which can fight against this cleo.
Describe alternatives you've considered
[LINK REMOVED]
Reason: Downloadable cheat (I already viewed it)
Additional context
no.
Using SetVehiclePos or any legit position change for a vehicle with passengers THAT DOESN'T have a driver will trigger OnPlayerBreakAir with breaktype No. 6, I'll fix it in a while. For now ignore it. I.e:
public OnPlayerBreakAir(playerid, breaktype)
{
if(breaktype == 6) return 0;
//Rest of the code
return 1;
}
Hello,
My server faced multiple kinds of attacking, such as server restarting, changing scores and many more!
A hacker could kick someone playing even without being in-game!
A normal player told me he has Sobiet, he could restart the server in no moment!
How can i secure this from happening again?
Thanks a lot.
I completely ruined the boolean checks, IsValidReason and IsKillFalse will make sure that the include never works, this is going to be patched, just notifying anyone watching the repository.
Describe the bug
Airbreak/teleport gets detected for passengers when they fall (I dont know if its same for drivers but i think i fixed it on foot?)
To Reproduce
Steps to reproduce the behavior:
Expected behavior
A protection should be given for falling players as passengers (Again im not sure if it detects drivers as well and i still think i fixed it for on-foot players)
Screenshots
N/A
Samp details (please complete the following information):
Additional context
N/A
Describe the bug
Sometimes, when going between world 0 and a virtual world (1000) in interior ID 1 (Warehouse 1) (and quite possibly vice-versa, I can't be sure of that), AirbreakTeleport.inc will be triggered. I should add that I'm also using LaggersDetect.inc.
To Reproduce
It is hard to give steps as it doesn't always happen, but the basic overview of what causes the issue is written above.
Expected behavior
AirbreakTeleport.inc should not flag the player(s).
Screenshots
N/A
Samp details (please complete the following information):
Additional context
N/A
Describe the bug
The detection never works if you use the callback
To Reproduce
Steps to reproduce the behavior:
Using the callback
Fix by holding check with a variable after detection.
Describe the bug
Two Players in cars one hits the middle of the other with his front bumper makes the one hitting the other a cheater for No.3 In rAct
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Player calls the callback for No.3 (RACT_SKICK_CAR)
Screenshots
None
Samp details (please complete the following information):
Additional context
None.
Fixing by holding the check for 3 seconds after player stops falling.
a certain fix can be applied using the desync+lag detector.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.