Advertisement
UserBlocked

Click to TP

Aug 20th, 2019
113
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.37 KB | None | 0 0
  1. local localPlayer = game:GetService("Players").LocalPlayer
  2. local char = localPlayer.Character
  3. local root = char.HumanoidRootPart
  4. local mouse = localPlayer:GetMouse()
  5.  
  6. if _G.ClickToTeleport == true then
  7.     _G.ClickToTeleport = false
  8.  else
  9.     _G.ClickToTeleport = true
  10. end
  11.  
  12. mouse.Button1Down:connect(function()
  13.     if _G.ClickToTeleport then root.CFrame = mouse.Hit end
  14. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement