local Players = game:GetService("Players") local UserInputService = game:GetService("UserInputService") local TweenService = game:GetService("TweenService") local RunService = game:GetService("RunService") local SoundService = game:GetService("SoundService") local Workspace = game:GetService("Workspace") local ContextActionService = game:GetService("ContextActionService") local player = Players.LocalPlayer local playerGui = player:WaitForChild("PlayerGui") local CONFIG = { RANGE = 80, SCAN_RATE = 0.05, TRACK_NPCS = true, BEEP_ID = "rbxassetid://139867692076286", BEEP_VOLUME = 0.6, BEEP_FAR = 2.0, BEEP_NEAR = 0.15, PITCH_FAR = 0.9, PITCH_NEAR = 1.8, HUD_SIZE = 230, HUD_OFFSET = 16, HUD_TRANS = 0, DOT_SIZE = 9, SWEEP_SPEED = 180, PULSE_SPEED = 1.2, } local MAX_BLIPS = 20 local TWEEN_TIME = 0.2 local RADAR_MIN_SIZE = 150 local RADAR_MAX_SIZE = 400 local RADAR_DEF_SIZE = 230 local SLIDER_PANEL_W = 60 local SLIDER_PANEL_H = 220 local SLIDER_BAR_W = 6 local SLIDER_BAR_H = 160 local SLIDER_GAP_X = 10 local COL_BG = Color3.fromRGB(0, 0, 0) local COL_RING = Color3.fromRGB(180, 180, 185) local COL_ACCENT = Color3.fromRGB(0, 220, 200) local COL_SELF = Color3.fromRGB(255, 255, 255) local COL_ENEMY = Color3.fromRGB(255, 50, 50) local COL_DANGER = Color3.fromRGB(255, 40, 40) local BTN_OFF_BG = Color3.fromRGB(25, 25, 28) local BTN_OFF_TEXT = Color3.fromRGB(200, 200, 200) local BTN_OFF_STROKE = Color3.fromRGB(60, 60, 65) local BTN_ON_BG = Color3.fromRGB(0, 45, 40) local BTN_ON_TEXT = Color3.fromRGB(0, 220, 200) local BTN_ON_STROKE = Color3.fromRGB(0, 200, 180) local BTN_HEIGHT = 32 local BTN_GAP = 8 local BTN_PAD_TOP = 70 local BTN_COUNT = 4 local HUB_HEIGHT = BTN_PAD_TOP + (BTN_HEIGHT * BTN_COUNT) + (BTN_GAP * (BTN_COUNT - 1)) + 12 local HUB_WIDTH = 220 local HUB_MIN_H = 48 local GENV = (getgenv and getgenv()) or _G if GENV.LonelyHub and GENV.LonelyHub.Destroy then pcall(GENV.LonelyHub.Destroy) end local connections = {} local npcs = {} local beepSound local radarHUD, radarDisplay, radarContainer, radarScale local radarBtn, soundBtn, moveRadarBtn, sizeBtn local radarEnabled = true local soundEnabled = true local targets = {} local nearestDist = nil local scanAcc, beepAcc, sweepAngle, pulseT = 0, 0, 0, 0 local minimized = false local wasEmpty = true local radarLocked = true local radarDragging = false local radarDragInput = nil local hubDragInput = nil local sliderOpen = false local sliderDragging = false local sliderDragInput = nil local currentRadarSize = RADAR_DEF_SIZE local function track(c) table.insert(connections, c) return c end local function create(class, props, parent) local inst = Instance.new(class) for k, v in pairs(props) do inst[k] = v end inst.Parent = parent return inst end local function getGuiParent() local ok, ui = pcall(function() return gethui and gethui() end) if ok and ui then return ui end local ok2, core = pcall(function() return game:GetService("CoreGui") end) if ok2 and core then local probe = Instance.new("Folder") local can = pcall(function() probe.Parent = core end) probe:Destroy() if can then return core end end return playerGui end local function isDragInput(input) return input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch end if CONFIG.TRACK_NPCS then task.spawn(function() local n = 0 for _, inst in ipairs(Workspace:GetDescendants()) do if inst:IsA("Humanoid") then npcs[inst] = true end n += 1 if n % 1500 == 0 then task.wait() end end end) track(Workspace.DescendantAdded:Connect(function(inst) if inst:IsA("Humanoid") then npcs[inst] = true end end)) track(Workspace.DescendantRemoving:Connect(function(inst) if npcs[inst] then npcs[inst] = nil end end)) end local function sinkCamera() ContextActionService:BindActionAtPriority( "LonelySliderSink", function() return Enum.ContextActionResult.Sink end, false, Enum.ContextActionPriority.High.Value, Enum.UserInputType.Touch, Enum.UserInputType.MouseButton1 ) end local function unsinkCamera() ContextActionService:UnbindAction("LonelySliderSink") end local function buildRadarHUD() if radarHUD then radarHUD:Destroy() end radarHUD = create("ScreenGui", { Name = "RadarHUD", ResetOnSpawn = false, ZIndexBehavior = Enum.ZIndexBehavior.Sibling, }, getGuiParent()) local size = CONFIG.HUD_SIZE local off = CONFIG.HUD_OFFSET local dotSize = CONFIG.DOT_SIZE radarContainer = create("Frame", { Size = UDim2.fromOffset(size, size), Position = UDim2.new(1, -size - off, 0, off), BackgroundColor3 = COL_BG, BackgroundTransparency = CONFIG.HUD_TRANS, BorderSizePixel = 0, }, radarHUD) create("UICorner", { CornerRadius = UDim.new(1, 0) }, radarContainer) local outerStroke = create("UIStroke", { Color = COL_ACCENT, Thickness = 2 }, radarContainer) radarScale = create("UIScale", { Scale = currentRadarSize / size }, radarContainer) local scope = create("Frame", { Size = UDim2.fromScale(1, 1), BackgroundColor3 = COL_BG, BackgroundTransparency = CONFIG.HUD_TRANS, BorderSizePixel = 0, ClipsDescendants = true, }, radarContainer) create("UICorner", { CornerRadius = UDim.new(1, 0) }, scope) for _, f in ipairs({ 0.75, 0.5, 0.25 }) do local ring = create("Frame", { Size = UDim2.fromScale(f, f), AnchorPoint = Vector2.new(0.5, 0.5), Position = UDim2.fromScale(0.5, 0.5), BackgroundTransparency = 1, ZIndex = 1, }, scope) create("UICorner", { CornerRadius = UDim.new(0.5, 0) }, ring) create("UIStroke", { Color = COL_RING, Thickness = 1, Transparency = 0.25 }, ring) end local pulseRing = create("Frame", { AnchorPoint = Vector2.new(0.5, 0.5), Position = UDim2.fromScale(0.5, 0.5), Size = UDim2.fromScale(0.01, 0.01), BackgroundTransparency = 1, ZIndex = 2, }, scope) create("UICorner", { CornerRadius = UDim.new(0.5, 0) }, pulseRing) local pulseStroke = create("UIStroke", { Color = COL_ACCENT, Thickness = 2, Transparency = 1 }, pulseRing) local sweepHolder = create("Frame", { Size = UDim2.fromScale(1, 1), BackgroundTransparency = 1, ZIndex = 3, }, scope) local sweepLine = create("Frame", { AnchorPoint = Vector2.new(0.5, 1), Position = UDim2.fromScale(0.5, 0.5), Size = UDim2.new(0, 2, 0.5, 0), BackgroundColor3 = COL_ACCENT, BackgroundTransparency = 0.2, BorderSizePixel = 0, ZIndex = 3, }, sweepHolder) local selfDot = create("Frame", { AnchorPoint = Vector2.new(0.5, 0.5), Position = UDim2.fromScale(0.5, 0.5), Size = UDim2.fromOffset(10, 10), BackgroundColor3 = COL_SELF, BorderSizePixel = 0, ZIndex = 7, }, scope) create("UICorner", { CornerRadius = UDim.new(1, 0) }, selfDot) local blips = {} for i = 1, MAX_BLIPS do local dot = create("Frame", { AnchorPoint = Vector2.new(0.5, 0.5), Size = UDim2.fromOffset(dotSize, dotSize), BackgroundColor3 = COL_ENEMY, BorderSizePixel = 0, Visible = false, ZIndex = 5, }, scope) create("UICorner", { CornerRadius = UDim.new(1, 0) }, dot) local stroke = create("UIStroke", { Color = COL_DANGER, Thickness = 2, Enabled = false, Transparency = 0, }, dot) blips[i] = { dot = dot, stroke = stroke } end local detectStroke = create("UIStroke", { Color = COL_DANGER, Thickness = 0, Transparency = 1, }, radarContainer) local statusText = create("TextLabel", { Position = UDim2.new(0, 0, 1, -22), Size = UDim2.new(1, 0, 0, 18), BackgroundTransparency = 1, Font = Enum.Font.GothamBold, TextSize = 11, TextColor3 = COL_ACCENT, Text = "SAFE ZONE", ZIndex = 9, }, scope) radarDisplay = { blips = blips, stroke = outerStroke, status = statusText, sweepHolder = sweepHolder, sweepLine = sweepLine, pulseRing = pulseRing, pulseStroke = pulseStroke, detectStroke = detectStroke, } track(radarContainer.InputBegan:Connect(function(input) if radarLocked then return end if isDragInput(input) then radarDragging = true radarDragInput = input end end)) end local sizePanel local sizeSliderBar, sizeSliderFill, sizeSliderKnob, sizeValueLabel local function repositionSizePanel() if not sizePanel or not radarContainer then return end local abs = radarContainer.AbsolutePosition local sz = radarContainer.AbsoluteSize.X sizePanel.Position = UDim2.fromOffset( abs.X - SLIDER_PANEL_W - SLIDER_GAP_X, abs.Y + (sz - SLIDER_PANEL_H) / 2 ) end local function buildSizePanel() if sizePanel then sizePanel:Destroy() end sizePanel = create("Frame", { Name = "SizePanel", Size = UDim2.fromOffset(SLIDER_PANEL_W, SLIDER_PANEL_H), Position = UDim2.new(0, 0, 0, 0), BackgroundColor3 = Color3.fromRGB(18, 18, 20), BackgroundTransparency = 0.15, BorderSizePixel = 0, Visible = false, ZIndex = 20, Active = true, }, radarHUD) create("UICorner", { CornerRadius = UDim.new(0, 12) }, sizePanel) create("UIStroke", { Color = COL_ACCENT, Thickness = 1, Transparency = 0.4 }, sizePanel) sizeValueLabel = create("TextLabel", { Position = UDim2.new(0, 0, 0, 6), Size = UDim2.new(1, 0, 0, 20), BackgroundTransparency = 1, Font = Enum.Font.GothamBold, TextSize = 12, TextColor3 = COL_ACCENT, Text = tostring(currentRadarSize), ZIndex = 21, }, sizePanel) sizeSliderBar = create("Frame", { AnchorPoint = Vector2.new(0.5, 0.5), Position = UDim2.new(0.5, 0, 0.5, 5), Size = UDim2.fromOffset(SLIDER_BAR_W, SLIDER_BAR_H), BackgroundColor3 = Color3.fromRGB(40, 40, 44), BorderSizePixel = 0, ZIndex = 21, Active = true, }, sizePanel) create("UICorner", { CornerRadius = UDim.new(1, 0) }, sizeSliderBar) sizeSliderFill = create("Frame", { AnchorPoint = Vector2.new(0.5, 1), Position = UDim2.fromScale(0.5, 1), Size = UDim2.new(1, 0, 0.5, 0), BackgroundColor3 = COL_ACCENT, BorderSizePixel = 0, ZIndex = 21, }, sizeSliderBar) create("UICorner", { CornerRadius = UDim.new(1, 0) }, sizeSliderFill) sizeSliderKnob = create("Frame", { AnchorPoint = Vector2.new(0.5, 0.5), Position = UDim2.new(0.5, 0, 0.5, 0), Size = UDim2.fromOffset(22, 22), BackgroundColor3 = COL_ACCENT, BorderSizePixel = 0, ZIndex = 22, }, sizeSliderBar) create("UICorner", { CornerRadius = UDim.new(1, 0) }, sizeSliderKnob) create("UIStroke", { Color = Color3.fromRGB(0, 0, 0), Thickness = 2 }, sizeSliderKnob) end local function updateSliderVisuals() local t = (currentRadarSize - RADAR_MIN_SIZE) / (RADAR_MAX_SIZE - RADAR_MIN_SIZE) t = math.clamp(t, 0, 1) sizeSliderFill.Size = UDim2.new(1, 0, t, 0) sizeSliderKnob.Position = UDim2.new(0.5, 0, 1 - t, 0) sizeValueLabel.Text = tostring(math.floor(currentRadarSize + 0.5)) end local function applyRadarSize(newSize) currentRadarSize = math.clamp(newSize, RADAR_MIN_SIZE, RADAR_MAX_SIZE) if radarScale then radarScale.Scale = currentRadarSize / CONFIG.HUD_SIZE end if sizePanel and sizePanel.Visible then updateSliderVisuals() repositionSizePanel() end end local function sliderSetFromScreenY(screenY) if not sizeSliderBar then return end local barY = sizeSliderBar.AbsolutePosition.Y local barH = sizeSliderBar.AbsoluteSize.Y if barH <= 0 then return end local rel = math.clamp((screenY - barY) / barH, 0, 1) local newSize = RADAR_MAX_SIZE - rel * (RADAR_MAX_SIZE - RADAR_MIN_SIZE) applyRadarSize(newSize) end local function startSliderDrag(input) sliderDragging = true sliderDragInput = input sinkCamera() local pos = input.Position if pos then sliderSetFromScreenY(pos.Y) end end local function stopSliderDrag() if not sliderDragging then return end sliderDragging = false sliderDragInput = nil unsinkCamera() end local function bindSliderInputs() track(sizeSliderBar.InputBegan:Connect(function(input) if isDragInput(input) then startSliderDrag(input) end end)) track(sizeSliderKnob.InputBegan:Connect(function(input) if isDragInput(input) then startSliderDrag(input) end end)) track(sizePanel.InputBegan:Connect(function(input) if isDragInput(input) and sizeSliderBar then startSliderDrag(input) end end)) end track(UserInputService.InputChanged:Connect(function(input) if not sliderDragging or input ~= sliderDragInput then return end if input.UserInputType == Enum.UserInputType.Touch then sliderSetFromScreenY(input.Position.Y) elseif input.UserInputType == Enum.UserInputType.MouseMovement then sliderSetFromScreenY(input.Position.Y) end end)) track(UserInputService.InputEnded:Connect(function(input) if sliderDragging and input == sliderDragInput then if isDragInput(input) then stopSliderDrag() end end end)) track(UserInputService.WindowFocusReleased:Connect(function() stopSliderDrag() end)) track(UserInputService.InputChanged:Connect(function(input) if not radarDragging then return end if input ~= radarDragInput then return end if input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch then local delta = input.Delta local pos = radarContainer.Position radarContainer.Position = UDim2.new( pos.X.Scale, pos.X.Offset + delta.X, pos.Y.Scale, pos.Y.Offset + delta.Y ) repositionSizePanel() end end)) track(UserInputService.InputEnded:Connect(function(input) if input ~= radarDragInput then return end if isDragInput(input) then radarDragging = false radarDragInput = nil end end)) local function scan() if not radarDisplay then return end local char = player.Character local hrp = char and char:FindFirstChild("HumanoidRootPart") if not hrp then nearestDist = nil; return end local playerPos = hrp.Position local camera = Workspace.CurrentCamera local camCF if camera then local look = camera.CFrame.LookVector local flatLook = Vector3.new(look.X, 0, look.Z) if flatLook.Magnitude < 0.01 then flatLook = Vector3.new(0, 0, -1) end flatLook = flatLook.Unit camCF = CFrame.new(playerPos, playerPos + flatLook) else camCF = hrp.CFrame end local R = CONFIG.RANGE local nearest = nil table.clear(targets) local function consider(root) local pos = root.Position local rel = camCF:PointToObjectSpace(pos) local dist = (pos - playerPos).Magnitude if dist > R then return end if not nearest or dist < nearest then nearest = dist end table.insert(targets, { nx = 0.5 + rel.X / (2 * R), ny = 0.5 + rel.Z / (2 * R), dist = dist, }) end for _, plr in ipairs(Players:GetPlayers()) do if plr ~= player then local c = plr.Character local root = c and c:FindFirstChild("HumanoidRootPart") if root then consider(root) end end end if CONFIG.TRACK_NPCS then for hum in pairs(npcs) do local model = hum.Parent if model and hum.Health > 0 and model ~= char and not Players:GetPlayerFromCharacter(model) then local root = model:FindFirstChild("HumanoidRootPart") or model.PrimaryPart if root and root:IsA("BasePart") then consider(root) end end end end table.sort(targets, function(a, b) return a.dist < b.dist end) nearestDist = nearest for i = 1, MAX_BLIPS do local entry = radarDisplay.blips[i] local t = targets[i] if t then entry.dot.Visible = true entry.dot.Position = UDim2.fromScale(t.nx, t.ny) else entry.dot.Visible = false entry.stroke.Enabled = false end end end local function beepInterval(dist) local t = math.clamp(1 - dist / CONFIG.RANGE, 0, 1) return CONFIG.BEEP_FAR + (CONFIG.BEEP_NEAR - CONFIG.BEEP_FAR) * t, t end beepSound = create("Sound", { Name = "RadarBeep", SoundId = CONFIG.BEEP_ID, Volume = CONFIG.BEEP_VOLUME, RollOffMode = Enum.RollOffMode.Linear, }, SoundService) track(RunService.Heartbeat:Connect(function(dt) if radarEnabled and radarDisplay then sweepAngle = (sweepAngle + CONFIG.SWEEP_SPEED * dt) % 360 radarDisplay.sweepHolder.Rotation = sweepAngle pulseT = (pulseT + dt * CONFIG.PULSE_SPEED) % 1 radarDisplay.pulseRing.Size = UDim2.fromScale(pulseT, pulseT) radarDisplay.pulseStroke.Transparency = pulseT scanAcc += dt if scanAcc >= CONFIG.SCAN_RATE then scanAcc = 0 scan() end local hasEnemy = #targets > 0 if hasEnemy then radarDisplay.stroke.Color = COL_DANGER radarDisplay.status.Text = "ENEMY DETECTED" radarDisplay.status.TextColor3 = COL_DANGER radarDisplay.sweepLine.BackgroundColor3 = COL_DANGER radarDisplay.pulseStroke.Color = COL_DANGER else radarDisplay.stroke.Color = COL_ACCENT radarDisplay.status.Text = "SAFE ZONE" radarDisplay.status.TextColor3 = COL_ACCENT radarDisplay.sweepLine.BackgroundColor3 = COL_ACCENT radarDisplay.pulseStroke.Color = COL_ACCENT end if hasEnemy and wasEmpty then radarDisplay.detectStroke.Thickness = 10 radarDisplay.detectStroke.Transparency = 0 TweenService:Create( radarDisplay.detectStroke, TweenInfo.new(0.9, Enum.EasingStyle.Quad, Enum.EasingDirection.Out), { Thickness = 0, Transparency = 1 } ):Play() end wasEmpty = not hasEnemy local first = radarDisplay.blips[1] if hasEnemy and first.dot.Visible then local p = (math.sin(tick() * 6) + 1) / 2 first.stroke.Enabled = true first.stroke.Transparency = 0.2 + (1 - p) * 0.6 else first.stroke.Enabled = false end end if soundEnabled and radarEnabled and nearestDist then local interval, t = beepInterval(nearestDist) beepAcc += dt if beepAcc >= interval then beepAcc = 0 beepSound.PlaybackSpeed = CONFIG.PITCH_FAR + (CONFIG.PITCH_NEAR - CONFIG.PITCH_FAR) * t beepSound:Play() end else beepAcc = math.huge end end)) local ScreenGui = Instance.new("ScreenGui") ScreenGui.Name = "LonelyHub" ScreenGui.ResetOnSpawn = false ScreenGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling ScreenGui.Parent = getGuiParent() local MainFrame = create("Frame", { Name = "MainFrame", Size = UDim2.fromOffset(HUB_WIDTH, HUB_HEIGHT), Position = UDim2.new(0.05, 0, 0.4, 0), BackgroundColor3 = Color3.fromRGB(0, 0, 0), BorderSizePixel = 0, Active = true, }, ScreenGui) create("UICorner", { CornerRadius = UDim.new(0, 12) }, MainFrame) create("TextLabel", { BackgroundTransparency = 1, Position = UDim2.fromOffset(35, 8), Size = UDim2.new(1, -70, 0, 30), Text = "LONELY HUB", TextColor3 = Color3.fromRGB(255, 255, 255), Font = Enum.Font.GothamBold, TextSize = 18, TextXAlignment = Enum.TextXAlignment.Center, }, MainFrame) local MinimizeButton = create("TextButton", { Position = UDim2.new(1, -32, 0, 10), Size = UDim2.fromOffset(23, 23), BackgroundTransparency = 1, Text = "-", TextColor3 = Color3.fromRGB(255, 255, 255), Font = Enum.Font.GothamBold, TextSize = 18, }, MainFrame) local Description = create("TextLabel", { BackgroundTransparency = 1, Position = UDim2.fromOffset(0, 40), Size = UDim2.new(1, 0, 0, 18), Text = "Property of Lonely", TextColor3 = Color3.fromRGB(200, 200, 200), Font = Enum.Font.Gotham, TextSize = 10, }, MainFrame) local ButtonContainer = create("Frame", { BackgroundTransparency = 1, Position = UDim2.fromOffset(12, BTN_PAD_TOP), Size = UDim2.new(1, -24, 0, (BTN_HEIGHT * BTN_COUNT) + (BTN_GAP * (BTN_COUNT - 1))), }, MainFrame) create("UIListLayout", { Padding = UDim.new(0, BTN_GAP), SortOrder = Enum.SortOrder.LayoutOrder, }, ButtonContainer) local function styleButton(btn, isOn) local stroke = btn:FindFirstChildOfClass("UIStroke") if isOn then btn.BackgroundColor3 = BTN_ON_BG btn.TextColor3 = BTN_ON_TEXT if stroke then stroke.Color = BTN_ON_STROKE end else btn.BackgroundColor3 = BTN_OFF_BG btn.TextColor3 = BTN_OFF_TEXT if stroke then stroke.Color = BTN_OFF_STROKE end end end local function makeToggleButton(text, order) local btn = create("TextButton", { Size = UDim2.new(1, 0, 0, BTN_HEIGHT), BackgroundColor3 = BTN_OFF_BG, Text = text, TextColor3 = BTN_OFF_TEXT, Font = Enum.Font.GothamBold, TextSize = 13, AutoButtonColor = false, LayoutOrder = order, BorderSizePixel = 0, }, ButtonContainer) create("UICorner", { CornerRadius = UDim.new(0, 8) }, btn) create("UIStroke", { Color = BTN_OFF_STROKE, Thickness = 1 }, btn) return btn end radarBtn = makeToggleButton("Radar", 1) styleButton(radarBtn, radarEnabled) soundBtn = makeToggleButton("Sound", 2) styleButton(soundBtn, soundEnabled) moveRadarBtn = makeToggleButton("Move Radar", 3) styleButton(moveRadarBtn, not radarLocked) sizeBtn = makeToggleButton("Radar Size", 4) styleButton(sizeBtn, sliderOpen) track(radarBtn.Activated:Connect(function() radarEnabled = not radarEnabled styleButton(radarBtn, radarEnabled) if radarHUD then radarHUD.Enabled = radarEnabled end if sizePanel then sizePanel.Visible = radarEnabled and sliderOpen if sizePanel.Visible then repositionSizePanel() end end end)) track(soundBtn.Activated:Connect(function() soundEnabled = not soundEnabled styleButton(soundBtn, soundEnabled) end)) track(moveRadarBtn.Activated:Connect(function() radarLocked = not radarLocked if radarLocked then moveRadarBtn.Text = "Move Radar" else moveRadarBtn.Text = "Lock Radar" end styleButton(moveRadarBtn, not radarLocked) end)) track(sizeBtn.Activated:Connect(function() sliderOpen = not sliderOpen styleButton(sizeBtn, sliderOpen) if sizePanel then sizePanel.Visible = radarEnabled and sliderOpen if sliderOpen then updateSliderVisuals() repositionSizePanel() end end end)) local function animate(object, properties) TweenService:Create( object, TweenInfo.new(TWEEN_TIME, Enum.EasingStyle.Quart, Enum.EasingDirection.Out), properties ):Play() end track(MinimizeButton.Activated:Connect(function() minimized = not minimized if minimized then Description.Visible = false ButtonContainer.Visible = false MinimizeButton.Text = "+" animate(MainFrame, { Size = UDim2.fromOffset(HUB_WIDTH, HUB_MIN_H) }) else animate(MainFrame, { Size = UDim2.fromOffset(HUB_WIDTH, HUB_HEIGHT) }) MinimizeButton.Text = "-" task.delay(TWEEN_TIME, function() if not minimized then Description.Visible = true ButtonContainer.Visible = true end end) end end)) track(MainFrame.InputBegan:Connect(function(input) if isDragInput(input) then hubDragInput = input end end)) track(UserInputService.InputChanged:Connect(function(input) if not hubDragInput then return end if input ~= hubDragInput then return end if input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch then local delta = input.Delta local pos = MainFrame.Position MainFrame.Position = UDim2.new( pos.X.Scale, pos.X.Offset + delta.X, pos.Y.Scale, pos.Y.Offset + delta.Y ) end end)) track(UserInputService.InputEnded:Connect(function(input) if input ~= hubDragInput then return end if isDragInput(input) then hubDragInput = nil end end)) buildRadarHUD() buildSizePanel() bindSliderInputs() applyRadarSize(currentRadarSize) repositionSizePanel() GENV.LonelyHub = { Destroy = function() stopSliderDrag() for _, c in ipairs(connections) do pcall(function() c:Disconnect() end) end table.clear(connections) if beepSound then beepSound:Destroy() end if radarHUD then radarHUD:Destroy() end if ScreenGui then ScreenGui:Destroy() end GENV.LonelyHub = nil end }