Would this be a good way to detect speed exploiting

it would kick if they walked 500 studs in less than 10 seconds

@Deezylolz You would want to check the magnitude between the two points.

@VaderGoalie You could just check if they were an admin before kicking them, or check their rank.

Ah i understand now. Thanks for the relpy.

I believe he’s making a temporary solution.

And to add on to that you could make a event when the player is teleported or given speed by a ADMIN that tells the code not to kick that player.

What if the player gets flinged somehow?

I believe this solution is better:

  plr.CharacterAdded:Connect(function(char)
      char.Humanoid.Running:Connect(function(speed)
      If speed > 40 then plr:kick()
             
end)
end)

Reason we use > 40 its because humanoid.running parameter return the absolute player speed so if the player glitches then the speed would go up to 16

but the player speed doesn’t replicate to the server so we need to check for distance

You can use this module:

Actually humanoid.running don’t give the player walk speed it give the player absolute speed which mean if the player is going fast and his walkspeed in the server is 16 then in the humanoid.running it will be more than that

The player speed number doesn’t replicate to the server

sorry but I didn’t understood what you said above

Wdym by player speed number? Do you mean the humanoid walkspeed don’t replicate from client to server ?

1 Like

Yes…

I need to write here

Yea but humanoid.running don’t return the humanoid walkspeed it return the player absolute speed which mean if the player is going fast it will have a velocity which is replicated and this function get that and turn it to speed idk how its turning it but there is a formula to that

1 Like

Why not to check distance from the last position of HumanoidRootPart?

Because sometime in the game itself can teleport the player to some place and the script itself would see if its last position is greater 500 and if it is then it will say “Oh its greater well, kick goes brr brr zoom sqrrrt” just a joke but you get it

1 Like

I don’t think kick is the right punishment

and you can do some calculations!
where the player stand last time, notify the server this teleport is vaild and tell him to ignore this and not kick him

Yes you can like add a bool value then when the server check it it will check if the bool value is here if it is then it will delete the book and return end

You can’t delete something that is on the server ( unless the server deletes it : ) )

You can delete it on your client…

You create it on the server then delete it on the server that what I mean i think you didn’t understand what I said

1 Like