TP_Tool_v2

Run Settings
LanguageLua
Language Version
Run Command
--[[ TP TOOL v2 | Advanced Executor Teleport [RIGHT CLICK] = TP to mouse position [T] = Toggle TP on/off [P] = Open player TP menu (click name to tp to them) [B] = Set waypoint at current pos [N] = TP to last waypoint [DELETE] = Clear waypoint Coords HUD + Waypoint display + Player list ]] -- services local plrs = game:GetService("Players") local uis = game:GetService("UserInputService") local rs = game:GetService("RunService") local ts = game:GetService("TweenService") local lp = plrs.LocalPlayer local mouse = lp:GetMouse() -- character refs local char, hmn, hrp local function grab() char = lp.Character if not char then return false end hmn = char:FindFirstChildOfClass("Humanoid") hrp = char:FindFirstChild("HumanoidRootPart") return hrp ~= nil and hmn ~= nil end grab() lp.CharacterAdded:Connect(function(c) c:WaitForChild("HumanoidRootPart") task.wait(0.2) grab() end) -- state local enabled = true local waypoint = nil local playerListOpen = false ------------------------------------------------------------------------ -- GUI ------------------------------------------------------------------------ local function kill(n) local x = lp.PlayerGui:FindFirstChild(n) if x then x:Destroy() end end kill("TPGui") local gui = Instance.new("ScreenGui") gui.Name = "TPGui" gui.ResetOnSpawn = false gui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling gui.Parent = lp.PlayerGui -- helper local function mkFrame(props) local f = Instance.new("Frame") f.BackgroundColor3 = props.bg or Color3.fromRGB(28,28,28) f.BorderSizePixel = 0 f.Size = props.size f.Position = props.pos f.Parent = props.parent f.BackgroundTransparency = props.tp or 0 if props.stroke then local s = Instance.new("UIStroke",f) s.Thickness = props.stroke s.Color = props.strokeColor or Color3.fromRGB(10,10,10) end return f end local function mkLabel(props) local t = Instance.new("TextLabel") t.BackgroundTransparency = 1 t.Size = props.size t.Position = props.pos or UDim2.new() t.Text = props.text or "" t.TextColor3 = props.color or Color3.fromRGB(200,200,200) t.TextSize = props.tsize or 12 t.Font = Enum.Font.Code t.TextXAlignment = props.ax or Enum.TextXAlignment.Left t.RichText = true t.Parent = props.parent t.Name = props.name or "Label" return t end -- main hud bar local bar = mkFrame({ size = UDim2.new(0,300,0,82), pos = UDim2.new(0.5,-150,1,-100), bg = Color3.fromRGB(22,22,22), parent = gui, stroke = 3, strokeColor = Color3.fromRGB(8,8,8), }) local inner = mkFrame({ size = UDim2.new(1,-8,1,-8), pos = UDim2.new(0,4,0,4), bg = Color3.fromRGB(38,38,38), parent = bar, stroke = 1, strokeColor = Color3.fromRGB(52,52,52), }) -- status local statusLbl = mkLabel({ size = UDim2.new(1,-12,0,16), pos = UDim2.new(0,6,0,3), text = '<font color="#55FF55">[ TP: ON ]</font> <font color="#888888">RClick=TP T=Toggle</font>', tsize = 11, parent = inner, name = "Status", }) -- coords local coordsLbl = mkLabel({ size = UDim2.new(1,-12,0,14), pos = UDim2.new(0,6,0,20), text = "Pos: 0, 0, 0", color = Color3.fromRGB(170,170,170), tsize = 11, parent = inner, name = "Coords", }) -- target info local targetLbl = mkLabel({ size = UDim2.new(1,-12,0,14), pos = UDim2.new(0,6,0,35), text = '<font color="#FFFF55">Hover to see target</font>', tsize = 11, parent = inner, name = "Target", }) -- waypoint info local wpLbl = mkLabel({ size = UDim2.new(1,-12,0,14), pos = UDim2.new(0,6,0,50), text = '<font color="#888888">WP: None [B]=Set [N]=Go</font>', tsize = 10, parent = inner, name = "WP", }) -- flash overlay local flash = Instance.new("Frame") flash.Size = UDim2.new(1,0,1,0) flash.BackgroundColor3 = Color3.fromRGB(120,60,255) flash.BackgroundTransparency = 1 flash.BorderSizePixel = 0 flash.ZIndex = 10 flash.Parent = gui -- crosshair local cross = mkLabel({ size = UDim2.new(0,20,0,20), pos = UDim2.new(0.5,-10,0.5,-10), text = "+", color = Color3.fromRGB(140,70,255), tsize = 22, ax = Enum.TextXAlignment.Center, parent = gui, name = "Cross", }) cross.TextYAlignment = Enum.TextYAlignment.Center cross.TextStrokeTransparency = 0.3 ------------------------------------------------------------------------ -- PLAYER LIST (toggle with P) ------------------------------------------------------------------------ local plrFrame = mkFrame({ size = UDim2.new(0,200,0,0), pos = UDim2.new(0,12,0.5,-100), bg = Color3.fromRGB(22,22,22), parent = gui, stroke = 2, strokeColor = Color3.fromRGB(60,30,100), }) plrFrame.Visible = false plrFrame.ClipsDescendants = true plrFrame.Name = "PlrList" local plrTitle = mkLabel({ size = UDim2.new(1,0,0,22), pos = UDim2.new(0,8,0,2), text = '<font color="#AA55FF">[ PLAYERS ]</font>', tsize = 12, parent = plrFrame, }) local plrScroll = Instance.new("ScrollingFrame") plrScroll.Size = UDim2.new(1,-4,1,-26) plrScroll.Position = UDim2.new(0,2,0,24) plrScroll.BackgroundTransparency = 1 plrScroll.BorderSizePixel = 0 plrScroll.ScrollBarThickness = 4 plrScroll.ScrollBarImageColor3 = Color3.fromRGB(100,50,160) plrScroll.CanvasSize = UDim2.new(0,0,0,0) plrScroll.Parent = plrFrame local plrLayout = Instance.new("UIListLayout") plrLayout.SortOrder = Enum.SortOrder.Name plrLayout.Padding = UDim.new(0,2) plrLayout.Parent = plrScroll local function refreshPlrList() for _,c in ipairs(plrScroll:GetChildren()) do if c:IsA("TextButton") then c:Destroy() end end local list = plrs:GetPlayers() local count = 0 for _, p in ipairs(list) do if p ~= lp then count += 1 local btn = Instance.new("TextButton") btn.Size = UDim2.new(1,-8,0,22) btn.BackgroundColor3 = Color3.fromRGB(35,35,35) btn.BorderSizePixel = 0 btn.Text = " " .. p.DisplayName .. " (@" .. p.Name .. ")" btn.TextColor3 = Color3.fromRGB(200,200,200) btn.TextSize = 11 btn.Font = Enum.Font.Code btn.TextXAlignment = Enum.TextXAlignment.Left btn.Parent = plrScroll Instance.new("UIStroke", btn).Color = Color3.fromRGB(50,50,50) btn.MouseEnter:Connect(function() btn.BackgroundColor3 = Color3.fromRGB(60,30,100) end) btn.MouseLeave:Connect(function() btn.BackgroundColor3 = Color3.fromRGB(35,35,35) end) btn.MouseButton1Click:Connect(function() if not grab() then return end local tc = p.Character if tc and tc:FindFirstChild("HumanoidRootPart") then doTP(tc.HumanoidRootPart.Position + Vector3.new(0,3,0)) targetLbl.Text = '<font color="#AA55FF">TP >> ' .. p.DisplayName .. '</font>' end end) end end plrScroll.CanvasSize = UDim2.new(0,0,0,count * 24) plrFrame.Size = UDim2.new(0,200,0, math.min(count * 24 + 28, 250)) end local function togglePlrList() playerListOpen = not playerListOpen plrFrame.Visible = playerListOpen if playerListOpen then refreshPlrList() end end ------------------------------------------------------------------------ -- TP FUNCTION ------------------------------------------------------------------------ function doTP(pos) if not grab() then return end -- flash flash.BackgroundTransparency = 0.4 ts:Create(flash, TweenInfo.new(0.35, Enum.EasingStyle.Quad, Enum.EasingDirection.Out), { BackgroundTransparency = 1 }):Play() -- tp hrp.CFrame = CFrame.new(pos + Vector3.new(0,0.5,0)) end ------------------------------------------------------------------------ -- INPUT ------------------------------------------------------------------------ uis.InputBegan:Connect(function(inp, gpe) if gpe then return end if inp.KeyCode == Enum.KeyCode.T then enabled = not enabled if enabled then statusLbl.Text = '<font color="#55FF55">[ TP: ON ]</font> <font color="#888888">RClick=TP T=Toggle</font>' cross.TextColor3 = Color3.fromRGB(140,70,255) else statusLbl.Text = '<font color="#FF5555">[ TP: OFF ]</font> <font color="#888888">RClick=TP T=Toggle</font>' cross.TextColor3 = Color3.fromRGB(100,100,100) end end if inp.KeyCode == Enum.KeyCode.P then togglePlrList() end if inp.KeyCode == Enum.KeyCode.B then if grab() then waypoint = hrp.Position local w = waypoint wpLbl.Text = string.format('<font color="#55FF55">WP: %d,%d,%d</font> <font color="#888">[N]=Go [Del]=Clear</font>', math.floor(w.X), math.floor(w.Y), math.floor(w.Z)) end end if inp.KeyCode == Enum.KeyCode.N then if waypoint then doTP(waypoint) targetLbl.Text = '<font color="#55FF55">TP >> Waypoint</font>' end end if inp.KeyCode == Enum.KeyCode.Delete then waypoint = nil wpLbl.Text = '<font color="#888888">WP: None [B]=Set [N]=Go</font>' end end) -- RIGHT CLICK to TP mouse.Button2Down:Connect(function() if not enabled then return end local hit = mouse.Hit if hit then doTP(hit.Position) local p = hit.Position targetLbl.Text = string.format('<font color="#AA55FF">TP >> %d, %d, %d</font>', math.floor(p.X), math.floor(p.Y), math.floor(p.Z)) end end) ------------------------------------------------------------------------ -- UPDATE ------------------------------------------------------------------------ rs.RenderStepped:Connect(function() if not grab() then return end local p = hrp.Position coordsLbl.Text = string.format("Pos: %d, %d, %d", math.floor(p.X), math.floor(p.Y), math.floor(p.Z)) -- show mouse target coords if enabled then local mh = mouse.Hit if mh then local mp = mh.Position local dist = (mp - p).Magnitude targetLbl.Text = string.format( '<font color="#FFFF55">Target: %d,%d,%d</font> <font color="#888">Dist: %d</font>', math.floor(mp.X), math.floor(mp.Y), math.floor(mp.Z), math.floor(dist) ) end end end) print("[TP v2] Loaded | RClick=TP | T=Toggle | P=Players | B=SetWP | N=GoWP")
Editor Settings
Theme
Key bindings
Full width
Lines