Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local Players = game:GetService("Players")
- local player = Players.LocalPlayer
- local mouse = player:GetMouse()
- local tool = Instance.new("Tool")
- tool.Name = "Teleport Tool"
- tool.RequiresHandle = false
- tool.Parent = player.Backpack
- tool.Equipped:Connect(function()
- mouse.Button1Down:Connect(function()
- local character = player.Character
- if character and mouse.Hit then
- local root = character:FindFirstChild("HumanoidRootPart")
- if root then
- local pos = mouse.Hit.Position + Vector3.new(0, 3, 0)
- root.CFrame = CFrame.new(pos)
- end
- end
- end)
- end)
Advertisement
Add Comment
Please, Sign In to add comment