Anti Click to TP (Feedback)

This looks just like one of mine…

local Players = game:GetService("Players")
local rns = game:GetService("RunService")

Players.PlayerAdded:Connect(function(p)
	p.CharacterAdded:Connect(function(c)
		local hrp = c:WaitForChild("HumanoidRootPart")
		local last = hrp.Position
		local conn; conn = rns.Heartbeat:Connect(function()
			if not c:IsDescendantOf(game) then return conn:Disconnect() end
			local pos = hrp.Position
			if (pos - last).Magnitude > 50 then
				conn:Disconnect()
				p:Kick("Exploit Detected")
			end last = pos
		end)
	end)
end)

I was just testing here… Really hate to ever use heartbeat for anything.

2 Likes

Oh my bad, I didn’t realize it was based on position changes instead of clicks. Thank you for responding through.

2 Likes

Most scripts that do the same things do look similar.

3 Likes

All good thanks for your response.

3 Likes

Hey there,

I see your point of view of this script, but you also forgot something.

The function will check when the player moved, therefore, when the player doesn’t move, no processing has been done, which is good for performance and unwanting reqource spilling.

You mentioned that when the player stands still, it wil teleport when the player clicked, in other words, the player position changed, thus, the function will trigger.

I hope this cleans up your confusion!

1 Like

I was going to say something else however someone else already said it.

Anyways, I personally agree with @Phylixius, I’m not to informed about exploiting however you should never take risks (depending on what your game is).

2 Likes

Thanks for your reply, i’ll revamp the code tomorrow and reply. Thanks for your help and clarification, I really appreciate it.

3 Likes

Hey there,

No worries, I’m glad I could help you!

If you have any other questions or need help on Roblox, you can always consult our developer forum!

1 Like

I’m not just prepared. I welcome it. Why do I welcome it? It’s not going to happen. That’s why.

All are welcomed to torture themselves and try to bypass it :slightly_smiling_face:

I trust the client until it detects them when they do something that isn’t allowed

That wasn’t intentional and I’m not sure why it did that but currently both his and mine have not been bypassed since the time of that attack as far as I’m aware.

Trust me I’m not here to be rude or overly aggressive but my point is simple: You can talk about what you think you know and understand all you want but if you can’t actually bypass mine or his then it proves that I’m in the right.

You just preached most simple and illogical concept.

Telling people that because it’s not 100% proof from something happening that it’s bad.

This concept is the same as saying “You should not go for a walk outside because some crazy person might come and hurt you” or “You should not cross the street because you might get hit by a car”

Yet both of those statements completely get overridden by basic logic. You always check to your right and your left before crossing the street. You always call 911 if a crazy person starts chasing you and defending yourself.

Again. Not trying to sound rude but it’s common sense.

1 Like

There is quite the ongoing debate about whether or not a handshake system is secure for a client anticheat.

Yes, it helps the server detect when a client anticheat is disabled or destroyed, but there’s the issue of hooking. Exploiters can hook the remote methods, remove the client anticheat’s connections and create a fake client to respond to requests. But then again, there’s a way around that. I am aware of and have tested myself a method of detecting hooks, which involves a built-in function, but most executors will hook at memory address, so storing an original reference to the function will not help. Unless you have a way to copy a function or else get around a hook, you’re quite cooked as they can just hook that global.

4 Likes

I can see your point.

I do not want to stretch this longer however, I do not think you should attempt to get people to hack/bypass your game to prove a point. It’s against the Terms of Service and also it’s incredibly sketchy.

1 Like

I just find it better to handle most anti exploits from the server, especially when your only checking character positions.

4 Likes