Hey,i tried to make my character walk faster using "User input service" to make a sprint key.
local UIS = game:GetService("UserInputService")
UIS.InputBegan:connect(function(input)
if input.KeyCode == Enum.KeyCode.Q then
print("yes")
local hum = game.Players.LocalPlayer:WaitForChild("Humanoid")
hum.WalkSpeed = 25
end
end)
This is my code. I tested it and when i'm pressing q it does print "yes" and i'm 100% sure that the 6 and 7th lines aren't correct. Could someone help me?

1 comment
also the script is a local one so there are no tehnnical issues