Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local Plr = game:GetService("Players").LocalPlayer
- local Mouse = Plr:GetMouse()
- local char = Plr.Character
- local human = char:FindFirstChild("Humanoid")
- local floating = true
- local runnyboi = true
- local falling = false
- Mouse.KeyDown:connect(function(KeyDown)
- if KeyDown == "e" then
- floating = false
- falling = false
- human:ChangeState(Enum.HumanoidStateType.Jumping)
- runnyboi = false
- elseif KeyDown == "q" then
- floating = false
- falling = true
- runnyboi = false
- end
- end)
- Mouse.KeyUp:connect(function(KeyUp)
- if KeyUp == "e" or KeyUp == "q" then
- floating = true
- runnyboi = true
- end
- end)
- game:GetService("RunService").RenderStepped:Connect(function()
- if char and human then
- if floating then
- human:ChangeState(11)
- end
- if falling then
- game:GetService("Workspace").Gravity = 50
- else
- game:getService("Workspace").Gravity = 0
- end
- if runnyboi then
- human.WalkSpeed = 100
- else
- human.WalkSpeed = 0
- end
- end
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement