AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   General (https://forums.alliedmods.net/forumdisplay.php?f=58)
-   -   Lag exploit fix (simulation time difference) (https://forums.alliedmods.net/showthread.php?t=313712)

foes 01-19-2019 17:22

Lag exploit fix (simulation time difference)
 
1 Attachment(s)
Hi everyone, i'm new the forum and need help. I'm trying to fix a very annoying exploit in CS:S which is called lag exploit.
Here is an example of what it does: https://youtu.be/zY55M9D7khQ?t=28s

The video shows someone planting and exploding the bomb like instantly. Lag exploits also lets you do other things than just that.
However a friend of mine has been trying to fix this issue by kicking clients that have a high simulation time difference and it actually works, it kicks people who attempt lag exploits.
Thing is that it often kicks legit people who dont attempt these kind of exploits. Sometimes when they join they get kicked instantly or just randomly after some time.
That especially happens when you tab.

I'm trying to think of some idea to improve this but at the moment i have no clue how. I'm also fairly new to sourcemod and still trying learn pawn.
I attached the source to this thread. Thanks for your help. BTW the plugin is for CS:S.

backwards 01-20-2019 03:32

Re: Lag exploit fix (simulation time difference)
 
You could hook a function like ProcessUserCmds using dhooks and update a variable with the most recent time a user has sent a chunk of these. If it's been > 1.0 seconds you can just ignore the checks and not ban the player. This should prevent that issue mostly. Alternatively most users would use the exploit when planting or defusing the bomb, you can get an instance when a player starts to plant/defuse the bomb by event and get the current time. Then on the finished defuse/plant you would subtract the current time from the previous and see if it's less than the amount of time it normally takes to do these actions. (bomb_defused, bomb_begindefuse, bomb_beginplant, bomb_planted, bomb_defused, bomb_exploded events)


All times are GMT -4. The time now is 02:01.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.