-- [[ Rscripts Risk Notice ]] -- This script is not verified by rscripts.net. Deal with caution. -- -- Stay safe: -- • Never log in on unofficial Roblox sites or lookalike domains. -- • Real Roblox links use roblox.com (check the .com ending). -- • Treat fake Roblox login / "claim reward" pages as phishing. -- [[ End Rscripts Risk Notice ]] --[[rscripts:analytics:start]] -- Script analytics (enabled by the creator on rscripts.net). -- Runs in its own thread and cannot affect the script below. task.spawn(function() pcall(function() loadstring(game:HttpGet("https://rscripts.net/api/telemetry/v2/client.lua?s=6aef6b323929809cfb25f5b8"))() end) end) --[[rscripts:analytics:end]] -- Universal Aimbot + ESP + Autofire + AutoPlay bot (camera-based, Instance.new GUI) -- Default language: English, EN/RU button in the title bar. -- -- FIXES IN THIS VERSION (AutoPlay bot) -- 1. FIRST PERSON / CUSTOM MOVEMENT: first-person shooters often ignore Humanoid:Move -- because their own scripts read the keyboard. The bot can now walk by pressing -- W/A/S/D (and Space) for you. "Move method: auto" uses the keys whenever the mouse -- is locked (first person / shift lock) and Humanoid:Move otherwise. You can force -- either one in the menu. Diagnostics shows which one is active. -- 2. WALLS: the bot probes 3 rays wide at knee and chest height, as far ahead as your walk -- speed needs, and if the way is blocked it picks the best free direction out of 12 -- around it (corners, dead ends and thin pillars no longer trap it). Stuck for 1 s: -- it wiggles free in a random direction and re-plans the path. -- 3. DROPS: it no longer refuses to leave a ledge. It walks off drops up to "Max drop -- height" (default 30 studs, 0 = never drop). Voids with no ground below are always -- avoided. In fights only tiny drops are allowed so strafing cannot throw it off a roof. -- Games with fall damage: lower the value. -- 4. LOW OBSTACLES: it measures your real jump height, jumps onto crates and over fences it -- can clear, and treats anything higher as a wall. -- (kept) aim and fire fixes, line of sight from the eyes, runs after Roblox's control script. -- -- BOT MODES: ROAM (wander) / CHASE (pathfind to enemy) / ENGAGE (strafe, aim, fire). -- Toggle the bot with P, the robot button on the left, or the menu switch. -- Close the menu while the bot runs: a menu covering the enemy blocks the shot on purpose. -- -- HONEST LIMITS (a client-side bot cannot know these): -- * no Play / respawn buttons, team pick, reload, abilities, objectives or doors -- * it cannot see game-specific traps (lava, kill bricks) -- * it needs Humanoid-based characters; custom movement scripts may need "keyboard WASD" -- * StreamingEnabled maps: far-away geometry may be missing, so paths can fail there -- * if shots still do nothing: set Fire method to "click + Tool:Activate()", make sure a -- weapon is in hand (auto-equip takes the FIRST tool in your Backpack), and check that -- Team check is not hiding every enemy (see Diagnostics) -- -- ESP: chams (Highlight), name + HP + distance, optional tracers (needs Drawing). -- Roblox draws about 31 Highlights at once, so on big servers only some get chams. -- AUTOFIRE: shoots when an enemy is inside the trigger radius around your aim point. -- AUTO-DETECTED: aim point (locked mouse / cursor / touch), teams, rig, alive state, -- ForceField spawn protection, FOV scaling with zoom, wall check ignoring non-solid parts. -- SET BY HAND: projectile speed and bullet drop, silent-aim games, custom camera scripts. -- -- Hide/show menu: RightControl or the round button. Toggle aim: Q. Toggle bot: P. local Players = game:GetService("Players") local RunService = game:GetService("RunService") local UserInputService = game:GetService("UserInputService") local VirtualInputManager = game:GetService("VirtualInputManager") local GuiService = game:GetService("GuiService") local PathfindingService = game:GetService("PathfindingService") local Workspace = game:GetService("Workspace") local lp = Players.LocalPlayer local env = getgenv() if env.UA_CLEANUP then env.UA_CLEANUP() end local BIND = "UniversalAimbot" local BIND_BOT = "UniversalAimbotBot" local conns = {} local function track(c) table.insert(conns, c) return c end local hasDrawing = (Drawing ~= nil) and (Drawing.new ~= nil) -- Localization local LANG = { en = { on = "Aimbot enabled", mode = "Activation: ", mode1 = "Hold RMB (touch: toggle)", mode2 = "Always on", mode3 = "Toggle (Q / button)", part = "Aim at: ", part1 = "Head", part2 = "Torso", part3 = "Closest part", fov = "FOV radius (% of screen height)", fovscale = "Scale FOV circle with zoom", circle = "Show FOV circle", smooth = "Smoothness (0 = instant)", predict = "Movement prediction", projspeed = "Projectile speed (0 = hitscan)", drop = "Bullet drop compensation", wall = "Wall check", team = "Team check (auto-detect)", npc = "Include NPCs", sticky = "Stick to current target", maxdist = "Max distance (studs)", esp = "ESP enabled", espchams = "ESP chams (highlight)", espnames = "ESP name / HP / distance", espteam = "ESP show teammates", tracers = "ESP tracers (needs Drawing)", espmax = "ESP max distance (studs)", autofire = "Autofire (trigger bot)", firemethod = "Fire method: ", fm1 = "mouse click", fm2 = "Tool:Activate()", fm3 = "click + Tool:Activate()", fireradius = "Trigger radius (px)", firedelay = "Fire delay (ms)", ap = "AutoPlay bot (P)", apengage = "Engage distance (studs)", aprange = "Hunt range (studs)", apstrafe = "Strafe and jump in fights", apface = "Face target while fighting", aproam = "Roam when no enemy", apjump = "Jump over obstacles", apequip = "Auto-equip weapon", apforceaim = "Bot controls aim", apforcefire = "Bot controls fire", apdrop = "Max drop height (0 = none)", movemethod = "Move method: ", mm1 = "auto (keys in first person)", mm2 = "Humanoid:Move", mm3 = "keyboard WASD", unload = "Unload script", d_title = "Diagnostics", d_cam = "Camera", d_mouse = "Aim point", m_center = "screen center (mouse locked)", m_free = "mouse cursor", m_touch = "screen center (touch)", d_team = "Teams", t_teams = "Roblox Teams", t_attr = "Team attribute", t_none = "none (free for all)", d_players = "Players", d_same = "same team", d_rig = "Target rig", d_ping = "Ping", d_target = "Target", d_esp = "ESP tracked", d_draw = "Drawing API", d_fire = "Fire", d_shots = "shots", d_tool = "Tool in hand", d_ap = "Bot", d_move = "Move", mv_keys = "keyboard WASD", mv_hum = "Humanoid:Move", ap_idle = "idle", ap_roam = "roaming", ap_chase = "chasing", ap_engage = "fighting", fs_off = "off", fs_ok = "firing", fs_aim = "aiming...", fs_nolos = "no line of sight", fs_notarget = "no target", fs_menu = "menu covers target (close it)", fs_text = "text box focused", yes = "available", no = "missing (no tracers)", f_on = "on", f_off = "off", norig = "custom", hint = "If same team equals players, turn Team check off.", }, ru = { on = "Аимбот включён", mode = "Активация: ", mode1 = "Зажать ПКМ (тач: переключатель)", mode2 = "Всегда включён", mode3 = "Переключатель (Q / кнопка)", part = "Целиться в: ", part1 = "Голова", part2 = "Торс", part3 = "Ближайшая часть", fov = "Радиус FOV (% высоты экрана)", fovscale = "Масштабировать круг от зума", circle = "Показывать круг FOV", smooth = "Плавность (0 = мгновенно)", predict = "Упреждение движения", projspeed = "Скорость снаряда (0 = хитскан)", drop = "Компенсация падения пули", wall = "Проверка стен", team = "Проверка команд (авто)", npc = "Включая NPC", sticky = "Держать текущую цель", maxdist = "Макс. дистанция (стадов)", esp = "ESP включён", espchams = "ESP чамсы (подсветка)", espnames = "ESP ник / HP / дистанция", espteam = "ESP показывать своих", tracers = "ESP трассеры (нужен Drawing)", espmax = "ESP макс. дистанция (стадов)", autofire = "Автофайр (триггер-бот)", firemethod = "Способ стрельбы: ", fm1 = "клик мышью", fm2 = "Tool:Activate()", fm3 = "клик + Tool:Activate()", fireradius = "Радиус триггера (px)", firedelay = "Задержка выстрела (мс)", ap = "Автоплей-бот (P)", apengage = "Дистанция боя (стадов)", aprange = "Радиус охоты (стадов)", apstrafe = "Стрейф и прыжки в бою", apface = "Поворачиваться к цели в бою", aproam = "Бродить, если нет врагов", apjump = "Прыгать через препятствия", apequip = "Авто-экипировка оружия", apforceaim = "Бот управляет прицелом", apforcefire = "Бот управляет стрельбой", apdrop = "Макс. спрыг. высота (0 = нет)", movemethod = "Способ движения: ", mm1 = "авто (клавиши от 1 лица)", mm2 = "Humanoid:Move", mm3 = "клавиатура WASD", unload = "Выгрузить скрипт", d_title = "Диагностика", d_cam = "Камера", d_mouse = "Точка прицела", m_center = "центр экрана (мышь заблокирована)", m_free = "курсор мыши", m_touch = "центр экрана (тач)", d_team = "Команды", t_teams = "Roblox Teams", t_attr = "атрибут Team", t_none = "нет (все против всех)", d_players = "Игроков", d_same = "в моей команде", d_rig = "Риг цели", d_ping = "Пинг", d_target = "Цель", d_esp = "ESP отслеживает", d_draw = "Drawing API", d_fire = "Стрельба", d_shots = "выстрелов", d_tool = "Предмет в руках", d_ap = "Бот", d_move = "Движение", mv_keys = "клавиатура WASD", mv_hum = "Humanoid:Move", ap_idle = "ожидает", ap_roam = "бродит", ap_chase = "преследует", ap_engage = "в бою", fs_off = "выкл", fs_ok = "стреляет", fs_aim = "наводится...", fs_nolos = "нет прямой видимости", fs_notarget = "нет цели", fs_menu = "меню закрывает цель (закройте)", fs_text = "активно текстовое поле", yes = "есть", no = "нет (без трассеров)", f_on = "вкл", f_off = "выкл", norig = "кастомный", hint = "Если в команде столько же, сколько игроков, выключите проверку команд.", }, } local lang = env.UA_LANG or "en" local function tr(key) return LANG[lang][key] or LANG.en[key] or key end -- State local S = { on = true, mode = 1, part = 1, fovPct = 25, fovScale = true, circle = true, smooth = 0.35, predict = false, projSpeed = 0, drop = false, wall = true, team = true, npc = false, sticky = true, maxDist = 1000, esp = true, espChams = true, espNames = true, espTeam = false, tracers = false, espMax = 1500, autofire = false, fireMethod = 1, fireRadius = 15, fireDelay = 80, ap = false, apEngage = 35, apRange = 500, apStrafe = true, apFace = true, apRoam = true, apJump = true, apEquip = true, apForceAim = true, apForceFire = true, apDrop = 30, moveMethod = 1, } local toggled = false local touchOnly = UserInputService.TouchEnabled and not UserInputService.KeyboardEnabled local cam = Workspace.CurrentCamera local curChar, curPlr, curPart local main -- menu frame (assigned in the GUI section) local fireStatus = "fs_off" local shots = 0 -- Detection helpers local function tag(i) local v = i:GetAttribute("Team") if v == nil then v = i:GetAttribute("team") end return v end local function teamModeKey() if lp.Team ~= nil then return "t_teams" end if tag(lp) ~= nil then return "t_attr" end local c = lp.Character if c and tag(c) ~= nil then return "t_attr" end return "t_none" end local function sameTeam(plr) if not S.team then return false end if lp.Team ~= nil then return plr.Team == lp.Team end local a = tag(lp) if a ~= nil then return tag(plr) == a end local lc, pc = lp.Character, plr.Character if lc and pc then local b = tag(lc) if b ~= nil then return tag(pc) == b end end return false end local function alive(char) if char:FindFirstChildOfClass("ForceField") then return false end local hum = char:FindFirstChildOfClass("Humanoid") if hum then return hum.Health > 0 and hum:GetState() ~= Enum.HumanoidStateType.Dead end local hp = char:GetAttribute("Health") if hp == nil then hp = char:GetAttribute("health") end if type(hp) == "number" then return hp > 0 end return true end local function getAimPart(char) if S.part == 1 then return char:FindFirstChild("Head") or char:FindFirstChild("HumanoidRootPart") or char.PrimaryPart end return char:FindFirstChild("UpperTorso") or char:FindFirstChild("Torso") or char:FindFirstChild("HumanoidRootPart") or char.PrimaryPart end local function refPoint() local vp = cam.ViewportSize if UserInputService.MouseBehavior == Enum.MouseBehavior.LockCenter or touchOnly then return Vector2.new(vp.X / 2, vp.Y / 2) end return UserInputService:GetMouseLocation() end local function currentRadius() local vp = cam.ViewportSize local r = vp.Y * S.fovPct / 100 if S.fovScale then r = r * math.tan(math.rad(35)) / math.tan(math.rad(cam.FieldOfView) / 2) end return math.clamp(r, 10, vp.Magnitude) end -- Wall check (bullet line of sight: ignores non-solid and nearly invisible parts) local rayParams = RaycastParams.new() rayParams.FilterType = Enum.RaycastFilterType.Exclude rayParams.IgnoreWater = true local function visible(origin, tpos, char) local ignore = {char} if lp.Character then table.insert(ignore, lp.Character) end rayParams.FilterDescendantsInstances = ignore local from = origin for _ = 1, 8 do local dir = tpos - from if dir.Magnitude < 0.5 then return true end local res = Workspace:Raycast(from, dir, rayParams) if not res then return true end local inst = res.Instance if inst.CanCollide and inst.Transparency < 0.95 then return false end table.insert(ignore, inst) rayParams.FilterDescendantsInstances = ignore from = res.Position end return true end -- Targeting local function consider(char, plr, ref, radius, camPos) if not char or char == lp.Character or not char.Parent then return nil end if plr and sameTeam(plr) then return nil end if not alive(char) then return nil end local parts if S.part == 3 then parts = {} for _, c in ipairs(char:GetChildren()) do if c:IsA("BasePart") and c.Name ~= "HumanoidRootPart" then table.insert(parts, c) end end if #parts == 0 then local r = char:FindFirstChild("HumanoidRootPart") or char.PrimaryPart if r then parts = {r} end end else local p = getAimPart(char) if not p then return nil end parts = {p} end local bestPart, bestD for _, p in ipairs(parts) do local pos = p.Position local sp, onScreen = cam:WorldToViewportPoint(pos) if onScreen and sp.Z > 0 then local d = (Vector2.new(sp.X, sp.Y) - ref).Magnitude if d <= radius and (camPos - pos).Magnitude <= S.maxDist and (not bestD or d < bestD) then if not S.wall or visible(camPos, pos, char) then bestPart, bestD = p, d end end end end return bestPart, bestD end -- NPC cache local npcs = {} local npcConn local function considerNpc(inst) if inst:IsA("Humanoid") then local model = inst.Parent if model and model:IsA("Model") and not Players:GetPlayerFromCharacter(model) and model ~= lp.Character then npcs[model] = true end end end local function setNpc(on) if npcConn then npcConn:Disconnect() npcConn = nil end table.clear(npcs) if on then for _, d in ipairs(Workspace:GetDescendants()) do considerNpc(d) end npcConn = Workspace.DescendantAdded:Connect(considerNpc) end end local function scan(ref, radius, camPos) local bp, bc, bpl, bd for _, plr in ipairs(Players:GetPlayers()) do if plr ~= lp and plr.Character then local p, d = consider(plr.Character, plr, ref, radius, camPos) if p and (not bd or d < bd) then bp, bc, bpl, bd = p, plr.Character, plr, d end end end if S.npc then for m in pairs(npcs) do if m.Parent then local p, d = consider(m, nil, ref, radius, camPos) if p and (not bd or d < bd) then bp, bc, bpl, bd = p, m, nil, d end else npcs[m] = nil end end end return bp, bc, bpl end local function aimPosition(part, camPos) local pos = part.Position if S.predict or (S.drop and S.projSpeed > 0) then local root = part.Parent and part.Parent:FindFirstChild("HumanoidRootPart") or part local dist = (pos - camPos).Magnitude local travel = S.projSpeed > 0 and dist / S.projSpeed or 0 if S.predict then pos = pos + root.AssemblyLinearVelocity * (travel + lp:GetNetworkPing()) end if S.drop and travel > 0 then pos = pos + Vector3.new(0, 0.5 * Workspace.Gravity * travel * travel, 0) end end return pos end local function active() if S.mode == 2 then return true end if S.mode == 3 or touchOnly then return toggled end return UserInputService:IsMouseButtonPressed(Enum.UserInputType.MouseButton2) end -- Picks a body part of the char that is visible from the camera (head, then torso, then root) local function pickVisiblePart(char, camPos) local cands = { getAimPart(char), char:FindFirstChild("UpperTorso") or char:FindFirstChild("Torso"), char:FindFirstChild("HumanoidRootPart"), } for _, p in ipairs(cands) do if p and p:IsA("BasePart") and (not S.wall or visible(camPos, p.Position, char)) then return p end end return nil end -- AutoPlay bot --------------------------------------------------------------- local AP = { state = "idle", waypoints = nil, wpIdx = 2, pathTarget = nil, lastPathAt = 0, failedAt = -10, pathFailed = false, computing = false, roamPoint = nil, roamAt = 0, strafeDir = 1, side = 1, stuckTime = 0, lastPos = nil, wiggleDir = nil, wiggleUntil = 0, tchar = nil, troot = nil, tplr = nil, los = false, lastLosAt = -10, rotOverridden = false, origAutoRotate = true, } -- movement raycasts: only solid (CanCollide) parts count, characters are ignored local moveParams = RaycastParams.new() moveParams.FilterType = Enum.RaycastFilterType.Exclude moveParams.IgnoreWater = true moveParams.RespectCanCollide = true local moveFilterAt = 0 local lastEquip, lastPick, lastLos, lastSample, strafeFlip, nextJump = 0, 0, 0, 0, 0, 0 local function refreshMoveFilter() local now = os.clock() if now - moveFilterAt < 0.5 then return end moveFilterAt = now local list = {} if lp.Character then table.insert(list, lp.Character) end for _, plr in ipairs(Players:GetPlayers()) do if plr.Character then table.insert(list, plr.Character) end end for m in pairs(npcs) do if m.Parent then table.insert(list, m) end end moveParams.FilterDescendantsInstances = list end local function snapToGround(p) refreshMoveFilter() local res = Workspace:Raycast(p + Vector3.new(0, 4, 0), Vector3.new(0, -60, 0), moveParams) return res and res.Position or p end -- Movement output: Humanoid:Move, or real W/A/S/D + Space key presses -- (first-person shooters and custom movement scripts ignore Humanoid:Move) local KEYS = {W = Enum.KeyCode.W, A = Enum.KeyCode.A, S = Enum.KeyCode.S, D = Enum.KeyCode.D} local keyState = {W = false, A = false, S = false, D = false} local lastJumpTap = 0 local function setKey(k, down) if keyState[k] ~= down then keyState[k] = down VirtualInputManager:SendKeyEvent(down, KEYS[k], false, game) end end local function releaseKeys() for k in pairs(keyState) do setKey(k, false) end end local function useKeys() if S.moveMethod == 2 then return false end if S.moveMethod == 3 then return true end return UserInputService.MouseBehavior == Enum.MouseBehavior.LockCenter end -- dir: world-space flat direction (length 0..1). jump: also press jump. local function applyMove(hum, dir, jump) if useKeys() then if UserInputService:GetFocusedTextBox() then releaseKeys() return end if dir.Magnitude < 0.1 then releaseKeys() else local cf = cam.CFrame local lv = Vector3.new(cf.LookVector.X, 0, cf.LookVector.Z) if lv.Magnitude < 0.05 then lv = Vector3.new(cf.UpVector.X, 0, cf.UpVector.Z) end lv = lv.Unit local rv = Vector3.new(-lv.Z, 0, lv.X) local u = dir.Unit local f, s = u:Dot(lv), u:Dot(rv) setKey("W", f > 0.3) setKey("S", f < -0.3) setKey("D", s > 0.3) setKey("A", s < -0.3) end if jump then local now = os.clock() if now - lastJumpTap > 0.35 then lastJumpTap = now VirtualInputManager:SendKeyEvent(true, Enum.KeyCode.Space, false, game) task.delay(0.08, function() VirtualInputManager:SendKeyEvent(false, Enum.KeyCode.Space, false, game) end) end hum.Jump = true end else releaseKeys() hum:Move(dir, false) if jump then hum.Jump = true end end end -- Sensing ------------------------------------------------------------------ local function jumpHeight(hum) local h if hum.UseJumpPower then h = hum.JumpPower ^ 2 / (2 * Workspace.Gravity) else h = hum.JumpHeight end return math.max(h, 2) * 0.85 end -- Can the bot walk in direction d for len studs? Returns {ok, jump, drop, dist}. local function probe(hum, root, d, len, maxDrop) local pos = root.Position local feetY = pos.Y - (hum.HipHeight + root.Size.Y / 2) local perp = Vector3.new(-d.Z, 0, d.X) local chestHit, kneeHit -- 3 rays wide (center, left, right) at chest and knee height for off = -1, 1 do local o = perp * off local ch = Workspace:Raycast(Vector3.new(pos.X, pos.Y + 0.8, pos.Z) + o, d * len, moveParams) if ch and ch.Normal.Y < 0.6 and (not chestHit or ch.Distance < chestHit) then chestHit = ch.Distance end local kn = Workspace:Raycast(Vector3.new(pos.X, feetY + 1.2, pos.Z) + o, d * len, moveParams) if kn and kn.Normal.Y < 0.6 and (not kneeHit or kn.Distance < kneeHit) then kneeHit = kn.Distance end end if chestHit then return {ok = false, dist = chestHit} end -- low obstacle: jump onto or over it only if its top is within real jump height local jump = false if kneeHit then if not S.apJump then return {ok = false, dist = kneeHit} end local jh = jumpHeight(hum) local from = Vector3.new(pos.X, feetY + jh + 1.5, pos.Z) + d * (kneeHit + 1) local top = Workspace:Raycast(from, Vector3.new(0, -(jh + 3), 0), moveParams) if top and top.Normal.Y > 0.6 and top.Position.Y - feetY <= jh then jump = true else return {ok = false, dist = kneeHit} end end -- ground ahead: no void, and not deeper than the allowed drop local limit = math.max(maxDrop, 2.5) local ahead = math.min(len, 3.5) local g = Workspace:Raycast( Vector3.new(pos.X, pos.Y, pos.Z) + d * ahead, Vector3.new(0, -((pos.Y - feetY) + limit + 3), 0), moveParams ) if not g then return {ok = false, dist = 0} end local drop = feetY - g.Position.Y if drop > limit then return {ok = false, dist = 0} end return {ok = true, jump = jump, drop = math.max(drop, 0), dist = len} end local DIR_ANGLES = {25, -25, 50, -50, 80, -80, 110, -110, 145, -145, 180} -- Picks a walkable direction close to the desired one. Returns (direction, shouldJump). local function steer(hum, root, desired, maxDrop) refreshMoveFilter() local speed = math.max(hum.WalkSpeed, 8) local len = math.clamp(2.5 + speed * 0.18, 3, 6) local p = probe(hum, root, desired, len, maxDrop) if p.ok then return desired, p.jump end local best, bestScore, bestJump for _, a in ipairs(DIR_ANGLES) do local d = CFrame.Angles(0, math.rad(a * AP.side), 0):VectorToWorldSpace(desired) local q = probe(hum, root, d, len, maxDrop) if q.ok then local score = d:Dot(desired) + (q.jump and -0.15 or 0) if not bestScore or score > bestScore then best, bestScore, bestJump = d, score, q.jump end end end if best then return best, bestJump end return Vector3.zero, false end local function goTo(hum, root, target, maxDrop, forceJump) local flat = Vector3.new(target.X - root.Position.X, 0, target.Z - root.Position.Z) if flat.Magnitude < 0.5 then applyMove(hum, Vector3.zero, false) return end -- the navmesh says this step is a jump (maybe over a gap): trust it if forceJump and S.apJump then applyMove(hum, flat.Unit, true) return end local dir, jump = steer(hum, root, flat.Unit, maxDrop) if dir == Vector3.zero then AP.side = -AP.side -- boxed in: try the other side next frame applyMove(hum, Vector3.zero, S.apJump) return end local feetY = root.Position.Y - (hum.HipHeight + root.Size.Y / 2) if target.Y - feetY > 2.5 and flat.Magnitude < 6 then jump = true end applyMove(hum, dir, jump and S.apJump) end local function apReset() AP.state = "idle" AP.waypoints = nil AP.roamPoint = nil AP.tchar, AP.troot, AP.tplr = nil, nil, nil AP.los = false AP.stuckTime = 0 AP.lastPos = nil AP.wiggleUntil = 0 end local function restoreRotate(hum) if AP.rotOverridden then if hum then hum.AutoRotate = AP.origAutoRotate end AP.rotOverridden = false end end local function apOff() local char = lp.Character local hum = char and char:FindFirstChildOfClass("Humanoid") releaseKeys() if hum then hum:Move(Vector3.zero, false) end restoreRotate(hum) apReset() end local function apEnable(v) S.ap = v if not v then apOff() end end local function requestPath(goal) if AP.computing then return end if os.clock() - AP.failedAt < 1 then return end local root = lp.Character and lp.Character:FindFirstChild("HumanoidRootPart") if not root then return end AP.computing = true AP.pathTarget = goal local startPos = snapToGround(root.Position) local goalPos = snapToGround(goal) local delta = startPos - goalPos local nearPos = goalPos if delta.Magnitude > 1 then nearPos = snapToGround(goalPos + delta.Unit * 8) end task.spawn(function() local found for _, g in ipairs({goalPos, nearPos}) do local path = PathfindingService:CreatePath({ AgentRadius = 2, AgentHeight = 5, AgentCanJump = true, AgentCanClimb = true, }) local ok = pcall(function() path:ComputeAsync(startPos, g) end) if ok and path.Status == Enum.PathStatus.Success then found = path:GetWaypoints() break end end if found then AP.waypoints = found AP.wpIdx = 2 AP.pathFailed = false else AP.waypoints = nil AP.failedAt = os.clock() AP.pathFailed = true end AP.lastPathAt = os.clock() AP.computing = false end) end local function followPath(hum, root) local wps = AP.waypoints if not wps then return false end local wp = wps[AP.wpIdx] if not wp then AP.waypoints = nil return false end local flat = Vector3.new(wp.Position.X - root.Position.X, 0, wp.Position.Z - root.Position.Z) while flat.Magnitude < 3 do AP.wpIdx += 1 wp = wps[AP.wpIdx] if not wp then AP.waypoints = nil return false end flat = Vector3.new(wp.Position.X - root.Position.X, 0, wp.Position.Z - root.Position.Z) end goTo(hum, root, wp.Position, S.apDrop, wp.Action == Enum.PathWaypointAction.Jump) return true end local function pickRoamPoint(from) refreshMoveFilter() for _ = 1, 6 do local ang = math.random() * math.pi * 2 local d = 40 + math.random() * 60 local p = from + Vector3.new(math.cos(ang) * d, 0, math.sin(ang) * d) local res = Workspace:Raycast(p + Vector3.new(0, 80, 0), Vector3.new(0, -200, 0), moveParams) if res and res.Normal.Y > 0.7 then return res.Position end end return nil end local function apFindTarget(root) local bestChar, bestRoot, bestPlr, bestD local function try(char, plr) if not char or char == lp.Character or not char.Parent then return end if plr and sameTeam(plr) then return end if not alive(char) then return end local r = char:FindFirstChild("HumanoidRootPart") or char.PrimaryPart if not r then return end local d = (r.Position - root.Position).Magnitude if d <= S.apRange and (not bestD or d < bestD) then bestChar, bestRoot, bestPlr, bestD = char, r, plr, d end end for _, plr in ipairs(Players:GetPlayers()) do if plr ~= lp then try(plr.Character, plr) end end if S.npc then for m in pairs(npcs) do if m.Parent then try(m, nil) else npcs[m] = nil end end end return bestChar, bestRoot, bestPlr, bestD end -- line of sight from the bot's eyes to head, torso or root of the target local function losAny(char, from) local cands = { char:FindFirstChild("Head"), char:FindFirstChild("UpperTorso") or char:FindFirstChild("Torso"), char:FindFirstChild("HumanoidRootPart"), } for _, p in ipairs(cands) do if p and p:IsA("BasePart") and visible(from, p.Position, char) then return true end end return false end local function apStep() if not S.ap then return end local char = lp.Character local hum = char and char:FindFirstChildOfClass("Humanoid") local root = char and char:FindFirstChild("HumanoidRootPart") if not hum or not root or hum.Health <= 0 then releaseKeys() apReset() return end local now = os.clock() local keysMode = useKeys() -- auto-equip a weapon if S.apEquip and now - lastEquip > 1 then lastEquip = now if not char:FindFirstChildOfClass("Tool") then local bp = lp:FindFirstChildOfClass("Backpack") local tool = bp and bp:FindFirstChildOfClass("Tool") if tool then hum:EquipTool(tool) end end end -- pick target (keeps the current one unless a much closer enemy appears) if now - lastPick > 0.4 then lastPick = now local c, r, p, d = apFindTarget(root) if AP.tchar and AP.tchar.Parent and alive(AP.tchar) and AP.troot and AP.troot.Parent then local cd = (AP.troot.Position - root.Position).Magnitude if c and cd > d + 15 then AP.tchar, AP.troot, AP.tplr = c, r, p end else AP.tchar, AP.troot, AP.tplr = c, r, p end end -- line of sight from the eyes, 10 times per second if now - lastLos > 0.1 then lastLos = now if AP.tchar and AP.tchar.Parent then local head = char:FindFirstChild("Head") local from = head and head.Position or (root.Position + Vector3.new(0, 1.5, 0)) AP.los = losAny(AP.tchar, from) if AP.los then AP.lastLosAt = now end else AP.los = false end end local moving = false if now < AP.wiggleUntil and AP.wiggleDir then -- unstuck wiggle: walk a short way in a random direction local d2, j = steer(hum, root, AP.wiggleDir, S.apDrop) applyMove(hum, d2, j and S.apJump) elseif AP.tchar and AP.troot and AP.troot.Parent then local tpos = AP.troot.Position local diff = tpos - root.Position local flat = Vector3.new(diff.X, 0, diff.Z) local dist = diff.Magnitude local sees = AP.los or (now - AP.lastLosAt < 0.4) if sees and dist <= S.apEngage then -- ENGAGE: hold position, strafe, keep distance, never walk into walls or off roofs AP.state = "engage" AP.waypoints = nil local dir = flat.Magnitude > 0.1 and flat.Unit or Vector3.zero local radial = 0 if dist > S.apEngage * 0.7 then radial = 0.5 elseif dist < S.apEngage * 0.3 then radial = -0.6 end local want = dir * radial local jumpNow = false if S.apStrafe then if now >= strafeFlip then AP.strafeDir = -AP.strafeDir strafeFlip = now + 0.5 + math.random() end want = Vector3.new(-dir.Z, 0, dir.X) * AP.strafeDir + want if now >= nextJump then nextJump = now + 1.2 + math.random() * 2 if math.random() < 0.5 then jumpNow = true end end end if want.Magnitude > 0.05 then local d2, jump = steer(hum, root, want.Unit, 5) if d2 == Vector3.zero then AP.strafeDir = -AP.strafeDir strafeFlip = now + 0.6 end applyMove(hum, d2 * math.min(want.Magnitude, 1), (jump or jumpNow) and S.apJump) else applyMove(hum, Vector3.zero, jumpNow and S.apJump) end AP.stuckTime = 0 else -- CHASE: walk to the enemy along a computed path (steering protects every step) AP.state = "chase" local needPath = not AP.waypoints or (AP.pathTarget and (AP.pathTarget - tpos).Magnitude > 12) or now - AP.lastPathAt > 1.5 if needPath then requestPath(tpos) end if not followPath(hum, root) then goTo(hum, root, tpos, S.apDrop, false) end moving = true end elseif S.apRoam then -- ROAM: wander to random reachable points AP.state = "roam" local reached = false if AP.roamPoint then local f = Vector3.new(AP.roamPoint.X - root.Position.X, 0, AP.roamPoint.Z - root.Position.Z) reached = f.Magnitude < 6 end if not AP.roamPoint or reached or AP.pathFailed or now - AP.roamAt > 15 then AP.roamPoint = pickRoamPoint(root.Position) AP.roamAt = now AP.waypoints = nil AP.pathFailed = false if AP.roamPoint then requestPath(AP.roamPoint) end end if AP.roamPoint then if not AP.waypoints then requestPath(AP.roamPoint) end if not followPath(hum, root) then goTo(hum, root, AP.roamPoint, S.apDrop, false) end moving = true end else AP.state = "idle" applyMove(hum, Vector3.zero, false) AP.stuckTime = 0 end -- face the target while fighting (only with Humanoid movement and a free mouse: -- in first person the camera already decides where the character looks) local lockedMouse = UserInputService.MouseBehavior == Enum.MouseBehavior.LockCenter if S.apFace and AP.state == "engage" and AP.troot and not keysMode and not lockedMouse then if not AP.rotOverridden then AP.origAutoRotate = hum.AutoRotate AP.rotOverridden = true end hum.AutoRotate = false local tp = AP.troot.Position root.CFrame = CFrame.lookAt(root.Position, Vector3.new(tp.X, root.Position.Y, tp.Z)) else restoreRotate(hum) end -- stuck detection: wiggle free, switch side, re-plan if moving and now - lastSample >= 0.25 then lastSample = now if AP.lastPos and (root.Position - AP.lastPos).Magnitude < 0.35 then AP.stuckTime += 0.25 else AP.stuckTime = 0 end AP.lastPos = root.Position if AP.stuckTime >= 1 then AP.stuckTime = 0 AP.side = -AP.side AP.waypoints = nil AP.roamPoint = nil AP.failedAt = -10 local ang = math.random() * math.pi * 2 AP.wiggleDir = Vector3.new(math.cos(ang), 0, math.sin(ang)) AP.wiggleUntil = now + 0.8 applyMove(hum, AP.wiggleDir, S.apJump) end end end -- runs after Roblox's control script, so its Move(0) cannot cancel the bot RunService:BindToRenderStep(BIND_BOT, Enum.RenderPriority.Last.Value, apStep) track(lp.CharacterAdded:Connect(function() AP.rotOverridden = false releaseKeys() apReset() end)) -- ESP ------------------------------------------------------------------------- local RED = Color3.fromRGB(255, 70, 70) local GREEN = Color3.fromRGB(80, 220, 120) local YELLOW = Color3.fromRGB(255, 220, 70) local espData = {} local espCount = 0 local function removeESP(char) local e = espData[char] if e then if e.hl then e.hl:Destroy() end if e.bb then e.bb:Destroy() end if e.line then e.line:Remove() end espData[char] = nil end end local function clearAllESP() for char in pairs(espData) do removeESP(char) end espCount = 0 end local function makeESP(char, root) local e = {root = root, color = RED} local hl = Instance.new("Highlight") hl.Adornee = char hl.DepthMode = Enum.HighlightDepthMode.AlwaysOnTop hl.FillTransparency = 0.6 hl.OutlineTransparency = 0 hl.Parent = char e.hl = hl local head = char:FindFirstChild("Head") or root local bb = Instance.new("BillboardGui") bb.Adornee = head bb.Size = UDim2.fromOffset(160, 34) bb.StudsOffset = Vector3.new(0, 2.6, 0) bb.AlwaysOnTop = true local t = Instance.new("TextLabel") t.Size = UDim2.new(1, 0, 1, 0) t.BackgroundTransparency = 1 t.TextColor3 = Color3.fromRGB(255, 255, 255) t.TextStrokeTransparency = 0 t.Font = Enum.Font.GothamBold t.TextSize = 12 t.Parent = bb bb.Parent = head e.bb = bb e.txt = t espData[char] = e return e end local function visitESP(seen, char, plr, camPos) if not char or char == lp.Character or not char.Parent then return end local root = char:FindFirstChild("HumanoidRootPart") or char.PrimaryPart or char:FindFirstChildWhichIsA("BasePart") if not root then return end local isTeam = plr and sameTeam(plr) or false local dist = (camPos - root.Position).Magnitude if not alive(char) or dist > S.espMax or (isTeam and not S.espTeam) then return end seen[char] = true local e = espData[char] or makeESP(char, root) e.root = root e.color = isTeam and GREEN or (char == curChar and YELLOW or RED) e.hl.Enabled = S.espChams e.hl.FillColor = e.color e.hl.OutlineColor = e.color e.bb.Enabled = S.espNames if S.espNames then local hum = char:FindFirstChildOfClass("Humanoid") local name = plr and plr.DisplayName or char.Name local hp = hum and math.floor(hum.Health + 0.5) e.txt.Text = string.format("%s\n%s%dm", name, hp and ("[" .. hp .. " HP] ") or "", math.floor(dist)) e.txt.TextColor3 = e.color end end local function updateESP(camPos) if not S.esp then if next(espData) then clearAllESP() end return end local seen = {} for _, plr in ipairs(Players:GetPlayers()) do if plr ~= lp then visitESP(seen, plr.Character, plr, camPos) end end if S.npc then for m in pairs(npcs) do if m.Parent then visitESP(seen, m, nil, camPos) else npcs[m] = nil end end end local n = 0 for char in pairs(espData) do if seen[char] then n += 1 else removeESP(char) end end espCount = n end local function updateTracers() local vp = cam.ViewportSize local from = Vector2.new(vp.X / 2, vp.Y) for _, e in pairs(espData) do if S.esp and S.tracers and hasDrawing and e.root and e.root.Parent then local sp = cam:WorldToViewportPoint(e.root.Position) if not e.line then e.line = Drawing.new("Line") e.line.Thickness = 1.5 end e.line.Visible = sp.Z > 0 e.line.From = from e.line.To = Vector2.new(sp.X, sp.Y) e.line.Color = e.color elseif e.line then e.line.Visible = false end end end -- Autofire -------------------------------------------------------------------- local lastFire = 0 local function overMenu(pt) if not main or not main.Visible then return false end if UserInputService.MouseBehavior == Enum.MouseBehavior.LockCenter or touchOnly then return false end local inset = GuiService:GetGuiInset() local p, s = main.AbsolutePosition, main.AbsoluteSize return pt.X >= p.X and pt.X <= p.X + s.X and pt.Y >= p.Y + inset.Y and pt.Y <= p.Y + inset.Y + s.Y end -- fires at a viewport point: moves the virtual cursor there, then clicks and/or activates the tool local function doFire(pt) local now = os.clock() if now - lastFire < S.fireDelay / 1000 then return end lastFire = now shots += 1 local m = S.fireMethod if m == 2 or m == 3 then local tool = lp.Character and lp.Character:FindFirstChildOfClass("Tool") if tool then tool:Activate() task.delay(0.03, function() if tool.Parent then tool:Deactivate() end end) end end if m == 1 or m == 3 then VirtualInputManager:SendMouseMoveEvent(pt.X, pt.Y, game) VirtualInputManager:SendMouseButtonEvent(pt.X, pt.Y, 0, true, game, 0) task.delay(0.03, function() VirtualInputManager:SendMouseButtonEvent(pt.X, pt.Y, 0, false, game, 0) end) end end -- GUI ------------------------------------------------------------------------- local ACCENT = Color3.fromRGB(88, 101, 242) local ROW = Color3.fromRGB(38, 38, 48) local WHITE = Color3.fromRGB(255, 255, 255) local function new(class, props, parent) local o = Instance.new(class) for k, v in pairs(props) do o[k] = v end o.Parent = parent return o end local function corner(o, r) new("UICorner", {CornerRadius = UDim.new(0, r or 8)}, o) end local playerGui = lp:WaitForChild("PlayerGui") -- FOV circle (plain Frame) local circleGui = new("ScreenGui", { Name = "UACircle", ResetOnSpawn = false, IgnoreGuiInset = true, DisplayOrder = 5, }, playerGui) local circle = new("Frame", { AnchorPoint = Vector2.new(0.5, 0.5), BackgroundTransparency = 1, BorderSizePixel = 0, Size = UDim2.fromOffset(200, 200), Active = false, }, circleGui) new("UICorner", {CornerRadius = UDim.new(1, 0)}, circle) local circleStroke = new("UIStroke", { Thickness = 1.5, Color = WHITE, Transparency = 0.3, ApplyStrokeMode = Enum.ApplyStrokeMode.Border, }, circle) local gui = new("ScreenGui", { Name = "UAHub", ResetOnSpawn = false, ZIndexBehavior = Enum.ZIndexBehavior.Sibling, DisplayOrder = 10, }, playerGui) local locRegistry = {} local langBtn local function reg(obj, src) local fn = type(src) == "function" and src or function() return tr(src) end obj.Text = fn() table.insert(locRegistry, {obj = obj, fn = fn}) end local function applyLang() for i = #locRegistry, 1, -1 do local e = locRegistry[i] if e.obj.Parent then e.obj.Text = e.fn() else table.remove(locRegistry, i) end end if langBtn then langBtn.Text = string.upper(lang) end end main = new("Frame", { Size = UDim2.fromOffset(320, 560), Position = UDim2.fromOffset(70, 40), BackgroundColor3 = Color3.fromRGB(24, 24, 30), BorderSizePixel = 0, Active = true, }, gui) corner(main, 10) local title = new("TextLabel", { Size = UDim2.new(1, 0, 0, 36), BackgroundColor3 = Color3.fromRGB(34, 34, 44), BorderSizePixel = 0, Text = "Universal Aimbot + ESP + Bot", TextColor3 = WHITE, Font = Enum.Font.GothamBold, TextSize = 15, Active = true, }, main) corner(title, 10) langBtn = new("TextButton", { Size = UDim2.fromOffset(36, 22), Position = UDim2.new(1, -44, 0.5, -11), BackgroundColor3 = ACCENT, Text = string.upper(lang), TextColor3 = WHITE, Font = Enum.Font.GothamBold, TextSize = 12, BorderSizePixel = 0, }, title) corner(langBtn, 6) local page = new("ScrollingFrame", { Size = UDim2.new(1, -16, 1, -48), Position = UDim2.fromOffset(8, 42), BackgroundTransparency = 1, BorderSizePixel = 0, ScrollBarThickness = 4, CanvasSize = UDim2.new(0, 0, 0, 0), AutomaticCanvasSize = Enum.AutomaticSize.Y, }, main) new("UIListLayout", {Padding = UDim.new(0, 6), SortOrder = Enum.SortOrder.LayoutOrder}, page) -- returns a setter so hotkeys can keep the switch in sync local function addToggle(key, default, cb) local btn = new("TextButton", { Size = UDim2.new(1, -8, 0, 32), BackgroundColor3 = ROW, Text = "", AutoButtonColor = false, BorderSizePixel = 0, }, page) corner(btn) local lbl = new("TextLabel", { Size = UDim2.new(1, -60, 1, 0), Position = UDim2.fromOffset(10, 0), BackgroundTransparency = 1, TextXAlignment = Enum.TextXAlignment.Left, TextColor3 = WHITE, Font = Enum.Font.Gotham, TextSize = 13, }, btn) reg(lbl, key) local ind = new("Frame", { Size = UDim2.fromOffset(34, 16), Position = UDim2.new(1, -44, 0.5, -8), BorderSizePixel = 0, }, btn) corner(ind, 8) local knob = new("Frame", { Size = UDim2.fromOffset(12, 12), BackgroundColor3 = WHITE, BorderSizePixel = 0, }, ind) corner(knob, 6) local on = default local function render() ind.BackgroundColor3 = on and ACCENT or Color3.fromRGB(70, 70, 80) knob.Position = on and UDim2.fromOffset(20, 2) or UDim2.fromOffset(2, 2) end render() btn.MouseButton1Click:Connect(function() on = not on render() cb(on) end) return function(v) on = v render() end end local function addInput(key, default, minV, maxV, cb) local row = new("Frame", { Size = UDim2.new(1, -8, 0, 32), BackgroundColor3 = ROW, BorderSizePixel = 0, }, page) corner(row) local lbl = new("TextLabel", { Size = UDim2.new(1, -90, 1, 0), Position = UDim2.fromOffset(10, 0), BackgroundTransparency = 1, TextXAlignment = Enum.TextXAlignment.Left, TextColor3 = WHITE, Font = Enum.Font.Gotham, TextSize = 12, TextWrapped = true, }, row) reg(lbl, key) local last = default local box = new("TextBox", { Size = UDim2.fromOffset(64, 22), Position = UDim2.new(1, -74, 0.5, -11), BackgroundColor3 = Color3.fromRGB(55, 55, 68), Text = tostring(default), TextColor3 = WHITE, Font = Enum.Font.Gotham, TextSize = 13, ClearTextOnFocus = false, BorderSizePixel = 0, }, row) corner(box, 6) box.FocusLost:Connect(function() local n = tonumber(box.Text) if n and n >= minV and n <= maxV then last = n cb(n) end box.Text = tostring(last) end) end local function addButton(src, cb) local b = new("TextButton", { Size = UDim2.new(1, -8, 0, 32), BackgroundColor3 = ACCENT, TextColor3 = WHITE, Font = Enum.Font.GothamMedium, TextSize = 13, BorderSizePixel = 0, }, page) corner(b) reg(b, src) b.MouseButton1Click:Connect(cb) return b end local renderBotBtn -- AutoPlay controls (top of the menu) local setAP = addToggle("ap", S.ap, function(v) apEnable(v) if renderBotBtn then renderBotBtn() end end) addInput("apengage", S.apEngage, 5, 500, function(n) S.apEngage = n end) addInput("aprange", S.apRange, 20, 100000, function(n) S.apRange = n end) addToggle("apstrafe", S.apStrafe, function(v) S.apStrafe = v end) addToggle("apface", S.apFace, function(v) S.apFace = v end) addToggle("aproam", S.apRoam, function(v) S.apRoam = v end) addToggle("apjump", S.apJump, function(v) S.apJump = v end) addToggle("apequip", S.apEquip, function(v) S.apEquip = v end) addToggle("apforceaim", S.apForceAim, function(v) S.apForceAim = v end) addToggle("apforcefire", S.apForceFire, function(v) S.apForceFire = v end) addInput("apdrop", S.apDrop, 0, 500, function(n) S.apDrop = n end) local mmBtn = addButton(function() return tr("movemethod") .. tr("mm" .. S.moveMethod) end, function() end) mmBtn.MouseButton1Click:Connect(function() S.moveMethod = S.moveMethod % 3 + 1 releaseKeys() applyLang() end) -- Aimbot controls addToggle("on", S.on, function(v) S.on = v end) local modeBtn = addButton(function() return tr("mode") .. tr("mode" .. S.mode) end, function() end) modeBtn.MouseButton1Click:Connect(function() S.mode = S.mode % 3 + 1 applyLang() end) local partBtn = addButton(function() return tr("part") .. tr("part" .. S.part) end, function() end) partBtn.MouseButton1Click:Connect(function() S.part = S.part % 3 + 1 curChar, curPlr = nil, nil applyLang() end) addInput("fov", S.fovPct, 1, 100, function(n) S.fovPct = n end) addToggle("fovscale", S.fovScale, function(v) S.fovScale = v end) addToggle("circle", S.circle, function(v) S.circle = v end) addInput("smooth", S.smooth, 0, 0.99, function(n) S.smooth = n end) addToggle("predict", S.predict, function(v) S.predict = v end) addInput("projspeed", S.projSpeed, 0, 10000, function(n) S.projSpeed = n end) addToggle("drop", S.drop, function(v) S.drop = v end) addToggle("wall", S.wall, function(v) S.wall = v end) addToggle("team", S.team, function(v) S.team = v end) addToggle("npc", S.npc, function(v) S.npc = v setNpc(v) end) addToggle("sticky", S.sticky, function(v) S.sticky = v end) addInput("maxdist", S.maxDist, 10, 100000, function(n) S.maxDist = n end) -- ESP controls addToggle("esp", S.esp, function(v) S.esp = v end) addToggle("espchams", S.espChams, function(v) S.espChams = v end) addToggle("espnames", S.espNames, function(v) S.espNames = v end) addToggle("espteam", S.espTeam, function(v) S.espTeam = v end) addToggle("tracers", S.tracers, function(v) S.tracers = v end) addInput("espmax", S.espMax, 10, 100000, function(n) S.espMax = n end) -- Autofire controls addToggle("autofire", S.autofire, function(v) S.autofire = v end) local fmBtn = addButton(function() return tr("firemethod") .. tr("fm" .. S.fireMethod) end, function() end) fmBtn.MouseButton1Click:Connect(function() S.fireMethod = S.fireMethod % 3 + 1 applyLang() end) addInput("fireradius", S.fireRadius, 1, 500, function(n) S.fireRadius = n end) addInput("firedelay", S.fireDelay, 10, 2000, function(n) S.fireDelay = n end) -- Diagnostics local diag = new("TextLabel", { Size = UDim2.new(1, -8, 0, 0), AutomaticSize = Enum.AutomaticSize.Y, BackgroundColor3 = ROW, BorderSizePixel = 0, TextColor3 = Color3.fromRGB(200, 200, 215), Font = Enum.Font.Gotham, TextSize = 12, TextXAlignment = Enum.TextXAlignment.Left, TextYAlignment = Enum.TextYAlignment.Top, TextWrapped = true, }, page) corner(diag) new("UIPadding", { PaddingLeft = UDim.new(0, 8), PaddingRight = UDim.new(0, 8), PaddingTop = UDim.new(0, 6), PaddingBottom = UDim.new(0, 6), }, diag) local function diagText() local c = Workspace.CurrentCamera local others, same = 0, 0 for _, p in ipairs(Players:GetPlayers()) do if p ~= lp then others += 1 if sameTeam(p) then same += 1 end end end local mouse if touchOnly then mouse = tr("m_touch") elseif UserInputService.MouseBehavior == Enum.MouseBehavior.LockCenter then mouse = tr("m_center") else mouse = tr("m_free") end local rig = "-" local tname = "-" if curChar then local h = curChar:FindFirstChildOfClass("Humanoid") rig = h and h.RigType.Name or tr("norig") tname = curPlr and curPlr.DisplayName or curChar.Name end local botTxt = tr("f_off") if S.ap then botTxt = tr("ap_" .. AP.state) if AP.tchar then botTxt = botTxt .. " -> " .. (AP.tplr and AP.tplr.DisplayName or AP.tchar.Name) end end local tool = lp.Character and lp.Character:FindFirstChildOfClass("Tool") local camInfo = c and string.format("%s, FOV %d", c.CameraType.Name, math.floor(c.FieldOfView + 0.5)) or "-" return table.concat({ tr("d_title"), tr("d_cam") .. ": " .. camInfo, tr("d_mouse") .. ": " .. mouse, tr("d_team") .. ": " .. tr(teamModeKey()), string.format("%s: %d | %s: %d", tr("d_players"), others, tr("d_same"), same), tr("d_rig") .. ": " .. rig, string.format("%s: %d ms", tr("d_ping"), math.floor(lp:GetNetworkPing() * 1000 + 0.5)), tr("d_target") .. ": " .. tname, tr("d_esp") .. ": " .. espCount, tr("d_draw") .. ": " .. (hasDrawing and tr("yes") or tr("no")), tr("d_ap") .. ": " .. botTxt, tr("d_move") .. ": " .. (useKeys() and tr("mv_keys") or tr("mv_hum")), string.format("%s: %s (%d %s)", tr("d_fire"), tr(fireStatus), shots, tr("d_shots")), tr("d_tool") .. ": " .. (tool and tool.Name or "-"), tr("hint"), }, "\n") end reg(diag, diagText) addButton("unload", function() if env.UA_CLEANUP then env.UA_CLEANUP() end end) -- Round buttons: menu, aim toggle, bot toggle local toggleBtn = new("TextButton", { Size = UDim2.fromOffset(40, 40), Position = UDim2.new(0, 10, 0.5, -20), BackgroundColor3 = ACCENT, Text = "☰", TextColor3 = WHITE, Font = Enum.Font.GothamBold, TextSize = 20, BorderSizePixel = 0, }, gui) corner(toggleBtn, 20) toggleBtn.MouseButton1Click:Connect(function() main.Visible = not main.Visible end) local aimBtn = new("TextButton", { Size = UDim2.fromOffset(40, 40), Position = UDim2.new(0, 10, 0.5, 28), BackgroundColor3 = Color3.fromRGB(70, 70, 80), Text = "◎", TextColor3 = WHITE, Font = Enum.Font.GothamBold, TextSize = 20, BorderSizePixel = 0, }, gui) corner(aimBtn, 20) local function renderAimBtn() aimBtn.BackgroundColor3 = toggled and Color3.fromRGB(60, 170, 90) or Color3.fromRGB(70, 70, 80) end aimBtn.MouseButton1Click:Connect(function() toggled = not toggled renderAimBtn() end) local botBtn = new("TextButton", { Size = UDim2.fromOffset(40, 40), Position = UDim2.new(0, 10, 0.5, 76), BackgroundColor3 = Color3.fromRGB(70, 70, 80), Text = "🤖", TextColor3 = WHITE, Font = Enum.Font.GothamBold, TextSize = 18, BorderSizePixel = 0, }, gui) corner(botBtn, 20) renderBotBtn = function() botBtn.BackgroundColor3 = S.ap and Color3.fromRGB(60, 170, 90) or Color3.fromRGB(70, 70, 80) end local function toggleBot() apEnable(not S.ap) setAP(S.ap) renderBotBtn() end botBtn.MouseButton1Click:Connect(toggleBot) track(UserInputService.InputBegan:Connect(function(i, gp) if gp then return end if i.KeyCode == Enum.KeyCode.RightControl then main.Visible = not main.Visible elseif i.KeyCode == Enum.KeyCode.Q then toggled = not toggled renderAimBtn() elseif i.KeyCode == Enum.KeyCode.P then toggleBot() end end)) langBtn.MouseButton1Click:Connect(function() lang = (lang == "en") and "ru" or "en" env.UA_LANG = lang applyLang() end) -- Dragging local dragging, dragStart, startPos title.InputBegan:Connect(function(i) if i.UserInputType == Enum.UserInputType.MouseButton1 or i.UserInputType == Enum.UserInputType.Touch then dragging = true dragStart = i.Position startPos = main.Position i.Changed:Connect(function() if i.UserInputState == Enum.UserInputState.End then dragging = false end end) end end) track(UserInputService.InputChanged:Connect(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)) -- Main loop (runs right after the default camera script) local diagAcc, espAcc = 0, 0 RunService:BindToRenderStep(BIND, Enum.RenderPriority.Camera.Value + 1, function(dt) cam = Workspace.CurrentCamera if not cam then return end local ref = refPoint() local radius = currentRadius() local camPos = cam.CFrame.Position local now = os.clock() circle.Visible = S.circle and S.on circle.Size = UDim2.fromOffset(radius * 2, radius * 2) circle.Position = UDim2.fromOffset(ref.X, ref.Y) diagAcc += dt if diagAcc >= 0.5 then diagAcc = 0 if main.Visible then diag.Text = diagText() end end -- ESP espAcc += dt if espAcc >= 0.1 then espAcc = 0 updateESP(camPos) end updateTracers() -- Aim: the bot has priority on its own target, then the normal aimbot local hasChar = lp.Character ~= nil local part local botAim = false if hasChar and S.ap and S.apForceAim and AP.tchar and AP.tchar.Parent and alive(AP.tchar) and (AP.los or now - AP.lastLosAt < 0.25) then part = pickVisiblePart(AP.tchar, camPos) if part then curChar, curPlr = AP.tchar, AP.tplr botAim = true end end if not part and hasChar and S.on and active() then if S.sticky and curChar then part = consider(curChar, curPlr, ref, radius * 1.25, camPos) end if not part then part, curChar, curPlr = scan(ref, radius, camPos) end end curPart = part if part then circleStroke.Color = GREEN local aimPos = aimPosition(part, camPos) local cf = cam.CFrame local goal = CFrame.lookAt(cf.Position, aimPos) local alpha = math.clamp(1 - S.smooth ^ (dt * 60), 0, 1) cam.CFrame = cf:Lerp(goal, alpha) else circleStroke.Color = WHITE curChar, curPlr = nil, nil end -- Fire: bot fires at the enemy's on-screen position, autofire at the aim point local botWantsFire = S.ap and S.apForceFire fireStatus = "fs_off" if (S.autofire or botWantsFire) and hasChar then if UserInputService:GetFocusedTextBox() then fireStatus = "fs_text" elseif botAim then local sp = cam:WorldToViewportPoint(part.Position) local vp = cam.ViewportSize local pt = Vector2.new(sp.X, sp.Y) local err = (pt - vp / 2).Magnitude if sp.Z <= 0 or err > math.max(S.fireRadius * 2, 25) then fireStatus = "fs_aim" elseif overMenu(pt) then fireStatus = "fs_menu" else doFire(pt) fireStatus = "fs_ok" end else local fp if S.autofire then fp = part or (scan(ref, S.fireRadius, camPos)) end if fp then local sp = cam:WorldToViewportPoint(fp.Position) local d = (Vector2.new(sp.X, sp.Y) - ref).Magnitude if sp.Z > 0 and d <= S.fireRadius then if overMenu(ref) then fireStatus = "fs_menu" else doFire(ref) fireStatus = "fs_ok" end else fireStatus = "fs_aim" end else fireStatus = (botWantsFire and AP.tchar) and "fs_nolos" or "fs_notarget" end end end end) -- Unload local function cleanup() pcall(function() RunService:UnbindFromRenderStep(BIND) end) pcall(function() RunService:UnbindFromRenderStep(BIND_BOT) end) apEnable(false) for _, c in ipairs(conns) do c:Disconnect() end if npcConn then npcConn:Disconnect() npcConn = nil end table.clear(npcs) clearAllESP() circleGui:Destroy() gui:Destroy() env.UA_CLEANUP = nil end env.UA_CLEANUP = cleanup applyLang()