Advertisement
MRobbin99

tp to mouse

Jan 11th, 2019
357
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.28 KB | None | 0 0
  1. -- press e to teleport
  2. plr = game.Players.LocalPlayer
  3. hum = plr.Character.HumanoidRootPart
  4. mouse = plr:GetMouse()
  5. mouse.KeyDown:connect(function(key)
  6. if key == "e" then
  7. if mouse.Target then
  8. hum.CFrame = CFrame.new(mouse.Hit.x, mouse.Hit.y + 5, mouse.Hit.z)
  9. end
  10. end
  11. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement