Advertisement
tbgtrev

x

Mar 5th, 2025
39
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.71 KB | None | 0 0
  1. getgenv().animpos = 0
  2. getgenv().underground = -6.50
  3.  
  4. local enabled = false
  5. local runserv = game:GetService("RunService")
  6. local lplr = game:GetService("Players").LocalPlayer
  7. local mouse = lplr:GetMouse()
  8. local animation = Instance.new("Animation")
  9. animation.AnimationId = "http://www.roblox.com/asset/?id=10147821284"
  10. local danceTrack
  11. mouse.KeyDown:Connect(function(key)
  12. if key == string.lower("x") then
  13. pcall(function()
  14. if enabled == false then
  15. enabled = true
  16. danceTrack = lplr.Character:FindFirstChildWhichIsA("Humanoid"):LoadAnimation(animation)
  17. danceTrack.Looped = false
  18. danceTrack:Play(.1, 1, 0)
  19. elseif enabled then
  20. enabled = false
  21. danceTrack:Stop()
  22. danceTrack:Destroy()
  23. end
  24. end)
  25. end
  26. end)
  27. local dysenc = {}
  28. local temp = 1
  29. runserv.Heartbeat:Connect(function()
  30. temp = temp + 1
  31. if enabled and lplr.Character and lplr.Character.HumanoidRootPart then
  32. danceTrack.TimePosition = animpos
  33. dysenc[1] = lplr.Character.HumanoidRootPart.CFrame
  34. dysenc[2] = lplr.Character.HumanoidRootPart.AssemblyLinearVelocity
  35. local SpoofThis = lplr.Character.HumanoidRootPart.CFrame
  36. SpoofThis = (SpoofThis + Vector3.new(0, getgenv().underground, 0)) * CFrame.Angles(0, 0, math.pi)
  37. lplr.Character.HumanoidRootPart.CFrame = SpoofThis
  38. runserv.RenderStepped:Wait()
  39. if lplr.Character and lplr.Character.HumanoidRootPart then
  40. lplr.Character.HumanoidRootPart.CFrame = dysenc[1]
  41. lplr.Character.HumanoidRootPart.AssemblyLinearVelocity = dysenc[2]
  42. end
  43. end
  44. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement