Advertisement
tonypoor12323

Sprint Script | Roblox Studio

May 2nd, 2021
2,309
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.55 KB | None | 0 0
  1. local userInputService = game:GetService("UserInputService")
  2. local userName = script.Parent.Parent.Name
  3.  
  4. userInputService.InputBegan:Connect(function(input, gameProcessed)
  5.     if gameProcessed then
  6.         return
  7.     else
  8.         if input.KeyCode == Enum.KeyCode.LeftShift then
  9.             workspace[userName].Humanoid.WalkSpeed = 32
  10.         end
  11.     end
  12. end)
  13.  
  14. userInputService.InputEnded:Connect(function(input, gameProcessed)
  15.     if gameProcessed then
  16.         return
  17.     else
  18.         if input.KeyCode == Enum.KeyCode.LeftShift then
  19.             workspace[userName].Humanoid.WalkSpeed = 16
  20.         end
  21.     end
  22. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement