How do I handle speedhacks WITH a movement system?

Basically I have a movement system with running, and sprinting (if running for EX amount of time), and after looking at some posts about how to deal with speedhacks I still am not really sure how I am supposed to make sure the server doesn’t kick someone who is just running or sprinting and isn’t actually hacking.

I considered whitelisting certain velocities or speeds or whatever that are equivalent to what my movement system changes the walkspeed to, so for example when running the walkspeed gets set to 20, so on the server I would just ignore player velocity near the range of 20 and assume they are running, but the problem with that is a hacker could just set their walkspeed to 20 then keep it there and the server would ignore it and assume they are just running. (I think?)

I also considered maybe adding a threshold or timer so if they are going EX amount of velocity for too long, like longer than their stamina should last, it would either kick them or more likely, set their walkspeed to 10(the default for walking)

1 Like

Just work out the maximum possible speed a player could be travelling, add a tolerance for lag, then set your exploit detection to be above that.

1 Like