-- [[ 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 ]] local p1 = game:GetService("Players") local w = game:GetService("Workspace") local lp = p1.LocalPlayer local cfg = { sm = true, TargetPart = "Head", fov = 180, } local targets = {} task.spawn(function() while true do local t = {} for _, p in ipairs(p1:GetPlayers()) do if p ~= lp and p.Character then local h = p.Character:FindFirstChildOfClass("Humanoid") local part = p.Character:FindFirstChild(cfg.TargetPart) if h and h.Health > 0 and part then table.insert(t, part) end end end targets = t task.wait(0.5) end end) local function getClosestTarget() if not cfg.sm then return nil, nil end local cam = w.CurrentCamera if not cam then return nil, nil end local bestDist = cfg.fov local bestPos, bestPart = nil, nil local center = Vector2.new(cam.ViewportSize.X / 2, cam.ViewportSize.Y / 2) for _, part in ipairs(targets) do if part and part.Parent then local pos, onScreen = cam:WorldToViewportPoint(part.Position) if onScreen and pos.Z > 0 then local dist = (Vector2.new(pos.X, pos.Y) - center).Magnitude if dist < bestDist then bestDist = dist bestPos = part.Position bestPart = part end end end end return bestPos, bestPart end local function reqAimRay(mod) if typeof(mod) == "Instance" and mod:IsA("ModuleScript") then local ok, tbl = pcall(require, mod) if ok and type(tbl) == "table" and type(tbl.shot) == "function" then return tbl end end end local function getAimRayModule() if type(getloadedmodules) == "function" then for _, mod in ipairs(getloadedmodules()) do if mod.Name == "AimRay" then local tbl = reqAimRay(mod) if tbl then return tbl end end end end local ps = lp:FindFirstChildOfClass("PlayerScripts") local mod = ps and ps:FindFirstChild("Client") and ps.Client:FindFirstChild("Lib") and ps.Client.Lib:FindFirstChild("AimRay") return reqAimRay(mod) end local AimRay = getAimRayModule() if AimRay then local oldShot = AimRay.shot local oldPreview = AimRay.preview local function aimAtTarget(oldFn, ...) local origin, dir = oldFn(...) local targetPos = getClosestTarget() if cfg.sm and targetPos and typeof(origin) == "Vector3" then local delta = targetPos - origin if delta.Magnitude > 0.001 then return origin, delta.Unit end end return origin, dir end function AimRay.shot(...) return aimAtTarget(oldShot, ...) end if type(oldPreview) == "function" then function AimRay.preview(...) return aimAtTarget(oldPreview, ...) end end end