Advertisement
kevinbuitendyk

Untitled

Nov 20th, 2017
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.36 KB | None | 0 0
  1. wait()
  2. local plrs = game:GetService("Players")
  3. local plr = plrs.LocalPlayer
  4. local char = plr.Character
  5. local head = char:WaitForChild("Head")
  6. local mouse = plr:GetMouse()
  7. local animation = Instance.new("Animation")
  8. animation.AnimationId = "http://www.roblox.com/Asset?ID=1188959652"
  9. local tweenService = game:GetService("TweenService")
  10. local cool = false
  11.  
  12. local tweeningInformation = TweenInfo.new(2,Enum.EasingStyle.Linear,Enum.EasingDirection.Out)
  13.  
  14. mouse.Button1Down:Connect(function()
  15. if cool == false then
  16. cool = true
  17. char.Torso.Anchored = true
  18. local animTrack = char.Humanoid:LoadAnimation(animation)
  19. animTrack:Play()
  20. local b = Instance.new("Part")
  21. b.Shape = Enum.PartType.Ball
  22. b.CanCollide = false
  23. b.Parent = workspace
  24. b.Anchored = true
  25. b.CFrame = CFrame.new(head.CFrame.X, head.CFrame.Y, head.CFrame.Z)
  26. local partProperties = {Position = Vector3.new(head.CFrame.X, head.CFrame.Y * 2, head.CFrame.Z)}
  27. local Tween = tweenService:Create(b,tweeningInformation,partProperties)
  28. Tween:Play()
  29. wait(2)
  30. b.Anchored = false
  31. local f = Instance.new("BodyForce")
  32. f.Parent = b
  33. f.Force = mouse.Hit.p * 10
  34. b.Touched:connect(function(hit)
  35. if hit.Parent:FindFirstChild("Humanoid") ~= nil and hit.Parent ~= char then
  36. hit.Parent.Humanoid.Health = 0
  37. b:Destroy()
  38. end
  39. end)
  40. char.Torso.Anchored = false
  41. wait(2)
  42. cool = false
  43. end
  44. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement