TheUnknownDiscord

walljump

Sep 20th, 2021 (edited)
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.87 KB | None | 0 0
  1. NLS([[
  2.  
  3. for i,v in pairs(owner.Character:GetDescendants()) do
  4. if v:IsA("BasePart") then
  5. v.CanTouch = false
  6. end
  7. end
  8. wait(0.1)
  9. owner.Character.Torso.CanTouch = true
  10. touchedlol = false
  11. RootPart = owner.Character.HumanoidRootPart
  12. local function touch(hit)
  13. if hit then
  14. touchedlol = true
  15. end
  16. end
  17. local function touchnot(hit)
  18. if hit then
  19. touchedlol = false
  20. end
  21. end
  22. owner.Character.Humanoid:GetPropertyChangedSignal("Jump"):Connect(function()
  23. if touchedlol and owner.Character.Humanoid.Jump then
  24. look = owner.Character.Torso.CFrame.LookVector * -2.5
  25. RootPart.Velocity =
  26. RootPart.Velocity +
  27. Vector3.new(0, owner.Character.Humanoid.JumpPower * 1, 0) +
  28. (look * owner.Character.Humanoid.JumpPower)
  29. end
  30. end)
  31. owner.Character.Torso.Touched:connect(touch)
  32. owner.Character.Torso.TouchEnded:connect(touchnot)
  33. wait(0.1)
  34. grab = true
  35. ]],owner.PlayerGui)
Add Comment
Please, Sign In to add comment