I was creating some levels, in which you have to touch a brick to teleport to the level area.
So the ServerScript inside of the Part went something like this:
local canRecieve = true
script.Parent.Touched:Connect(function(hit)
if hit.Parent:WaitForChild('Humanoid') then
local player = game.Players:GetPlayerFromCharacter(hit.Parent)
if canRecieve == true then
canRecieve = false
player:WaitForChild('leaderstats').Vertigo.Value = player:WaitForChild('leaderstats').Vertigo.Value + 1000
game.ReplicatedStorage.OneThousandRecieved:FireClient(player)
hit.Parent:WaitForChild('HumanoidRootPart').CFrame = CFrame.new(40.882, 3.974, -9.194)
wait(60)
canRecieve = true
end
end
end)
The thing is, it's server-side. I want the cooldown of the .Touched event ONLY for the client, so that no one can abuse this system and not let anyone through.
Do I have to use RemoteEvents? If so, how could I use it?
Help please!

2 comments
The event fires on both client and server and can be accessed from both.
ok