Advertisement
fireband12

Untitled

Jul 5th, 2015
178
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.00 KB | None | 0 0
  1. local plr = game.Players.LocalPlayer
  2. local mouse = plr:GetMouse()
  3. local Character = plr.Character
  4. local Torso = Character:WaitForChild("Torso")
  5. local RightHip = Torso:WaitForChild("Right Hip")
  6. local LeftHip = Torso:WaitForChild("Left Hip")
  7. local RightLeg = Character:WaitForChild("Right Leg")
  8. local CFrameInterpolate=function(s,e,a,r,i,n,g)g,r=CFrame,{{s:toEulerAnglesXYZ()},{e:toEulerAnglesXYZ()}}for _=1,3 do i,n=r[1][_],r[2][_]r[1][_]=i+a*(n-i)end return(g.new(s.p:lerp(e.p,a))*g.Angles(unpack(r[1])))end
  9.  
  10. mouse.KeyDown:connect(function(key)
  11. key:lower()
  12. if key == "f" then
  13. local mo = Instance.new("Motor6D", Torso)
  14. mo.Part0 = Torso
  15. mo.Part1 = RightLeg
  16. for i = 1,10,.1 do
  17. mo.C0 = CFrameInterpolate(mo.C0, CFrame.new(0,1,0) * CFrame.Angles(0,-1.5,0), .1)
  18. wait()
  19. end
  20. end
  21. end)
  22.  
  23. --[[
  24. local lefthip = Instance.new("Motor6D", child.Torso)
  25. lefthip.Name = "Left Hip"
  26. lefthip.DesiredAngle = 0.086
  27. lefthip.MaxVelocity = 0.1
  28. lefthip.Part0 = child.Torso
  29. lefthip.Part1 = child["Left Leg"]--]]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement