I have a button but i want the player to use only every minute. Not after a minute they can use it. Say I clicked the button, I cannot use it for another minute, like that. This is the code inside the button right now. I do not know how to make the timer. I know how to use loops and runservice but I do not know how to make this certain timer of timer which resets when a player hits the button.
CurrentStage.MouseButton1Click:Connect(function()
local player = game.Players.LocalPlayer.Character:FindFirstChild("Humanoid")
local players = game.Players.LocalPlayer
local Character = players.Character
local humpart = Character.HumanoidRootPart
RunService.Stepped:Wait()
humpart.CFrame = checkpoints[players.leaderstats.Stage.Value].CFrame+ Vector3.new(0,math.rad(120),0)
end)
end)