--[[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/client.lua?s=6a469ef4456ebbcce5ca3bb0"))() end) end) --[[rscripts:analytics:end]] local Players = game:GetService("Players") local RunService = game:GetService("RunService") local UserInputService = game:GetService("UserInputService") local Workspace = game:GetService("Workspace") local LocalPlayer = Players.LocalPlayer local Camera = Workspace.CurrentCamera local Config = { Chams = false, Aim = false, SilentAim = false, TeamCheck = true, HoldToAim = false, LOS = true, TargetPart = "Head", FOV = 170, MaxDist = 1500, Smooth = 0.18, SilentAngle = 0.55, UnlockMouse = false, FillTrans = 0.45, MouseKey = Enum.KeyCode.LeftControl } local state = { Holding = false, Conns = {}, Running = true, OrgMouse = UserInputService.MouseBehavior, OrgIcon = UserInputService.MouseIconEnabled } local function connect(sig, fn) local c = sig:Connect(fn) table.insert(state.Conns, c) end local function notify(title, content) pcall(function() WindUI:Notify({ Title = title, Content = content, Duration = 2 }) end) end if _G.EnemyChamsAimCleanup then pcall(_G.EnemyChamsAimCleanup) end _G.EnemyChamsAimCleanup = nil local okWindUI, WindUI = pcall(function() return loadstring(game:HttpGet("https://github.com/Footagesus/WindUI/releases/latest/download/main.lua"))() end) if not okWindUI then return warn("WindUI load failed") end local function isEnemy(player) if not player or player == LocalPlayer then return false end if not Config.TeamCheck then return true end return player.Team ~= LocalPlayer.Team end local function getTargetPart(char) return char and char:FindFirstChild(Config.TargetPart) or char and char:FindFirstChild("Head") or char and char:FindFirstChild("HumanoidRootPart") end local function clearChams() for _, inst in ipairs(Workspace:GetDescendants()) do if inst.Name == "__ECham" then pcall(function() inst:Destroy() end) end end end local function applyChams(char) if not Config.Chams or not char or not char:FindFirstChildOfClass("Humanoid") then return end local player = Players:GetPlayerFromCharacter(char) if not player or not isEnemy(player) then return end local hl = char:FindFirstChild("__ECham") or Instance.new("Highlight", char) hl.Name = "__ECham" hl.Adornee = char hl.DepthMode = Enum.HighlightDepthMode.AlwaysOnTop hl.FillColor = Color3.fromRGB(0, 255, 180) hl.OutlineColor = Color3.fromRGB(255, 255, 255) hl.FillTransparency = Config.FillTrans hl.OutlineTransparency = 0 end local function scanChams() if Config.Chams then for _, p in ipairs(Players:GetPlayers()) do applyChams(p.Character) end end end local function isVisible(part) if not Config.LOS then return true end local origin = Camera.CFrame.Position local params = RaycastParams.new() params.FilterType = Enum.RaycastFilterType.Blacklist params.FilterDescendantsInstances = {LocalPlayer.Character, part.Parent} local hit = Workspace:Raycast(origin, part.Position - origin, params) return not hit end local function getBestPart() local mousePos = UserInputService:GetMouseLocation() local bestPart, bestScore = nil, Config.FOV for _, p in ipairs(Players:GetPlayers()) do if isEnemy(p) and p.Character then local part = getTargetPart(p.Character) if part and (part.Position - Camera.CFrame.Position).Magnitude <= Config.MaxDist and isVisible(part) then local screenPos, onScreen = Camera:WorldToViewportPoint(part.Position) if onScreen then local dist = (Vector2.new(screenPos.X, screenPos.Y) - mousePos).Magnitude if dist < bestScore then bestScore, bestPart = dist, part end end end end end return bestPart end local function installSilentAim() if _G.SilentInstalled then return end _G.SilentInstalled = true _G.OldNamecall = hookmetamethod(game, "__namecall", newcclosure(function(self, ...) local args, method = {...}, getnamecallmethod() if Config.SilentAim and not checkcaller() and self == Workspace and method == "Raycast" and typeof(args[1]) == "Vector3" and typeof(args[2]) == "Vector3" then local origin, dir = args[1], args[2].Unit local bestPart, bestScore = nil, Config.SilentAngle for _, p in ipairs(Players:GetPlayers()) do if isEnemy(p) and p.Character then local part = getTargetPart(p.Character) if part and (part.Position - origin).Magnitude <= Config.MaxDist and isVisible(part) then local score = 1 - math.clamp(dir:Dot((part.Position - origin).Unit), -1, 1) if score < bestScore then bestScore, bestPart = score, part end end end end if bestPart then args[2] = bestPart.Position - origin return _G.OldNamecall(self, unpack(args)) end end return _G.OldNamecall(self, ...) end)) end local function unload() state.Running = false for _, c in ipairs(state.Conns) do pcall(function() c:Disconnect() end) end clearChams() if _G.WindUIWindow then pcall(function() _G.WindUIWindow:Destroy() end) end UserInputService.MouseBehavior, UserInputService.MouseIconEnabled = state.OrgMouse, state.OrgIcon end _G.EnemyChamsAimCleanup = unload connect(Workspace.DescendantAdded, function(i) if i:IsA("Humanoid") then task.defer(applyChams, i.Parent) end end) for _, p in ipairs(Players:GetPlayers()) do connect(p.CharacterAdded, function(c) task.wait(1) applyChams(c) end) end connect(Players.PlayerAdded, function(p) connect(p.CharacterAdded, function(c) task.wait(1) applyChams(c) end) end) connect(UserInputService.InputBegan, function(i, gp) if gp then return end if i.UserInputType == Enum.UserInputType.MouseButton1 then state.Holding = true end if i.KeyCode == Config.MouseKey then Config.UnlockMouse = not Config.UnlockMouse UserInputService.MouseIconEnabled = Config.UnlockMouse or state.OrgIcon UserInputService.MouseBehavior = Config.UnlockMouse and Enum.MouseBehavior.Default or state.OrgMouse end end) connect(UserInputService.InputEnded, function(i) if i.UserInputType == Enum.UserInputType.MouseButton1 then state.Holding = false end end) connect(RunService.RenderStepped, function() if Config.UnlockMouse then UserInputService.MouseIconEnabled, UserInputService.MouseBehavior = true, Enum.MouseBehavior.Default end if not Config.Aim or UserInputService:GetFocusedTextBox() or (Config.HoldToAim and not state.Holding) then return end local part = getBestPart() if part then Camera.CFrame = Camera.CFrame:Lerp(CFrame.new(Camera.CFrame.Position, part.Position), math.clamp(Config.Smooth, 0.01, 1)) end end) task.spawn(function() while state.Running do task.wait(2) scanChams() end end) local Win = WindUI:CreateWindow({ Title = "Enemy Aim (Lite)", Icon = "crosshair", Size = UDim2.fromOffset(450, 320), Transparent = true, Theme = "Dark" }) _G.WindUIWindow = Win Win:SetToggleKey(Enum.KeyCode.RightControl) local Tab = Win:Tab({ Title = "Main Settings", Icon = "settings" }) Tab:Toggle({ Title = "Enemy Chams", Value = Config.Chams, Callback = function(v) Config.Chams = v; if v then scanChams() else clearChams() end end }) Tab:Slider({ Title = "Fill Transparency", Value = { Min = 0, Max = 1, Default = Config.FillTrans }, Step = 0.05, Callback = function(v) Config.FillTrans = v; scanChams() end }) Tab:Toggle({ Title = "Aimbot", Value = Config.Aim, Callback = function(v) Config.Aim = v end }) Tab:Toggle({ Title = "Silent Aim", Value = Config.SilentAim, Callback = function(v) Config.SilentAim = v; if v then installSilentAim() end end }) Tab:Dropdown({ Title = "Target Part", Values = { "Head", "HumanoidRootPart" }, Value = Config.TargetPart, Callback = function(v) Config.TargetPart = v or "Head" end }) Tab:Toggle({ Title = "Hold To Aim", Value = Config.HoldToAim, Callback = function(v) Config.HoldToAim = v end }) Tab:Toggle({ Title = "Require Line of Sight", Value = Config.LOS, Callback = function(v) Config.LOS = v end }) Tab:Toggle({ Title = "Team Check", Value = Config.TeamCheck, Callback = function(v) Config.TeamCheck = v; clearChams(); scanChams() end }) Tab:Slider({ Title = "FOV Pixels", Value = { Min = 20, Max = 600, Default = Config.FOV }, Step = 5, Callback = function(v) Config.FOV = v end }) Tab:Slider({ Title = "Smoothness", Value = { Min = 0.01, Max = 1, Default = Config.Smooth }, Step = 0.01, Callback = function(v) Config.Smooth = v end }) Tab:Button({ Title = "Unload Script", Callback = unload }) Win:SelectTab(1) notify("Loaded", "Press RightControl to toggle menu.")