local Players = game:GetService("Players") local RunService = game:GetService("RunService") local UserInputService = game:GetService("UserInputService") local player = Players.LocalPlayer local mouse = player:GetMouse() local screenGui = Instance.new("ScreenGui") screenGui.Name = "FlingTPUI" screenGui.ResetOnSpawn = false screenGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling screenGui.Parent = game.CoreGui local triggerBtn = Instance.new("TextButton") triggerBtn.Size = UDim2.new(0, 90, 0, 26) triggerBtn.Position = UDim2.new(0, 8, 0.5, 0) triggerBtn.BackgroundColor3 = Color3.fromRGB(24, 24, 24) triggerBtn.BorderSizePixel = 1 triggerBtn.BorderColor3 = Color3.fromRGB(80, 80, 80) triggerBtn.Text = "FlingTP" triggerBtn.Font = Enum.Font.SourceSansSemibold triggerBtn.TextSize = 13 triggerBtn.TextColor3 = Color3.fromRGB(230, 230, 230) triggerBtn.Parent = screenGui local main = Instance.new("Frame") main.Size = UDim2.new(0, 300, 0, 320) main.Position = UDim2.new(0.5, -150, 0.2, 0) main.BackgroundColor3 = Color3.fromRGB(34, 34, 34) main.BorderSizePixel = 0 main.Visible = false main.Parent = screenGui local titlebar = Instance.new("Frame") titlebar.Size = UDim2.new(1, 0, 0, 34) titlebar.BackgroundColor3 = Color3.fromRGB(24, 24, 24) titlebar.BorderSizePixel = 0 titlebar.Parent = main local titleLabel = Instance.new("TextLabel") titleLabel.Size = UDim2.new(0.75, 0, 1, 0) titleLabel.Position = UDim2.new(0, 8, 0, 0) titleLabel.BackgroundTransparency = 1 titleLabel.Text = "Fling Teleport" titleLabel.TextColor3 = Color3.fromRGB(230, 230, 230) titleLabel.Font = Enum.Font.SourceSansSemibold titleLabel.TextSize = 14 titleLabel.TextXAlignment = Enum.TextXAlignment.Left titleLabel.Parent = titlebar local btnClose = Instance.new("TextButton") btnClose.Size = UDim2.new(0, 36, 0, 22) btnClose.Position = UDim2.new(1, -44, 0, 6) btnClose.BackgroundColor3 = Color3.fromRGB(38, 38, 38) btnClose.BorderSizePixel = 1 btnClose.BorderColor3 = Color3.fromRGB(80, 80, 80) btnClose.Text = "X" btnClose.Font = Enum.Font.SourceSansSemibold btnClose.TextSize = 13 btnClose.TextColor3 = Color3.fromRGB(230, 230, 230) btnClose.Parent = titlebar local content = Instance.new("Frame") content.Size = UDim2.new(1, -16, 1, -42) content.Position = UDim2.new(0, 8, 0, 40) content.BackgroundTransparency = 1 content.Parent = main local function makeLabel(text, yPos) local l = Instance.new("TextLabel") l.Size = UDim2.new(1, 0, 0, 16) l.Position = UDim2.new(0, 0, 0, yPos) l.BackgroundTransparency = 1 l.Font = Enum.Font.SourceSans l.TextSize = 12 l.TextColor3 = Color3.fromRGB(200, 200, 200) l.TextXAlignment = Enum.TextXAlignment.Left l.Text = text l.Parent = content return l end local function makeInput(yPos, placeholder, default) local box = Instance.new("TextBox") box.Size = UDim2.new(1, 0, 0, 26) box.Position = UDim2.new(0, 0, 0, yPos) box.BackgroundColor3 = Color3.fromRGB(28, 28, 28) box.BorderSizePixel = 1 box.BorderColor3 = Color3.fromRGB(70, 70, 70) box.Font = Enum.Font.Code box.TextSize = 12 box.TextColor3 = Color3.new(1, 1, 1) box.PlaceholderText = placeholder box.PlaceholderColor3 = Color3.fromRGB(90, 90, 90) box.ClearTextOnFocus = false box.Text = default or "0" box.Parent = content return box end makeLabel("X", 0) local xBox = makeInput(16, "0") makeLabel("Y", 48) local yBox = makeInput(64, "0") makeLabel("Z", 96) local zBox = makeInput(112, "0") makeLabel("Air time (seconds)", 144) local timeBox = makeInput(160, "0.6", "0.6") local pickerBtn = Instance.new("TextButton") pickerBtn.Size = UDim2.new(1, 0, 0, 26) pickerBtn.Position = UDim2.new(0, 0, 0, 194) pickerBtn.BackgroundColor3 = Color3.fromRGB(38, 38, 38) pickerBtn.BorderSizePixel = 1 pickerBtn.BorderColor3 = Color3.fromRGB(70, 70, 70) pickerBtn.Font = Enum.Font.SourceSansSemibold pickerBtn.TextSize = 13 pickerBtn.TextColor3 = Color3.fromRGB(200, 200, 255) pickerBtn.Text = "[ Pick Location ]" pickerBtn.Parent = content local flingBtn = Instance.new("TextButton") flingBtn.Size = UDim2.new(1, 0, 0, 30) flingBtn.Position = UDim2.new(0, 0, 0, 228) flingBtn.BackgroundColor3 = Color3.fromRGB(38, 38, 38) flingBtn.BorderSizePixel = 1 flingBtn.BorderColor3 = Color3.fromRGB(180, 30, 30) flingBtn.Font = Enum.Font.SourceSansSemibold flingBtn.TextSize = 14 flingBtn.TextColor3 = Color3.fromRGB(255, 80, 80) flingBtn.Text = "[ Fling Go ]" flingBtn.Parent = content local statusLabel = Instance.new("TextLabel") statusLabel.Size = UDim2.new(1, 0, 0, 16) statusLabel.Position = UDim2.new(0, 0, 0, 266) statusLabel.BackgroundTransparency = 1 statusLabel.Font = Enum.Font.Code statusLabel.TextSize = 11 statusLabel.TextColor3 = Color3.fromRGB(0, 200, 100) statusLabel.TextXAlignment = Enum.TextXAlignment.Left statusLabel.Text = "ready." statusLabel.Parent = content local markerPart = nil local function removeMarker() if markerPart then markerPart:Destroy() markerPart = nil end end local function placeMarker(pos) removeMarker() local part = Instance.new("Part") part.Size = Vector3.new(0.3, 9999, 0.3) part.CFrame = CFrame.new(pos.X, 0, pos.Z) part.Anchored = true part.CanCollide = false part.CanQuery = false part.CanTouch = false part.CastShadow = false part.BrickColor = BrickColor.new("Bright red") part.Material = Enum.Material.Neon part.Parent = workspace markerPart = part xBox.Text = tostring(math.round(pos.X)) yBox.Text = tostring(math.round(pos.Y)) zBox.Text = tostring(math.round(pos.Z)) statusLabel.Text = "marker: " .. math.round(pos.X) .. ", " .. math.round(pos.Y) .. ", " .. math.round(pos.Z) statusLabel.TextColor3 = Color3.fromRGB(0, 200, 100) end local tool = Instance.new("Tool") tool.Name = "FlingMarker" tool.RequiresHandle = false tool.ToolTip = "Click to place fling marker" tool.Parent = player.Backpack tool.Equipped:Connect(function() pickerBtn.Text = "[ Tool Active - Click World ]" pickerBtn.TextColor3 = Color3.fromRGB(255, 100, 100) statusLabel.Text = "tool equipped. click to place." end) tool.Unequipped:Connect(function() pickerBtn.Text = "[ Pick Location ]" pickerBtn.TextColor3 = Color3.fromRGB(200, 200, 255) end) tool.Activated:Connect(function() if mouse.Hit then placeMarker(mouse.Hit.Position) end end) local pickingMode = false local clickConn = nil local function stopPicking() pickingMode = false pickerBtn.Text = "[ Pick Location ]" pickerBtn.TextColor3 = Color3.fromRGB(200, 200, 255) mouse.Icon = "" if clickConn then clickConn:Disconnect() clickConn = nil end end pickerBtn.MouseButton1Click:Connect(function() if pickingMode then stopPicking() return end pickingMode = true pickerBtn.Text = "[ Click World to Place... ]" pickerBtn.TextColor3 = Color3.fromRGB(255, 100, 100) mouse.Icon = "rbxasset://textures/Cursors/CrossHair.png" clickConn = mouse.Button1Down:Connect(function() local target = mouse.Target if target and not target:IsDescendantOf(screenGui) then placeMarker(mouse.Hit.Position) stopPicking() end end) end) local function doFlingTP(targetX, targetY, targetZ, airTime) local char = player.Character if not char then return end local hrp = char:FindFirstChild("HumanoidRootPart") local hum = char:FindFirstChild("Humanoid") if not hrp or not hum then return end local g = workspace.Gravity local op = hrp.Position local dx = targetX - op.X local dy = targetY - op.Y local dz = targetZ - op.Z local vx = dx / airTime local vz = dz / airTime local vy = (dy + 0.5 * g * airTime * airTime) / airTime local spinMag = math.clamp(Vector2.new(dx, dz).Magnitude * 0.3, 80, 500) hum.PlatformStand = true hrp:PivotTo(hrp:GetPivot() + Vector3.new(0, 1, 0)) hrp.AssemblyLinearVelocity = Vector3.new(vx, vy, vz) hrp.AssemblyAngularVelocity = Vector3.new( math.random(-1, 1) * spinMag, math.random(-1, 1) * spinMag * 0.4, math.random(-1, 1) * spinMag ) statusLabel.Text = string.format("v: %.1f, %.1f, %.1f | t: %.2fs", vx, vy, vz, airTime) statusLabel.TextColor3 = Color3.fromRGB(255, 200, 0) local threshold = math.max(4, Vector2.new(dx, dz).Magnitude * 0.04) local elapsed = 0 local conn conn = RunService.Heartbeat:Connect(function(dt) elapsed += dt if elapsed < airTime * 0.4 then return end local pos = hrp.Position local xzDist = Vector2.new(pos.X - targetX, pos.Z - targetZ).Magnitude if xzDist <= threshold then hrp.AssemblyLinearVelocity = Vector3.zero hrp.AssemblyAngularVelocity = Vector3.zero hum.PlatformStand = false hum:ChangeState(Enum.HumanoidStateType.GettingUp) hum:SetStateEnabled(Enum.HumanoidStateType.FallingDown, false) hum:SetStateEnabled(Enum.HumanoidStateType.Ragdoll, false) task.delay(0.1, function() hum:ChangeState(Enum.HumanoidStateType.Landed) hum:SetStateEnabled(Enum.HumanoidStateType.FallingDown, true) hum:SetStateEnabled(Enum.HumanoidStateType.Ragdoll, true) end) statusLabel.Text = "landed. xz err: " .. string.format("%.2f", xzDist) statusLabel.TextColor3 = Color3.fromRGB(0, 200, 100) conn:Disconnect() end if elapsed > airTime + 2 then hum.PlatformStand = false hum:SetStateEnabled(Enum.HumanoidStateType.FallingDown, true) hum:SetStateEnabled(Enum.HumanoidStateType.Ragdoll, true) statusLabel.Text = "timeout." statusLabel.TextColor3 = Color3.fromRGB(255, 80, 80) conn:Disconnect() end end) removeMarker() end flingBtn.MouseButton1Click:Connect(function() local x = tonumber(xBox.Text) local y = tonumber(yBox.Text) local z = tonumber(zBox.Text) local t = tonumber(timeBox.Text) if not x or not y or not z or not t or t <= 0 then statusLabel.Text = "invalid input." statusLabel.TextColor3 = Color3.fromRGB(255, 80, 80) return end doFlingTP(x, y, z, t) end) triggerBtn.MouseButton1Click:Connect(function() main.Visible = not main.Visible end) btnClose.MouseButton1Click:Connect(function() main.Visible = false end) local dragging, dragStartPos, guiStartPos = false, nil, nil titlebar.InputBegan:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseButton1 then dragging = true dragStartPos = input.Position guiStartPos = main.Position input.Changed:Connect(function() if input.UserInputState == Enum.UserInputState.End then dragging = false end end) end end) UserInputService.InputChanged:Connect(function(input) if dragging and input.UserInputType == Enum.UserInputType.MouseMovement then local delta = input.Position - dragStartPos main.Position = UDim2.new( guiStartPos.X.Scale, guiStartPos.X.Offset + delta.X, guiStartPos.Y.Scale, guiStartPos.Y.Offset + delta.Y ) end end)