Advertisement
jjoseph196

2007 Roblox Custom Cursor Script

Dec 10th, 2015
4,149
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.06 KB | None | 0 0
  1. local plr = game.Players.LocalPlayer
  2. local mouse = plr:GetMouse()
  3. local char
  4. local canMove = true
  5. repeat
  6.     wait()
  7.     char = plr.Character
  8. until char~=nil
  9. local circle = Instance.new('Part',workspace)
  10. circle.Shape = 'Cylinder'
  11. circle.FormFactor = 'Custom'
  12. circle.Size = Vector3.new(0.2,2,2)
  13. circle.Rotation = Vector3.new(0,0,90)
  14. circle.BrickColor = BrickColor.new('Lime green')
  15. circle.Anchored = true
  16. mouse.Icon= 'http://www.roblox.com/asset/?id=329842504'
  17. mouse.Move:connect(function()
  18.     circle.Position = Vector3.new(mouse.Hit.p.X,mouse.Target.Position.Y,mouse.Hit.p.Z)
  19.     if(char.Torso.Position-mouse.Hit.p).Magnitude>=50 then
  20.         circle.Transparency=1
  21.         mouse.Icon='http://www.roblox.com/asset/?id=329847672'
  22.         canMove=false
  23.     else
  24.         circle.Transparency=0
  25.         mouse.Icon='http://www.roblox.com/asset/?id=329842504'
  26.         canMove=true
  27.     end
  28. end)
  29. mouse.Button1Down:connect(function()
  30.     if canMove==true then
  31.         if char:FindFirstChild'Humanoid'then
  32.             char.Humanoid:MoveTo(circle.Position)
  33.         end
  34.     end
  35. end)
  36. char.Humanoid.Died:connect(function()
  37.     circle:Destroy()
  38. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement