Hello Devs, i was doing a script to give speed to the Humanoid, everything is ok with my script, it works but the problem is when the script execute for the 2nd time, the script doesnt work for the 2nd time but the output doesnt give any errors, anyone know why this is happening?
Im doing this by touched event
My script:
local instance = script.Parent
local function speed(Part)
local Humanoid = Part.Parent:FindFirstChild(“Humanoid”)
if Humanoid then
Humanoid.WalkSpeed = 35
end
end
instance.Touched:Connect(speed)