Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local plr = game:GetService("Players").LocalPlayer
- local char = plr.Character
- local mouse = game:GetService("Players").LocalPlayer:GetMouse()
- local hum = char:FindFirstChild("HumanoidRootPart")
- local KEY= "q"
- local SPEED = "3"
- mouse.KeyDown:connect(function(key)
- if key == KEY then
- loop = true
- while loop do
- hum.CFrame = hum.CFrame + hum.CFrame.lookVector * SPEED
- wait()
- end
- end
- end)
- mouse.KeyUp:connect(function(key)
- if key == KEY then
- loop = false
- end
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement