Advertisement
Guest User

Untitled

a guest
Aug 4th, 2015
198
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.04 KB | None | 0 0
  1. local mp = game.Players.LocalPlayer
  2. local mpc = mp.Character
  3. local mouse = mp:GetMouse()
  4.  
  5. mpc.Humanoid.PlatformStand = true
  6. local ball = Instance.new("Part",workspace)
  7. ball.Transparency = 0.4
  8. ball.BrickColor = BrickColor:Black()
  9. ball.Shape = "Ball" --ball+ball yup i got them ballz
  10. ball.Size = Vector3.new(10,10,10)
  11. local weld = Instance.new("Weld",ball)
  12. weld.Part0 = mpc.Torso --mpc = mp.Character well here the weld.Part0 means that the main part is mpc.Torso
  13. weld.Part1 = ball --This is the part that has to be attached to Part0(Torso)
  14. local bv = Instance.new("BodyVelocity")
  15. bv.maxForce = Vector3.new(100000,5000,100000)
  16. mouse.Button1Down:connect(function()
  17. bv.velocity = mouse.hit.lookVector*80 --This means the velocity(direction in this case) is the where the mouse.hit(mouse.hit gives you 3D position of mouse x,y,z and it's CFrame) mouse.hit.lookVector this means
  18. --get the direction of the CFrame which will return a new cframe by multiplying it to 80 means the new cframe with longer distance there's a reason for this too
  19. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement