Quote:
Originally Posted by zTREME
for speedhack not only speed, uz then cyclone will get them caught.
Make it check speed + ping.
because when you speedhack your ping goes really high, but if is just lag, then you dont speed. So if you lag and have high speed, then is probably speedhack XD
|
Using C-E speed hack would make it very visible even to the server not just by walking too fast or jumping too fast. The client sends each 8 seconds a ping packet. Using C-E speed hack the client will send the ping packet according with your selected speed. For eg setting the speed to 0.5 would make the client send the ping packet after more than 8 seconds. If you chose 1.5 or whatever, the client will send the ping packet in less than 8 seconds. This fact can be used to detect c-e speedhack. If the ping packet is received twice in less than 14seconds => speedhack.(If lag the ping packets will be received by server with some delay so it will always be more than 7 seconds.)
Other speedhacks.
Add time check between walks and jumps.
More likely if players have cyclone/superman/riding horse remove the checks
Basic speed for jump is:
public static uint minJumpTime(uint distance)
{
return (uint)(400 * distance / 10);
}
If time between jumps is less than minJumpTime(distance) then disconnect because that's speedhack. Even so, I say you should use 300 not 400 to make sure people won't get disconnected for nothing.
About walk...I didn't look for some time check yet.
Hopefully my English is not that bad so it can be understood...