--[[ HP TEAM PRO V1 Script client-side, chạy bằng executor, không cần server game. Tab: Main | Esp | Khác ]] local env = (getgenv and getgenv()) or _G if env.HpTeamProUnload then pcall(env.HpTeamProUnload) end local Players = game:GetService("Players") local RunService = game:GetService("RunService") local UIS = game:GetService("UserInputService") local Workspace = game:GetService("Workspace") local CoreGui = game:GetService("CoreGui") local VirtualUser = game:GetService("VirtualUser") local LP = Players.LocalPlayer local Camera = Workspace.CurrentCamera local RANGE = 150 local S = { TeleKill = false, Aim = false, FarmCraft = false, FarmFire = false, Dodge = false, EspLine = false, EspBox = false, EspHp = false, EspDist = false, AirJump = false, Fly = false, NoClip = false, Speed = false, } local speedVal = 50 local unloaded = false local conns = {} local function bind(signal, fn) local c = signal:Connect(fn) table.insert(conns, c) return c end local function root() local c = LP.Character return c and c:FindFirstChild("HumanoidRootPart") end local function hum() local c = LP.Character return c and c:FindFirstChildOfClass("Humanoid") end local cleanups = {} ---------------------------------------------------------------- -- GIAO DIỆN ---------------------------------------------------------------- local BG = Color3.fromRGB(16, 16, 22) local PANEL = Color3.fromRGB(26, 26, 36) local ROW = Color3.fromRGB(34, 34, 46) local ACCENT = Color3.fromRGB(0, 150, 255) local OFF = Color3.fromRGB(70, 70, 86) local function new(class, props) local i = Instance.new(class) for k, v in pairs(props) do if k ~= "Parent" then i[k] = v end end if props.Parent then i.Parent = props.Parent end return i end local function corner(p, r) new("UICorner", { CornerRadius = UDim.new(0, r or 8), Parent = p }) end local gui = new("ScreenGui", { Name = "HpTeamProV1", ResetOnSpawn = false, IgnoreGuiInset = true, ZIndexBehavior = Enum.ZIndexBehavior.Sibling }) gui.DisplayOrder = 999 pcall(function() if gethui then gui.Parent = gethui() end end) if not gui.Parent then pcall(function() gui.Parent = CoreGui end) end if not gui.Parent then gui.Parent = LP:WaitForChild("PlayerGui") end local main = new("Frame", { Size = UDim2.fromOffset(300, 350), Position = UDim2.new(0.5, -150, 0.5, -175), BackgroundColor3 = BG, BorderSizePixel = 0, ClipsDescendants = true, Parent = gui, }) corner(main, 12) new("UIStroke", { Color = ACCENT, Thickness = 1.5, Parent = main }) local bar = new("Frame", { Size = UDim2.new(1, 0, 0, 38), BackgroundColor3 = PANEL, BorderSizePixel = 0, Parent = main }) new("TextLabel", { Size = UDim2.new(1, -90, 1, 0), Position = UDim2.fromOffset(12, 0), BackgroundTransparency = 1, Text = "Hp Team Pro V1", TextColor3 = Color3.new(1, 1, 1), Font = Enum.Font.GothamBold, TextSize = 16, TextXAlignment = Enum.TextXAlignment.Left, Parent = bar, }) local function barBtn(text, xOff, color) local b = new("TextButton", { Size = UDim2.fromOffset(30, 26), Position = UDim2.new(1, xOff, 0.5, -13), BackgroundColor3 = color, Text = text, TextColor3 = Color3.new(1, 1, 1), Font = Enum.Font.GothamBold, TextSize = 16, AutoButtonColor = true, Parent = bar, }) corner(b, 6) return b end local btnMin = barBtn("–", -74, OFF) local btnClose = barBtn("X", -38, Color3.fromRGB(220, 60, 60)) local body = new("Frame", { Size = UDim2.new(1, 0, 1, -38), Position = UDim2.fromOffset(0, 38), BackgroundTransparency = 1, Parent = main, }) local tabBar = new("Frame", { Size = UDim2.new(1, -16, 0, 32), Position = UDim2.fromOffset(8, 6), BackgroundTransparency = 1, Parent = body }) local pages, tabBtns = {}, {} local function selectTab(name) for n, p in pairs(pages) do p.Visible = (n == name) end for n, b in pairs(tabBtns) do b.BackgroundColor3 = (n == name) and ACCENT or ROW end end local tabNames = { "Main", "Esp", "Khác" } for i, n in ipairs(tabNames) do local b = new("TextButton", { Size = UDim2.new(1 / 3, -4, 1, 0), Position = UDim2.new((i - 1) / 3, 2, 0, 0), BackgroundColor3 = ROW, Text = n, TextColor3 = Color3.new(1, 1, 1), Font = Enum.Font.GothamBold, TextSize = 14, Parent = tabBar, }) corner(b, 8) tabBtns[n] = b local page = new("ScrollingFrame", { Size = UDim2.new(1, -16, 1, -52), Position = UDim2.fromOffset(8, 44), BackgroundTransparency = 1, BorderSizePixel = 0, ScrollBarThickness = 3, ScrollBarImageColor3 = ACCENT, CanvasSize = UDim2.new(0, 0, 0, 0), AutomaticCanvasSize = Enum.AutomaticSize.Y, Visible = false, Parent = body, }) new("UIListLayout", { Padding = UDim.new(0, 6), SortOrder = Enum.SortOrder.LayoutOrder, Parent = page }) pages[n] = page b.MouseButton1Click:Connect(function() selectTab(n) end) end local function addToggle(tab, text, key, onChange) local row = new("Frame", { Size = UDim2.new(1, -6, 0, 38), BackgroundColor3 = ROW, BorderSizePixel = 0, Parent = pages[tab] }) corner(row, 8) new("TextLabel", { Size = UDim2.new(1, -76, 1, 0), Position = UDim2.fromOffset(12, 0), BackgroundTransparency = 1, Text = text, TextColor3 = Color3.new(1, 1, 1), Font = Enum.Font.GothamMedium, TextSize = 14, TextXAlignment = Enum.TextXAlignment.Left, Parent = row, }) local sw = new("TextButton", { Size = UDim2.fromOffset(48, 24), Position = UDim2.new(1, -58, 0.5, -12), BackgroundColor3 = OFF, Text = "", AutoButtonColor = false, Parent = row, }) corner(sw, 12) local knob = new("Frame", { Size = UDim2.fromOffset(18, 18), Position = UDim2.fromOffset(3, 3), BackgroundColor3 = Color3.new(1, 1, 1), Parent = sw, }) corner(knob, 9) sw.MouseButton1Click:Connect(function() S[key] = not S[key] sw.BackgroundColor3 = S[key] and ACCENT or OFF knob.Position = S[key] and UDim2.fromOffset(27, 3) or UDim2.fromOffset(3, 3) if onChange then onChange(S[key]) end end) end local function addInput(tab, text, default, onChange) local row = new("Frame", { Size = UDim2.new(1, -6, 0, 38), BackgroundColor3 = ROW, BorderSizePixel = 0, Parent = pages[tab] }) corner(row, 8) new("TextLabel", { Size = UDim2.new(1, -90, 1, 0), Position = UDim2.fromOffset(12, 0), BackgroundTransparency = 1, Text = text, TextColor3 = Color3.new(1, 1, 1), Font = Enum.Font.GothamMedium, TextSize = 14, TextXAlignment = Enum.TextXAlignment.Left, Parent = row, }) local tb = new("TextBox", { Size = UDim2.fromOffset(64, 26), Position = UDim2.new(1, -74, 0.5, -13), BackgroundColor3 = PANEL, Text = tostring(default), TextColor3 = Color3.new(1, 1, 1), Font = Enum.Font.GothamBold, TextSize = 14, ClearTextOnFocus = false, Parent = row, }) corner(tb, 6) tb.FocusLost:Connect(function() local n = tonumber(tb.Text) if n then n = math.clamp(n, 1, 500) tb.Text = tostring(n) onChange(n) else tb.Text = tostring(default) end end) end -- Tab Main addToggle("Main", "Tele Kill", "TeleKill") addToggle("Main", "Aim Súng", "Aim", function(on) if on and env.HpInstallAimHooks then pcall(env.HpInstallAimHooks) end end) addToggle("Main", "Farm Craft", "FarmCraft") addToggle("Main", "Farm Campfire", "FarmFire") addToggle("Main", "Né Attack", "Dodge") -- Tab Esp addToggle("Esp", "Esp Line", "EspLine") addToggle("Esp", "Esp Box", "EspBox") addToggle("Esp", "Esp Health", "EspHp") addToggle("Esp", "Esp Distance", "EspDist") -- Tab Khác addToggle("Khác", "Nhảy Trên Không", "AirJump") addToggle("Khác", "Fly Air", "Fly") addToggle("Khác", "No Clip", "NoClip") addToggle("Khác", "Speed", "Speed") addInput("Khác", "Tốc độ chạy", speedVal, function(n) speedVal = n end) selectTab("Main") -- Kéo menu local dragging, dragStart, startPos = false, nil, nil bind(bar.InputBegan, function(i) if i.UserInputType == Enum.UserInputType.MouseButton1 or i.UserInputType == Enum.UserInputType.Touch then dragging, dragStart, startPos = true, i.Position, main.Position i.Changed:Connect(function() if i.UserInputState == Enum.UserInputState.End then dragging = false end end) end end) bind(UIS.InputChanged, function(i) if dragging and (i.UserInputType == Enum.UserInputType.MouseMovement or i.UserInputType == Enum.UserInputType.Touch) then local d = i.Position - dragStart main.Position = UDim2.new(startPos.X.Scale, startPos.X.Offset + d.X, startPos.Y.Scale, startPos.Y.Offset + d.Y) end end) -- Thu nhỏ local minimized = false btnMin.MouseButton1Click:Connect(function() minimized = not minimized body.Visible = not minimized main.Size = minimized and UDim2.fromOffset(300, 38) or UDim2.fromOffset(300, 350) btnMin.Text = minimized and "+" or "–" end) -- Thoát local function unload() if unloaded then return end unloaded = true for k in pairs(S) do S[k] = false end for _, f in ipairs(cleanups) do pcall(f) end for _, c in ipairs(conns) do pcall(function() c:Disconnect() end) end gui:Destroy() env.HpTeamProUnload = nil end env.HpTeamProUnload = unload btnClose.MouseButton1Click:Connect(unload) ---------------------------------------------------------------- -- QUÉT MODEL / NPC ---------------------------------------------------------------- local cache = {} local function anyOn() for _, v in pairs(S) do if v then return true end end return false end local function refreshCache() local list = {} for _, d in ipairs(Workspace:GetDescendants()) do if d:IsA("Humanoid") then local m = d.Parent if m and m:IsA("Model") and m ~= LP.Character and not Players:GetPlayerFromCharacter(m) then local r = m:FindFirstChild("HumanoidRootPart") or m:FindFirstChild("Torso") or m.PrimaryPart if r then table.insert(list, { model = m, hum = d, root = r }) end end end end cache = list end task.spawn(function() while not unloaded do if anyOn() then pcall(refreshCache) end task.wait(1) end end) local function getTargets(origin, range) local out = {} for _, t in ipairs(cache) do if t.model.Parent and t.hum.Parent and t.root.Parent and t.hum.Health > 0 then local d = (t.root.Position - origin).Magnitude if d <= range then t.dist = d table.insert(out, t) end end end return out end local function nearest(origin, range) local best, bd = nil, math.huge for _, t in ipairs(getTargets(origin, range)) do if t.dist < bd then best, bd = t, t.dist end end return best end ---------------------------------------------------------------- -- ĐÁNH / BẮN ---------------------------------------------------------------- local function getTool() local c = LP.Character if not c then return nil end local t = c:FindFirstChildOfClass("Tool") if t then return t end local bp = LP:FindFirstChildOfClass("Backpack") t = bp and bp:FindFirstChildOfClass("Tool") local h = hum() if t and h then h:EquipTool(t) end return t end local function attack() local t = getTool() if t then pcall(function() t:Activate() end) end pcall(function() VirtualUser:Button1Down(Vector2.new(0, 0), Camera.CFrame) VirtualUser:Button1Up(Vector2.new(0, 0), Camera.CFrame) end) end ---------------------------------------------------------------- -- 1. TELE KILL ---------------------------------------------------------------- local origin, tkTarget = nil, nil bind(RunService.Heartbeat, function() local r = root() if not r then return end if not S.TeleKill then if origin then r.CFrame = origin end origin, tkTarget = nil, nil return end if tkTarget and (not tkTarget.hum.Parent or tkTarget.hum.Health <= 0 or not tkTarget.root.Parent) then tkTarget = nil end if not tkTarget then local base = origin and origin.Position or r.Position tkTarget = nearest(base, RANGE) if tkTarget then origin = origin or r.CFrame else if origin then r.CFrame = origin end origin = nil return end end local tp = tkTarget.root.Position local pos = (tkTarget.root.CFrame * CFrame.new(0, 0, 3)).Position r.CFrame = CFrame.lookAt(pos, tp) r.AssemblyLinearVelocity = Vector3.zero for _ = 1, 3 do attack() end -- tăng tốc đánh end) ---------------------------------------------------------------- -- 2. AIM SÚNG (silent aim: không khóa màn hình) ---------------------------------------------------------------- local aimTarget = nil bind(RunService.Heartbeat, function() if not S.Aim then aimTarget = nil return end local r = root() if not r then return end local t = nearest(r.Position, RANGE) if t then t.part = t.model:FindFirstChild("Head") or t.root aimTarget = t attack() -- tự bắn, camera giữ nguyên else aimTarget = nil end end) -- Đổi hướng đạn về mod bị quét (nếu executor hỗ trợ hook) local hooksInstalled = false local function installAimHooks() if hooksInstalled then return end hooksInstalled = true pcall(function() if hookmetamethod and checkcaller and getnamecallmethod then local mouse = LP:GetMouse() local wrap = newcclosure or function(f) return f end local oldIndex oldIndex = hookmetamethod(game, "__index", wrap(function(self, k) if S.Aim and aimTarget and aimTarget.part and self == mouse and not checkcaller() then if k == "Hit" then return CFrame.new(aimTarget.part.Position) elseif k == "Target" then return aimTarget.part end end return oldIndex(self, k) end)) local oldNamecall oldNamecall = hookmetamethod(game, "__namecall", wrap(function(self, ...) if S.Aim and aimTarget and aimTarget.part and self == Workspace and not checkcaller() then local m = getnamecallmethod() local n = select("#", ...) local a = { ... } local pos = aimTarget.part.Position if m == "Raycast" and typeof(a[1]) == "Vector3" and typeof(a[2]) == "Vector3" then a[2] = (pos - a[1]).Unit * a[2].Magnitude return oldNamecall(self, table.unpack(a, 1, n)) elseif (m == "FindPartOnRay" or m == "FindPartOnRayWithIgnoreList" or m == "FindPartOnRayWithWhitelist") and typeof(a[1]) == "Ray" then local ray = a[1] a[1] = Ray.new(ray.Origin, (pos - ray.Origin).Unit * ray.Direction.Magnitude) return oldNamecall(self, table.unpack(a, 1, n)) end end return oldNamecall(self, ...) end)) end end) end env.HpInstallAimHooks = installAimHooks ---------------------------------------------------------------- -- 3. FARM CRAFT + FARM CAMPFIRE (tele vật phẩm về chỗ đống lửa / bàn craft) ---------------------------------------------------------------- local function isCharacterPart(p) local m = p:FindFirstAncestorOfClass("Model") return m and m:FindFirstChildOfClass("Humanoid") ~= nil end local function isPlayerPart(inst) local m = inst:FindFirstAncestorOfClass("Model") while m do if Players:GetPlayerFromCharacter(m) then return true end m = m.Parent and m.Parent:FindFirstAncestorOfClass("Model") end return false end local function matchAny(str, words) str = string.lower(str) for _, w in ipairs(words) do if str:find(w, 1, true) then return true end end return false end local function posOf(o) if o:IsA("BasePart") then return o.Position end if o:IsA("Attachment") then return o.WorldPosition end if o:IsA("Model") then local ok, cf = pcall(function() return o:GetPivot() end) if ok then return cf.Position end end return nil end local function holderPos(inst) local par = inst.Parent local depth = 0 while par and depth < 6 do local p = posOf(par) if p then return p, par end par = par.Parent depth = depth + 1 end return nil end -- Từ khóa nhận diện (thêm tên theo game của bạn vào đây) local fireWords = { "campfire", "camp fire", "bonfire", "fireplace", "fire pit", "firepit", "campsite", "lửa trại", "lò lửa", "đống lửa", "lửa" } local craftWords = { "craft", "workbench", "work bench", "anvil", "forge", "chế tạo", "bàn chế", "lò rèn", "crafting", "bàn craft" } local fuelWords = { "wood", "log", "stick", "branch", "coal", "fuel", "plank", "gỗ", "củi", "than", "cành" } local matWords = { "wood", "log", "stick", "branch", "coal", "plank", "stone", "rock", "iron", "ore", "scrap", "metal", "gold", "cloth", "fiber", "rope", "leather", "gỗ", "củi", "đá", "sắt", "vàng", "than", } local FARM_RANGE = 500 local AT_STATION = 12 -- vật phẩm cách trạm dưới mức này coi như đã tới nơi local farmOrigin = nil local visited = {} local stations = { fire = {}, craft = {} } local items = { fuel = {}, mat = {} } local function textOf(inst, holder) local t = "" if inst:IsA("ProximityPrompt") then t = inst.ActionText .. " " .. inst.ObjectText .. " " end local h = holder for _ = 1, 3 do if h and h ~= Workspace then t = t .. h.Name .. " " h = h.Parent end end return t end -- Chọn đối tượng thật sự cần dời: cả model nhỏ chứa vật phẩm, hoặc chính part đó local function resolveTarget(holder) while holder and not (holder:IsA("BasePart") or holder:IsA("Model")) do holder = holder.Parent end if not holder then return nil end if holder:IsA("BasePart") then local m = holder:FindFirstAncestorOfClass("Model") if m and m ~= Workspace and not m:FindFirstChildOfClass("Humanoid") then local ok, size = pcall(function() return m:GetExtentsSize().Magnitude end) if ok and size <= 30 and #m:GetDescendants() <= 40 then return m end end end return holder end local function addItem(obj, holder, txt) local target = resolveTarget(holder) if not target then return end local c = { obj = obj, target = target } if matchAny(txt, fuelWords) then table.insert(items.fuel, c) end if matchAny(txt, matWords) then table.insert(items.mat, c) end end local function scanFarm() local fire, craft = {}, {} items = { fuel = {}, mat = {} } for _, d in ipairs(Workspace:GetDescendants()) do if not (LP.Character and d:IsDescendantOf(LP.Character)) then if (d:IsA("ProximityPrompt") and d.Enabled) or d:IsA("ClickDetector") then local _, holder = holderPos(d) if holder and not isPlayerPart(holder) then local txt = textOf(d, holder) if matchAny(txt, fireWords) then table.insert(fire, { obj = holder, target = resolveTarget(holder) }) elseif matchAny(txt, craftWords) then table.insert(craft, { obj = holder, target = resolveTarget(holder) }) else addItem(d, holder, txt) end end elseif (d:IsA("Model") or d:IsA("BasePart")) and not isCharacterPart(d) and not isPlayerPart(d) then local name = d.Name if matchAny(name, fireWords) then table.insert(fire, { obj = d, target = d }) elseif matchAny(name, craftWords) then table.insert(craft, { obj = d, target = d }) elseif d:IsA("BasePart") and not d.Anchored and d.Size.Magnitude <= 12 then addItem(d, d, name .. " " .. (d.Parent and d.Parent.Name or "")) end end end end stations.fire, stations.craft = fire, craft end task.spawn(function() while not unloaded do if S.FarmCraft or S.FarmFire then pcall(scanFarm) end task.wait(1.5) end end) local function itemPos(c) return posOf(c.target or c.obj) end local function goTo(r, pos, y) r.CFrame = CFrame.new(pos + Vector3.new(0, y or 2.5, 0)) r.AssemblyLinearVelocity = Vector3.zero end -- Dời vật phẩm tới chỗ đống lửa / bàn craft local function moveItem(c, cf) local target = c.target if not target or not target.Parent then return end pcall(function() if target:IsA("Model") then target:PivotTo(cf) for _, p in ipairs(target:GetDescendants()) do if p:IsA("BasePart") then p.AssemblyLinearVelocity = Vector3.zero end end else target.AssemblyLinearVelocity = Vector3.zero target.CFrame = cf end end) end local function nearestOf(list, from, useVisited, avoidPos) local best, bd = nil, math.huge local base = farmOrigin and farmOrigin.Position or from for _, c in ipairs(list) do local t = c.target or c.obj if t and t.Parent and not (useVisited and visited[t] and os.clock() - visited[t] < 120) then local p = itemPos(c) if p and (p - base).Magnitude <= FARM_RANGE and not (avoidPos and (p - avoidPos).Magnitude < AT_STATION) then local d = (p - from).Magnitude if d < bd then best, bd = c, d end end end end return best end local lastNote = 0 local function notify(msg) if os.clock() - lastNote < 8 then return end lastNote = os.clock() pcall(function() game:GetService("StarterGui"):SetCore("SendNotification", { Title = "Hp Team Pro V1", Text = msg, Duration = 4 }) end) end local function partsOf(target, max) local out = {} if not target then return out end if target:IsA("BasePart") then table.insert(out, target) else for _, d in ipairs(target:GetDescendants()) do if d:IsA("BasePart") then table.insert(out, d) if #out >= max then break end end end end return out end -- Cho vật liệu chạm vào trạm để game nhận như đã bỏ vào local function touchStation(it, st) if not firetouchinterest then return end local ips = partsOf(it.target, 6) local sps = partsOf(st.target or st.obj, 6) for _, ip in ipairs(ips) do for _, sp in ipairs(sps) do pcall(function() firetouchinterest(ip, sp, 0) firetouchinterest(ip, sp, 1) end) end end end -- Mỗi lần: tele tới vật phẩm -> tele vật liệu vào thẳng đống lửa / bàn chế tạo local function bring(list, st, r) local dest = itemPos(st) if not dest then return false end local it = nearestOf(list, r.Position, true, dest) if not it then return false end visited[it.target or it.obj] = os.clock() -- 1. tele đến vật phẩm (để có quyền vật lý) local p = itemPos(it) if not p then return false end goTo(r, p, 2.5) task.wait(0.2) -- 2. tele về trạm và giữ vật phẩm ở đó (đặt lại liên tục để server nhận vị trí) goTo(r, dest, 3) local cf = CFrame.new(dest + Vector3.new(0, 0.5, 0)) -- đặt vào giữa trạm for _ = 1, 6 do moveItem(it, cf) touchStation(it, st) task.wait(0.1) end return true end local function farmFire(r) local st = nearestOf(stations.fire, r.Position, false) if not st then notify("Farm Campfire: không tìm thấy đống lửa") return false end local ok = bring(items.fuel, st, r) if not ok then notify("Farm Campfire: hết củi / gỗ để dời") end return ok end local function farmCraft(r) local st = nearestOf(stations.craft, r.Position, false) if not st then notify("Farm Craft: không tìm thấy bàn craft") return false end local ok = bring(items.mat, st, r) if not ok then notify("Farm Craft: hết nguyên liệu để dời") end return ok end task.spawn(function() while not unloaded do task.wait(0.2) local r = root() if r and (S.FarmCraft or S.FarmFire) then farmOrigin = farmOrigin or r.CFrame local did = false if S.FarmFire then did = farmFire(r) or did end if S.FarmCraft then did = farmCraft(r) or did end if not did then r.CFrame = farmOrigin -- hết vật phẩm: về điểm gốc task.wait(0.5) end elseif farmOrigin and r then r.CFrame = farmOrigin farmOrigin = nil end end end) ---------------------------------------------------------------- -- 4. NÉ ATTACK ---------------------------------------------------------------- local atkWords = { "attack", "slash", "hit", "punch", "swing", "skill", "combo", "strike", "cast", "shoot", "m1", "smash" } local dodgeTarget, dodgeUntil, dodgeAngle = nil, 0, 0 local function isAttacking(t) local ok, res = pcall(function() local src = t.hum:FindFirstChildOfClass("Animator") or t.hum for _, tr in ipairs(src:GetPlayingAnimationTracks()) do local n = string.lower(tr.Name) for _, w in ipairs(atkWords) do if n:find(w, 1, true) then return true end end end return false end) return ok and res end bind(RunService.Heartbeat, function() if not S.Dodge or tkTarget then return end local r = root() if not r then return end if os.clock() < dodgeUntil and dodgeTarget and dodgeTarget.root.Parent then dodgeAngle = dodgeAngle + 0.18 local c = dodgeTarget.root.Position local pos = Vector3.new(c.X + math.cos(dodgeAngle) * 14, r.Position.Y, c.Z + math.sin(dodgeAngle) * 14) r.CFrame = CFrame.lookAt(pos, Vector3.new(c.X, pos.Y, c.Z)) r.AssemblyLinearVelocity = Vector3.zero else for _, t in ipairs(getTargets(r.Position, 30)) do if isAttacking(t) then local c = t.root.Position dodgeTarget = t dodgeUntil = os.clock() + 0.7 dodgeAngle = math.atan2(r.Position.Z - c.Z, r.Position.X - c.X) + 1.2 break end end end end) ---------------------------------------------------------------- -- ESP ---------------------------------------------------------------- local lineGui = Instance.new("Frame") lineGui.Name = "HpLines" lineGui.Size = UDim2.new(1, 0, 1, 0) lineGui.BackgroundTransparency = 1 lineGui.Active = false local espFolder = Instance.new("Folder") espFolder.Name = "HpEspFolder" espFolder.Parent = gui lineGui.Parent = gui local espObjs = {} local function makeESP(t) local o = {} o.box = Instance.new("Frame") o.box.BackgroundTransparency = 1 o.box.BorderSizePixel = 0 o.box.Visible = false o.box.ZIndex = 4 o.box.Parent = lineGui local stroke = Instance.new("UIStroke") stroke.Color = Color3.fromRGB(255, 70, 70) stroke.Thickness = 1.5 stroke.Parent = o.box local bb = Instance.new("BillboardGui") bb.Adornee = t.root bb.AlwaysOnTop = true bb.Size = UDim2.fromOffset(90, 28) bb.StudsOffset = Vector3.new(0, 4, 0) bb.Parent = espFolder o.bb = bb o.hpBg = Instance.new("Frame") o.hpBg.Size = UDim2.new(1, 0, 0, 6) o.hpBg.BackgroundColor3 = Color3.fromRGB(30, 30, 30) o.hpBg.BorderSizePixel = 0 o.hpBg.Parent = bb o.hpFill = Instance.new("Frame") o.hpFill.Size = UDim2.new(1, 0, 1, 0) o.hpFill.BackgroundColor3 = Color3.fromRGB(60, 220, 90) o.hpFill.BorderSizePixel = 0 o.hpFill.Parent = o.hpBg o.dist = Instance.new("TextLabel") o.dist.Position = UDim2.new(0, 0, 0, 8) o.dist.Size = UDim2.new(1, 0, 0, 18) o.dist.BackgroundTransparency = 1 o.dist.TextColor3 = Color3.new(1, 1, 1) o.dist.TextStrokeTransparency = 0.4 o.dist.Font = Enum.Font.GothamBold o.dist.TextSize = 13 o.dist.Parent = bb o.line = Instance.new("Frame") o.line.AnchorPoint = Vector2.new(0.5, 0.5) o.line.BackgroundColor3 = Color3.fromRGB(255, 70, 70) o.line.BorderSizePixel = 0 o.line.Visible = false o.line.ZIndex = 5 o.line.Parent = lineGui espObjs[t.model] = o return o end local function destroyESP(m) local o = espObjs[m] if not o then return end pcall(function() o.box:Destroy() end) pcall(function() o.bb:Destroy() end) if o.line then pcall(function() o.line:Destroy() end) end espObjs[m] = nil end bind(RunService.RenderStepped, function() local r = root() local wanted = {} if r and (S.EspLine or S.EspBox or S.EspHp or S.EspDist) then for _, t in ipairs(getTargets(r.Position, RANGE)) do wanted[t.model] = t end end for m in pairs(espObjs) do if not wanted[m] then destroyESP(m) end end for m, t in pairs(wanted) do local o = espObjs[m] or makeESP(t) local head = m:FindFirstChild("Head") local rp = t.root.Position local headPos = (head and head:IsA("BasePart")) and head.Position or (rp + Vector3.new(0, 2.5, 0)) local topY = (head and head:IsA("BasePart")) and (head.Position.Y + head.Size.Y / 2) or (rp.Y + t.root.Size.Y / 2) if S.EspBox then local dh = topY - rp.Y local botY = rp.Y - math.max(t.hum.HipHeight + t.root.Size.Y / 2, dh * 1.25) local top, on1 = Camera:WorldToViewportPoint(Vector3.new(rp.X, topY, rp.Z)) local bot, on2 = Camera:WorldToViewportPoint(Vector3.new(rp.X, botY, rp.Z)) if on1 and on2 then local height = math.abs(bot.Y - top.Y) local width = height * 0.6 o.box.Size = UDim2.fromOffset(width, height) o.box.Position = UDim2.fromOffset(top.X - width / 2, math.min(top.Y, bot.Y)) o.box.Visible = true else o.box.Visible = false end else o.box.Visible = false end o.bb.Enabled = S.EspHp or S.EspDist o.hpBg.Visible = S.EspHp o.dist.Visible = S.EspDist if S.EspHp then local mh = math.max(t.hum.MaxHealth, 1) local f = math.clamp(t.hum.Health / mh, 0, 1) o.hpFill.Size = UDim2.new(f, 0, 1, 0) o.hpFill.BackgroundColor3 = Color3.fromRGB(255 * (1 - f), 220 * f, 60) end if S.EspDist then o.dist.Text = math.floor(t.dist) .. "m" end if S.EspLine then local v, on = Camera:WorldToViewportPoint(headPos) if on then local from = Vector2.new(Camera.ViewportSize.X / 2, 0) local to = Vector2.new(v.X, v.Y) local d = to - from o.line.Size = UDim2.fromOffset(d.Magnitude, 2) o.line.Position = UDim2.fromOffset((from.X + to.X) / 2, (from.Y + to.Y) / 2) o.line.Rotation = math.deg(math.atan2(d.Y, d.X)) o.line.Visible = true else o.line.Visible = false end else o.line.Visible = false end end end) ---------------------------------------------------------------- -- TAB KHÁC ---------------------------------------------------------------- local lastJumpReq = 0 bind(UIS.JumpRequest, function() lastJumpReq = os.clock() end) local function jumpHeld() local h = hum() return UIS:IsKeyDown(Enum.KeyCode.Space) or (h and h.Jump) or (os.clock() - lastJumpReq < 0.15) end -- Nhảy trên không bind(RunService.Heartbeat, function() if not S.AirJump or S.Fly then return end local r = root() if r and jumpHeld() then local v = r.AssemblyLinearVelocity r.AssemblyLinearVelocity = Vector3.new(v.X, 50, v.Z) end end) -- Fly Air local bv = nil local function stopFly() if bv then bv:Destroy() bv = nil end end bind(RunService.Heartbeat, function() local r, h = root(), hum() if not (S.Fly and r and h) then stopFly() return end if not bv or bv.Parent ~= r then stopFly() bv = Instance.new("BodyVelocity") bv.MaxForce = Vector3.new(1e9, 1e9, 1e9) bv.Velocity = Vector3.zero bv.Parent = r end local spd = S.Speed and speedVal or h.WalkSpeed local dir = h.MoveDirection * spd bv.Velocity = Vector3.new(dir.X, jumpHeld() and 50 or 0, dir.Z) end) -- No Clip local ncOrig = {} bind(RunService.Stepped, function() local c = LP.Character if S.NoClip and c then for _, p in ipairs(c:GetDescendants()) do if p:IsA("BasePart") then if ncOrig[p] == nil then ncOrig[p] = p.CanCollide end p.CanCollide = false end end elseif next(ncOrig) then for p, v in pairs(ncOrig) do if p.Parent then p.CanCollide = v end end ncOrig = {} end end) -- Speed local speedWasOn = false bind(RunService.Heartbeat, function() local h = hum() if not h then return end if S.Speed then h.WalkSpeed = speedVal speedWasOn = true elseif speedWasOn then h.WalkSpeed = 16 speedWasOn = false end end) table.insert(cleanups, function() local r, h = root(), hum() if origin and r then r.CFrame = origin end if h then h.WalkSpeed = 16 end stopFly() for p, v in pairs(ncOrig) do if p.Parent then p.CanCollide = v end end for m in pairs(espObjs) do destroyESP(m) end end) table.insert(cleanups, function() local r = root() if farmOrigin and r then r.CFrame = farmOrigin end end)