Advertisement
Guest User

ve ai

a guest
Apr 20th, 2019
116
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.63 KB | None | 0 0
  1. local debris = game:service("Debris")
  2. bin = script.Parent
  3. Go = 0
  4. Kick = false
  5. function onKeyDown(key)
  6. if Go == 1 then return end
  7. if key ~= nil then
  8. key = key:lower()
  9. if key == "e" then
  10. Go = 1
  11. if script.Parent.Parent.Parent.Character == nil then return end
  12. if script.Parent.Parent.Parent.Character:findFirstChild("Torso") == nil then return end
  13. if script.Parent.Parent.Parent.Character:findFirstChild("Right Leg") == nil then return end
  14. if script.Parent.Parent.Parent.Character:findFirstChild("Left Leg") == nil then return end
  15. Torso = script.Parent.Parent.Parent.Character.Torso
  16. RL = script.Parent.Parent.Parent.Character["Right Leg"]
  17. LL = script.Parent.Parent.Parent.Character["Left Leg"]
  18. Hip = Torso["Right Hip"]
  19. Hip1 = Torso["Left Hip"]
  20. Hip.Part1 = nil
  21. Hip1.Part1 = nil
  22. W = Instance.new("Weld")
  23. W.Parent = RL
  24. W.Part0 = Torso
  25. W.Part1 = RL
  26. ServerWeldInstance(RL, Torso, RL)
  27. R = Instance.new("Weld")
  28. R.Parent = LL
  29. R.Part0 = Torso
  30. R.Part1 = LL
  31. ServerWeldInstance(LL, Torso, LL)
  32. Kick = true
  33. W.C0 = CFrame.new(0.8,-1.3,-1.5) * CFrame.fromEulerAnglesXYZ(math.pi/2.5,-0.3,0.2)
  34. ServerWeld(RL, CFrame.new(0.8,-1.3,-1.5) * CFrame.fromEulerAnglesXYZ(math.pi/2.5,-0.3,0.2))
  35. R.C0 = CFrame.new(-0.8,-1.8,0.8) * CFrame.fromEulerAnglesXYZ(-math.pi/5,0.5,-0.3)
  36. ServerWeld(LL, CFrame.new(0.8,-1.8,-0.8) * CFrame.fromEulerAnglesXYZ(math.pi/5,0.5,-0.3))
  37. wait(0.1)
  38. W.C0 = CFrame.new(0.8,-1.5,-1.3) * CFrame.fromEulerAnglesXYZ(math.pi/3,-0.5,0.2)
  39. ServerWeld(RL, CFrame.new(0.8,-1.5,-1.3) * CFrame.fromEulerAnglesXYZ(math.pi/3,-0.5,0.2))
  40. wait(0.1)
  41. R.C0 = CFrame.new(-0.9,-1.8,1) * CFrame.fromEulerAnglesXYZ(-math.pi/4,0.5,-0.3)
  42. ServerWeld(LL, CFrame.new(0.9,-1.8,1) * CFrame.fromEulerAnglesXYZ(math.pi/4,0.5,-0.3))
  43. RL.Touched:connect(function(hit)
  44. if Kick == false then return end
  45. if hit.Locked == true or hit.Anchored == true then return end
  46. Kick = false
  47. F = Instance.new("BodyVelocity")
  48. F.Parent = hit
  49. F.velocity = RL.CFrame.lookVector * 85
  50. F.maxForce = Vector3.new(4e+006,0,4e+006)
  51. debris:AddItem(F,0.3)
  52. end)
  53. wait(0.3)
  54. Kick = false
  55. W:Remove()
  56. ServerWeldRemoval(RL)
  57. R:Remove()
  58. ServerWeldRemoval(LL)
  59. Hip.Part1 = RL
  60. UpdateHips(Hip, RL)
  61. Hip1.Part1 = LL
  62. UpdateHips(Hip1, LL)
  63. wait(0.2)
  64. Go = 0
  65. end
  66. end
  67. end
  68.  
  69. bin.Deselected:connect(function()
  70. end)
  71. function onSelected(mouse)
  72. mouse.KeyDown:connect(onKeyDown)
  73. end
  74.  
  75. bin.Selected:connect(onSelected)
  76.  
  77. function ServerWeld(weld, cframe)
  78. game:GetService("ReplicatedStorage").RemoteEvents.WeldUpdates:FireServer(weld, cframe)
  79. end
  80. ---------------------------------
  81. function ServerWeldInstance(weldparent, weldpart0, weldpart1)
  82. game:GetService("ReplicatedStorage").RemoteEvents.WeldInstanceUpdate:FireServer(weldparent, weldpart0, weldpart1)
  83. end
  84. ---------------------------------
  85. function ServerWeldRemoval(weldname)
  86. game:GetService("ReplicatedStorage").RemoteEvents.WeldRemoval:FireServer(weldname)
  87. end
  88. ---------------------------------
  89. function UpdateHips(hip, part1)
  90. game:GetService("ReplicatedStorage").RemoteEvents.UpdateHips:FireServer(hip, part1)
  91. end
  92. ---
  93. ---
  94. ---
  95. function CFrameTorso(torso1, cframe_value)
  96. game:GetService("ReplicatedStorage").Events.TorsoCFrame:FireServer(torso1, cframe_value)
  97. torso1.CFrame = cframe_value
  98. end
  99. ---
  100. function FE_Attach(name, part0, part1, ball, c0, c1)
  101. game:GetService("ReplicatedStorage").Events.Attach:FireServer(name, part0, part1, ball, c0, c1)
  102. local W = Instance.new("Weld")
  103. W.Name = "Keep"
  104. W.Part0 = part0
  105. W.Part1 = part1
  106. W.Parent = part0
  107. W.C0 = c0
  108. W.C1 = c1
  109. end
  110. ---
  111. ---
  112. function OwnershipChange(ball)
  113. game:GetService("ReplicatedStorage").Events.NetworkOwnership:FireServer(ball)
  114. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement