how can i make it so that when on person touches a part then a value will change to half its value? this is the script i have in the part right now
function Touched(hit)
local b = hit.Parent:FindFirstChild("Humanoid")
if b ~= nil then
game.ReplicatedStorage.WaitTime.Value = 0.5
end
end
script.Parent.Touched:connect(Touched)

3 comments
Check out my answer!
This is exploitable.