--[[ Hp Team Pro V1 - Menu gỡ lỗi / kiểm thử cho game Roblox tự xây dựng Loại: LocalScript Vị trí: StarterPlayer > StarterPlayerScripts Chỉ chạy trong Studio, với chủ game, hoặc UserId nằm trong CONFIG.DEV_USER_IDS. ]] --================================================================== -- [1] DỊCH VỤ --================================================================== local Players = game:GetService("Players") local RunService = game:GetService("RunService") local UserInputService = game:GetService("UserInputService") local ReplicatedStorage = game:GetService("ReplicatedStorage") local Lighting = game:GetService("Lighting") local player = Players.LocalPlayer local camera = workspace.CurrentCamera --================================================================== -- [2] CẤU HÌNH (chỉnh theo game thực tế) --================================================================== local CONFIG = { RANGE = 150, -- phạm vi quét (studs) TARGET_ROOT = workspace, -- thư mục chứa NPC/Mob (vd: workspace.Mobs) INCLUDE_PLAYERS = false, -- true nếu muốn coi người chơi khác là mục tiêu SCAN_INTERVAL = 0.5, -- chu kỳ quét lại danh sách Humanoid (giây) AIM_PART = "Head", -- bộ phận ngắm (không có sẽ dùng root) TELE_OFFSET = CFrame.new(0, 0, 4), -- vị trí đứng so với mục tiêu ATTACK_DELAY = 0.15, -- nhịp đánh Tele Kill (giây) FIRE_DELAY = 0.15, -- nhịp bắn Auto Bắn (giây) FIRE_EVENT_NAME = "FireEvent", -- RemoteEvent trong ReplicatedStorage: FireServer(origin, direction) FLY_SPEED = 50, FLY_MIN = 10, FLY_MAX = 200, FLY_STEP = 10, WALK_SPEED = 50, WALK_MIN = 16, WALK_MAX = 150, WALK_STEP = 8, DEV_USER_IDS = {}, -- thêm UserId được phép dùng menu } --================================================================== -- [3] KIỂM TRA QUYỀN (công cụ dev, không chạy với người chơi thường) --================================================================== local function isAuthorized() if RunService:IsStudio() then return true end if game.CreatorType == Enum.CreatorType.User and player.UserId == game.CreatorId then return true end return table.find(CONFIG.DEV_USER_IDS, player.UserId) ~= nil end if not isAuthorized() then return end --================================================================== -- [4] TRẠNG THÁI & QUẢN LÝ KẾT NỐI --================================================================== local GREEN = Color3.fromHex("00FF66") local BG_DARK = Color3.fromHex("0C0E0C") local BG_MID = Color3.fromHex("141814") local RED = Color3.fromRGB(255, 70, 70) local alive = true local connections = {} -- kết nối toàn cục của GUI local fconn = {} -- kết nối theo từng chức năng local active = {} -- [tên chức năng] = true khi đang bật local Features = {} -- [tên] = {start = fn, stop = fn} local toggleButtons = {} -- [tên] = TextButton local flyValue = CONFIG.FLY_SPEED local walkValue = CONFIG.WALK_SPEED local flyInput = { up = false, down = false } local function track(conn) table.insert(connections, conn) return conn end local function hold(name, conn) fconn[name] = fconn[name] or {} table.insert(fconn[name], conn) return conn end local function release(name) local list = fconn[name] if list then for _, c in ipairs(list) do c:Disconnect() end fconn[name] = nil end end --================================================================== -- [5] TIỆN ÍCH NHÂN VẬT & MỤC TIÊU --================================================================== local function getChar() return player.Character end local function getHumanoid() local char = getChar() return char and char:FindFirstChildOfClass("Humanoid") end local function getMyRoot() local char = getChar() return char and char:FindFirstChild("HumanoidRootPart") end local function getRoot(model) return model.PrimaryPart or model:FindFirstChild("HumanoidRootPart") end local function getAimPart(model) return model:FindFirstChild(CONFIG.AIM_PART) or getRoot(model) end local function isValidModel(model) if not model or not model.Parent or not model:IsA("Model") then return false end if model == getChar() then return false end local hum = model:FindFirstChildOfClass("Humanoid") if not hum or hum.Health <= 0 then return false end if not CONFIG.INCLUDE_PLAYERS and Players:GetPlayerFromCharacter(model) then return false end return getRoot(model) ~= nil end -- Danh sách Model có Humanoid, làm mới định kỳ (tránh quét mỗi khung hình) local modelSet = {} local function rescan() local newSet = {} for _, d in ipairs(CONFIG.TARGET_ROOT:GetDescendants()) do if d:IsA("Humanoid") and d.Parent and d.Parent:IsA("Model") then newSet[d.Parent] = true end end modelSet = newSet end task.spawn(function() while alive do rescan() task.wait(CONFIG.SCAN_INTERVAL) end end) -- Trả về mục tiêu hợp lệ gần nhất trong phạm vi local function nearestTarget() local myRoot = getMyRoot() if not myRoot then return nil, nil end local best, bestDist = nil, CONFIG.RANGE for model in pairs(modelSet) do if isValidModel(model) then local d = (getRoot(model).Position - myRoot.Position).Magnitude if d <= bestDist then best, bestDist = model, d end end end return best, bestDist end -- Bắn qua RemoteEvent với hướng đã chỉnh về mục tiêu. Trả về true nếu đã gửi. local function fireAt(model) local part = getAimPart(model) local myRoot = getMyRoot() if not part or not myRoot then return false end local char = getChar() local head = char and char:FindFirstChild("Head") local origin = (head or myRoot).Position local direction = (part.Position - origin).Unit local ev = ReplicatedStorage:FindFirstChild(CONFIG.FIRE_EVENT_NAME) if ev and ev:IsA("RemoteEvent") then ev:FireServer(origin, direction) return true end return false end -- Kích hoạt Tool đang cầm (đánh cận chiến / bắn bằng Tool) local function activateTool() local char = getChar() local tool = char and char:FindFirstChildOfClass("Tool") if tool then tool:Activate() end end --================================================================== -- [6] GUI GỐC --================================================================== local playerGui = player:WaitForChild("PlayerGui") for _, name in ipairs({ "HpTeamProV1", "HpTeamProEsp", "HpTeamProFly" }) do local old = playerGui:FindFirstChild(name) if old then old:Destroy() end end local function new(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 gui = new("ScreenGui", { Name = "HpTeamProV1", ResetOnSpawn = false, DisplayOrder = 100, ZIndexBehavior = Enum.ZIndexBehavior.Sibling, }, playerGui) local espLayer = new("ScreenGui", { Name = "HpTeamProEsp", ResetOnSpawn = false, IgnoreGuiInset = true, DisplayOrder = 50, }, playerGui) local flyGui = new("ScreenGui", { Name = "HpTeamProFly", ResetOnSpawn = false, DisplayOrder = 99, Enabled = false, }, playerGui) --================================================================== -- [7] ESP (dựng bằng GUI + Highlight) --================================================================== local espState = { Line = false, Box = false, Name = false, Distance = false, Hologram = false } local espEntries = {} local espLoopConn = nil local function removeEntry(model) local e = espEntries[model] if not e then return end for _, inst in pairs(e) do inst:Destroy() end espEntries[model] = nil end local function clearAllEsp() for model in pairs(espEntries) do removeEntry(model) end end local function createEntry(model) local line = new("Frame", { BackgroundColor3 = GREEN, BorderSizePixel = 0, AnchorPoint = Vector2.new(0.5, 0.5), Visible = false, }, espLayer) local box = new("Frame", { BackgroundTransparency = 1, BorderSizePixel = 0, Visible = false, }, espLayer) new("UIStroke", { Color = GREEN, Thickness = 1.5 }, box) local nameLabel = new("TextLabel", { BackgroundTransparency = 1, TextColor3 = GREEN, TextStrokeTransparency = 0, Font = Enum.Font.GothamBold, TextSize = 13, Size = UDim2.fromOffset(140, 16), AnchorPoint = Vector2.new(0.5, 1), Visible = false, }, espLayer) local distLabel = new("TextLabel", { BackgroundTransparency = 1, TextColor3 = Color3.new(1, 1, 1), TextStrokeTransparency = 0, Font = Enum.Font.Gotham, TextSize = 12, Size = UDim2.fromOffset(140, 16), AnchorPoint = Vector2.new(0.5, 0), Visible = false, }, espLayer) local hl = new("Highlight", { Adornee = model, FillColor = GREEN, FillTransparency = 0.6, OutlineColor = GREEN, DepthMode = Enum.HighlightDepthMode.AlwaysOnTop, Enabled = false, }, model) espEntries[model] = { line = line, box = box, name = nameLabel, dist = distLabel, hl = hl } return espEntries[model] end local function updateEsp() local myRoot = getMyRoot() local visible = {} if myRoot then for model in pairs(modelSet) do if isValidModel(model) then local d = (getRoot(model).Position - myRoot.Position).Magnitude if d <= CONFIG.RANGE then visible[model] = d end end end end for model in pairs(espEntries) do if not visible[model] then removeEntry(model) end end local viewport = camera.ViewportSize for model, dist in pairs(visible) do local e = espEntries[model] or createEntry(model) local root = getRoot(model) local pos, onScreen = camera:WorldToViewportPoint(root.Position) local show = onScreen and pos.Z > 0 e.hl.Enabled = espState.Hologram if show then local halfY = model:GetExtentsSize().Y / 2 local top = camera:WorldToViewportPoint(root.Position + Vector3.new(0, halfY, 0)) local bottom = camera:WorldToViewportPoint(root.Position - Vector3.new(0, halfY, 0)) local h = math.max(math.abs(bottom.Y - top.Y), 8) local w = h * 0.6 e.line.Visible = espState.Line if espState.Line then local from = Vector2.new(viewport.X / 2, 0) local to = Vector2.new(pos.X, pos.Y) local delta = to - from e.line.Size = UDim2.fromOffset(delta.Magnitude, 1) e.line.Position = UDim2.fromOffset((from.X + to.X) / 2, (from.Y + to.Y) / 2) e.line.Rotation = math.deg(math.atan2(delta.Y, delta.X)) end e.box.Visible = espState.Box if espState.Box then e.box.Size = UDim2.fromOffset(w, h) e.box.Position = UDim2.fromOffset(pos.X - w / 2, top.Y) end e.name.Visible = espState.Name if espState.Name then e.name.Text = model.Name e.name.Position = UDim2.fromOffset(pos.X, top.Y - 2) end e.dist.Visible = espState.Distance if espState.Distance then e.dist.Text = string.format("%dm", math.floor(dist + 0.5)) e.dist.Position = UDim2.fromOffset(pos.X, bottom.Y + 2) end else e.line.Visible = false e.box.Visible = false e.name.Visible = false e.dist.Visible = false end end end local function refreshEspLoop() local any = false for _, v in pairs(espState) do if v then any = true break end end if any and not espLoopConn then espLoopConn = RunService.RenderStepped:Connect(updateEsp) elseif not any and espLoopConn then espLoopConn:Disconnect() espLoopConn = nil clearAllEsp() end end local function espFeature(key) return { start = function() espState[key] = true refreshEspLoop() end, stop = function() espState[key] = false refreshEspLoop() end, } end Features.EspLine = espFeature("Line") Features.EspBox = espFeature("Box") Features.EspName = espFeature("Name") Features.EspDistance = espFeature("Distance") Features.EspHologram = espFeature("Hologram") --================================================================== -- [8] TAB MAIN --================================================================== -- Tele Kill: dịch chuyển tới mục tiêu gần nhất và đánh Features.TeleKill = { start = function() local acc = 0 hold("TeleKill", RunService.Heartbeat:Connect(function(dt) local model = nearestTarget() local myRoot = getMyRoot() if not model or not myRoot then return end local tRoot = getRoot(model) local pos = (tRoot.CFrame * CONFIG.TELE_OFFSET).Position myRoot.CFrame = CFrame.lookAt(pos, Vector3.new(tRoot.Position.X, pos.Y, tRoot.Position.Z)) myRoot.AssemblyLinearVelocity = Vector3.zero acc += dt if acc >= CONFIG.ATTACK_DELAY then acc = 0 activateTool() end end)) end, stop = function() release("TeleKill") end, } -- Aimbot: ghim camera vào mục tiêu gần nhất Features.Aimbot = { start = function() RunService:BindToRenderStep("HpTeamProAimbot", Enum.RenderPriority.Camera.Value + 1, function() local model = nearestTarget() if not model then return end local part = getAimPart(model) camera.CFrame = CFrame.lookAt(camera.CFrame.Position, part.Position) end) end, stop = function() RunService:UnbindFromRenderStep("HpTeamProAimbot") end, } -- Aim Magic: khi người chơi bắn bằng Tool, đạn gửi về server với hướng tới mục tiêu. -- Camera và mục tiêu không bị khóa. Features.AimMagic = { start = function() local hooked = {} local function onActivated() local model = nearestTarget() if model then fireAt(model) end end local function hookTool(child) if child:IsA("Tool") and not hooked[child] then hooked[child] = true hold("AimMagic", child.Activated:Connect(onActivated)) end end local function hookChar(char) for _, c in ipairs(char:GetChildren()) do hookTool(c) end hold("AimMagic", char.ChildAdded:Connect(hookTool)) end if getChar() then hookChar(getChar()) end hold("AimMagic", player.CharacterAdded:Connect(hookChar)) end, stop = function() release("AimMagic") end, } -- Auto Bắn: tự bắn mục tiêu trong phạm vi, không khóa camera Features.AutoFire = { start = function() local acc = 0 hold("AutoFire", RunService.Heartbeat:Connect(function(dt) acc += dt if acc < CONFIG.FIRE_DELAY then return end acc = 0 local model = nearestTarget() if model and not fireAt(model) then activateTool() end end)) end, stop = function() release("AutoFire") end, } --================================================================== -- [9] TAB KHÁC --================================================================== -- No Clip local noclipOriginal = setmetatable({}, { __mode = "k" }) Features.NoClip = { start = function() hold("NoClip", RunService.Stepped:Connect(function() local char = getChar() if not char then return end for _, part in ipairs(char:GetDescendants()) do if part:IsA("BasePart") and part.CanCollide then noclipOriginal[part] = true part.CanCollide = false end end end)) end, stop = function() release("NoClip") for part in pairs(noclipOriginal) do if part.Parent then part.CanCollide = true end end table.clear(noclipOriginal) end, } -- Fly Air: bay, đứng yên khi không bấm, nút ▲/▼ chỉnh độ cao local flyBV, flyBG = nil, nil local function destroyFlyBodies() if flyBV then flyBV:Destroy() flyBV = nil end if flyBG then flyBG:Destroy() flyBG = nil end end local function ensureFlyBodies(root) if not flyBV or flyBV.Parent ~= root then destroyFlyBodies() flyBV = new("BodyVelocity", { MaxForce = Vector3.new(1e9, 1e9, 1e9), Velocity = Vector3.zero, }, root) flyBG = new("BodyGyro", { MaxTorque = Vector3.new(1e9, 1e9, 1e9), P = 9e4, CFrame = root.CFrame, }, root) end end Features.FlyAir = { start = function() flyGui.Enabled = true hold("FlyAir", RunService.Heartbeat:Connect(function() local hum, root = getHumanoid(), getMyRoot() if not hum or not root then return end ensureFlyBodies(root) hum.PlatformStand = true local vy = (flyInput.up and 1 or 0) - (flyInput.down and 1 or 0) flyBV.Velocity = hum.MoveDirection * flyValue + Vector3.new(0, vy * flyValue, 0) local look = camera.CFrame.LookVector if Vector3.new(look.X, 0, look.Z).Magnitude > 0.01 then flyBG.CFrame = CFrame.lookAt(root.Position, root.Position + Vector3.new(look.X, 0, look.Z)) end end)) end, stop = function() release("FlyAir") destroyFlyBodies() flyInput.up, flyInput.down = false, false flyGui.Enabled = false local hum = getHumanoid() if hum then hum.PlatformStand = false end end, } -- Speed local originalWalkSpeed = 16 Features.Speed = { start = function() local hum = getHumanoid() if hum then originalWalkSpeed = hum.WalkSpeed end hold("Speed", RunService.Heartbeat:Connect(function() local h = getHumanoid() if h then h.WalkSpeed = walkValue end end)) end, stop = function() release("Speed") local hum = getHumanoid() if hum then hum.WalkSpeed = originalWalkSpeed end end, } -- Jumping Air Features.JumpAir = { start = function() hold("JumpAir", UserInputService.JumpRequest:Connect(function() local hum = getHumanoid() if hum then hum:ChangeState(Enum.HumanoidStateType.Jumping) end end)) end, stop = function() release("JumpAir") end, } -- Night Vision: bỏ bóng tối và sương mù local nightSaved = nil Features.NightVision = { start = function() nightSaved = { Brightness = Lighting.Brightness, ClockTime = Lighting.ClockTime, Ambient = Lighting.Ambient, OutdoorAmbient = Lighting.OutdoorAmbient, GlobalShadows = Lighting.GlobalShadows, FogStart = Lighting.FogStart, FogEnd = Lighting.FogEnd, atmos = {}, } for _, a in ipairs(Lighting:GetChildren()) do if a:IsA("Atmosphere") then nightSaved.atmos[a] = { Density = a.Density, Haze = a.Haze } end end hold("NightVision", RunService.Heartbeat:Connect(function() Lighting.Brightness = 2 Lighting.ClockTime = 14 Lighting.Ambient = Color3.fromRGB(200, 200, 200) Lighting.OutdoorAmbient = Color3.fromRGB(200, 200, 200) Lighting.GlobalShadows = false Lighting.FogStart = 1e6 Lighting.FogEnd = 1e6 for a in pairs(nightSaved.atmos) do if a.Parent then a.Density = 0 a.Haze = 0 end end end)) end, stop = function() release("NightVision") local s = nightSaved if not s then return end Lighting.Brightness = s.Brightness Lighting.ClockTime = s.ClockTime Lighting.Ambient = s.Ambient Lighting.OutdoorAmbient = s.OutdoorAmbient Lighting.GlobalShadows = s.GlobalShadows Lighting.FogStart = s.FogStart Lighting.FogEnd = s.FogEnd for a, v in pairs(s.atmos) do if a.Parent then a.Density = v.Density a.Haze = v.Haze end end nightSaved = nil end, } --================================================================== -- [10] BẬT/TẮT CHỨC NĂNG --================================================================== local function refreshToggle(btn, on) btn.Text = on and "ON" or "OFF" btn.BackgroundColor3 = on and GREEN or BG_DARK btn.TextColor3 = on and BG_DARK or GREEN end local function setFeature(name, on) local f = Features[name] if not f then return end if on and not active[name] then active[name] = true f.start() elseif not on and active[name] then active[name] = nil f.stop() end if toggleButtons[name] then refreshToggle(toggleButtons[name], active[name] == true) end end --================================================================== -- [11] KHUNG MENU (350 ngang x 200 dài) --================================================================== local main = new("Frame", { Name = "Main", Size = UDim2.fromOffset(350, 200), Position = UDim2.new(0.5, -175, 0.5, -100), BackgroundColor3 = BG_DARK, BorderSizePixel = 0, ClipsDescendants = true, }, gui) new("UICorner", { CornerRadius = UDim.new(0, 6) }, main) new("UIStroke", { Color = GREEN, Thickness = 1.5 }, main) local titleBar = new("Frame", { Size = UDim2.new(1, 0, 0, 28), BackgroundColor3 = BG_MID, BorderSizePixel = 0, }, main) new("TextLabel", { Size = UDim2.new(1, -70, 1, 0), Position = UDim2.fromOffset(10, 0), BackgroundTransparency = 1, Text = "Hp Team Pro V1", TextColor3 = GREEN, Font = Enum.Font.GothamBold, TextSize = 14, TextXAlignment = Enum.TextXAlignment.Left, }, titleBar) local minBtn = new("TextButton", { Size = UDim2.fromOffset(26, 22), Position = UDim2.new(1, -60, 0, 3), BackgroundColor3 = BG_DARK, Text = "-", TextColor3 = GREEN, Font = Enum.Font.GothamBold, TextSize = 16, AutoButtonColor = true, }, titleBar) new("UICorner", { CornerRadius = UDim.new(0, 4) }, minBtn) local closeBtn = new("TextButton", { Size = UDim2.fromOffset(26, 22), Position = UDim2.new(1, -30, 0, 3), BackgroundColor3 = BG_DARK, Text = "X", TextColor3 = RED, Font = Enum.Font.GothamBold, TextSize = 14, AutoButtonColor = true, }, titleBar) new("UICorner", { CornerRadius = UDim.new(0, 4) }, closeBtn) local tabBar = new("Frame", { Size = UDim2.new(1, 0, 0, 26), Position = UDim2.fromOffset(0, 28), BackgroundColor3 = BG_DARK, BorderSizePixel = 0, }, main) local pages = new("Frame", { Size = UDim2.new(1, 0, 0, 146), Position = UDim2.fromOffset(0, 54), BackgroundTransparency = 1, }, main) --================================================================== -- [12] KÉO THẢ (chuột + cảm ứng, kéo bằng thanh tiêu đề) --================================================================== local dragging, dragStart, startPos = false, nil, nil track(titleBar.InputBegan:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then dragging = true dragStart = input.Position startPos = main.Position end end)) track(UserInputService.InputChanged:Connect(function(input) if dragging and (input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch) then local delta = input.Position - dragStart main.Position = UDim2.new( startPos.X.Scale, startPos.X.Offset + delta.X, startPos.Y.Scale, startPos.Y.Offset + delta.Y ) end end)) track(UserInputService.InputEnded:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then dragging = false flyInput.up, flyInput.down = false, false end end)) --================================================================== -- [13] TAB & HÀNG CHỨC NĂNG (cuộn lên/xuống) --================================================================== local tabPages, tabButtons = {}, {} local function makePage(name) local page = new("ScrollingFrame", { Name = name, Size = UDim2.fromScale(1, 1), BackgroundTransparency = 1, BorderSizePixel = 0, ScrollBarThickness = 4, ScrollBarImageColor3 = GREEN, ScrollingDirection = Enum.ScrollingDirection.Y, AutomaticCanvasSize = Enum.AutomaticSize.Y, CanvasSize = UDim2.new(), Visible = false, }, pages) new("UIListLayout", { Padding = UDim.new(0, 4), SortOrder = Enum.SortOrder.LayoutOrder }, page) new("UIPadding", { PaddingTop = UDim.new(0, 4), PaddingBottom = UDim.new(0, 4), PaddingLeft = UDim.new(0, 6), PaddingRight = UDim.new(0, 6), }, page) tabPages[name] = page return page end local function selectTab(name) for n, page in pairs(tabPages) do page.Visible = (n == name) end for n, btn in pairs(tabButtons) do btn.TextColor3 = (n == name) and GREEN or Color3.fromRGB(120, 140, 120) btn.BackgroundColor3 = (n == name) and BG_MID or BG_DARK end end local tabNames = { "Main", "Esp", "Khác" } for i, name in ipairs(tabNames) do local btn = new("TextButton", { Size = UDim2.new(1 / 3, 0, 1, 0), Position = UDim2.new((i - 1) / 3, 0, 0, 0), BackgroundColor3 = BG_DARK, BorderSizePixel = 0, Text = name, Font = Enum.Font.GothamBold, TextSize = 13, TextColor3 = GREEN, }, tabBar) tabButtons[name] = btn makePage(name) track(btn.MouseButton1Click:Connect(function() selectTab(name) end)) end local function makeSmallButton(text, parent, pos) local b = new("TextButton", { Size = UDim2.fromOffset(22, 22), Position = pos, BackgroundColor3 = BG_MID, Text = text, TextColor3 = GREEN, Font = Enum.Font.GothamBold, TextSize = 14, }, parent) new("UICorner", { CornerRadius = UDim.new(0, 4) }, b) return b end -- opts.feature: tên chức năng có công tắc | opts.stepper: {get, set, min, max, step} local function addRow(pageName, labelText, order, opts) local row = new("Frame", { Size = UDim2.new(1, 0, 0, 28), BackgroundColor3 = BG_MID, BorderSizePixel = 0, LayoutOrder = order, }, tabPages[pageName]) new("UICorner", { CornerRadius = UDim.new(0, 4) }, row) new("TextLabel", { Size = UDim2.fromOffset(104, 28), Position = UDim2.fromOffset(8, 0), BackgroundTransparency = 1, Text = labelText, TextColor3 = Color3.new(1, 1, 1), Font = Enum.Font.GothamMedium, TextSize = 13, TextXAlignment = Enum.TextXAlignment.Left, }, row) if opts.stepper then local s = opts.stepper local minus = makeSmallButton("-", row, UDim2.fromOffset(116, 3)) local valueLabel = new("TextLabel", { Size = UDim2.fromOffset(44, 28), Position = UDim2.fromOffset(140, 0), BackgroundTransparency = 1, Text = tostring(s.get()), TextColor3 = GREEN, Font = Enum.Font.GothamBold, TextSize = 13, }, row) local plus = makeSmallButton("+", row, UDim2.fromOffset(186, 3)) track(minus.MouseButton1Click:Connect(function() s.set(math.clamp(s.get() - s.step, s.min, s.max)) valueLabel.Text = tostring(s.get()) end)) track(plus.MouseButton1Click:Connect(function() s.set(math.clamp(s.get() + s.step, s.min, s.max)) valueLabel.Text = tostring(s.get()) end)) end if opts.feature then local btn = new("TextButton", { Size = UDim2.fromOffset(56, 22), AnchorPoint = Vector2.new(1, 0), Position = UDim2.new(1, -6, 0, 3), BackgroundColor3 = BG_DARK, Text = "OFF", TextColor3 = GREEN, Font = Enum.Font.GothamBold, TextSize = 12, }, row) new("UICorner", { CornerRadius = UDim.new(0, 4) }, btn) new("UIStroke", { Color = GREEN, Thickness = 1 }, btn) toggleButtons[opts.feature] = btn refreshToggle(btn, false) track(btn.MouseButton1Click:Connect(function() setFeature(opts.feature, not active[opts.feature]) end)) end end -- Tab Main addRow("Main", "Tele Kill", 1, { feature = "TeleKill" }) addRow("Main", "Aimbot", 2, { feature = "Aimbot" }) addRow("Main", "Aim Magic", 3, { feature = "AimMagic" }) addRow("Main", "Auto Bắn", 4, { feature = "AutoFire" }) -- Tab Esp addRow("Esp", "Esp Line", 1, { feature = "EspLine" }) addRow("Esp", "Esp Box", 2, { feature = "EspBox" }) addRow("Esp", "Esp Name", 3, { feature = "EspName" }) addRow("Esp", "Esp Distance", 4, { feature = "EspDistance" }) addRow("Esp", "Esp Hologram", 5, { feature = "EspHologram" }) -- Tab Khác addRow("Khác", "No Clip", 1, { feature = "NoClip" }) addRow("Khác", "Fly Air", 2, { feature = "FlyAir" }) addRow("Khác", "Fly Speed", 3, { stepper = { get = function() return flyValue end, set = function(v) flyValue = v end, min = CONFIG.FLY_MIN, max = CONFIG.FLY_MAX, step = CONFIG.FLY_STEP, }, }) addRow("Khác", "Speed", 4, { feature = "Speed", stepper = { get = function() return walkValue end, set = function(v) walkValue = v end, min = CONFIG.WALK_MIN, max = CONFIG.WALK_MAX, step = CONFIG.WALK_STEP, }, }) addRow("Khác", "Jumping Air", 5, { feature = "JumpAir" }) addRow("Khác", "Night Vision", 6, { feature = "NightVision" }) selectTab("Main") --================================================================== -- [14] NÚT BAY LÊN/XUỐNG (hiện khi bật Fly Air) --================================================================== local function makeFlyButton(text, y, key) local b = new("TextButton", { Size = UDim2.fromOffset(56, 56), AnchorPoint = Vector2.new(1, 0.5), Position = UDim2.new(1, -16, 0.5, y), BackgroundColor3 = BG_DARK, BackgroundTransparency = 0.15, Text = text, TextColor3 = GREEN, Font = Enum.Font.GothamBold, TextSize = 24, }, flyGui) new("UICorner", { CornerRadius = UDim.new(0, 8) }, b) new("UIStroke", { Color = GREEN, Thickness = 1.5 }, b) track(b.InputBegan:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then flyInput[key] = true end end)) track(b.InputEnded:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then flyInput[key] = false end end)) end makeFlyButton("▲", -34, "up") makeFlyButton("▼", 34, "down") --================================================================== -- [15] THU NHỎ & THOÁT (dọn dẹp toàn bộ) --================================================================== local minimized = false track(minBtn.MouseButton1Click:Connect(function() minimized = not minimized tabBar.Visible = not minimized pages.Visible = not minimized main.Size = minimized and UDim2.fromOffset(350, 28) or UDim2.fromOffset(350, 200) minBtn.Text = minimized and "+" or "-" end)) local function shutdown() if not alive then return end -- tắt mọi chức năng đang bật (khôi phục trạng thái gốc) for name in pairs(Features) do if active[name] then setFeature(name, false) end end alive = false if espLoopConn then espLoopConn:Disconnect() espLoopConn = nil end clearAllEsp() destroyFlyBodies() pcall(function() RunService:UnbindFromRenderStep("HpTeamProAimbot") end) for name in pairs(fconn) do release(name) end for _, c in ipairs(connections) do c:Disconnect() end table.clear(connections) espLayer:Destroy() flyGui:Destroy() gui:Destroy() end closeBtn.MouseButton1Click:Connect(shutdown)