I want to stop exploiters from calling a remote, from 100000 studs away.
This will be for a part you can touch and earn money / points off of
how could i check if the player is in a Radius and if so continue else kick them.
if (plyr.HumanoidRootPart.Position - part.Position).magnitude > 5 then
plyr:Kick()
return
end
1 Like
This could also do the work
local part = --put the part here
local radius = 5 --change radius according to your needs
local player
game.Players.PlayerAdded:Connect(function(fv1)
player = fv1
end)
local functions f1()
if player:DistanceFromCharacter(part.Position) > radius then
player:Kick()
end
end
1 Like
Thanks,
#IHate30CharaterBlocks