--!nocheck --!native --!optimize 2 -- Silent aim for the gun game - reroute only. -- -- The game shoots entirely on the client: WeaponActionController.CastBulletRay() takes the -- origin off Camera.CFrame, adds the weapon's spread, and hands (origin, dir, maxDist, -- {Character, Camera}) to ComponentsManager.Player.BulletRayCast. Whatever that returns is -- what the client reports through GameEvents.Hit and GameEvents.Damage. -- -- So the whole silent aim is one replacement of that direction: when the ray belongs to our -- own shot, point it at the chosen body part instead. The camera is never touched, the input -- path is never touched, the fire rate is never touched - the round simply leaves the muzzle -- in the target's direction and arrives there. Hitscan, so there is no travel time to lead. -- -- Every branch is pcall-guarded: if anything here fails, the game's own raycast runs with the -- game's own arguments, so a shot can never be blocked by this script. -- -- Menu key: RightAlt. Toggle key: X. local Players = game:GetService("Players") local RunService = game:GetService("RunService") local CollectionService = game:GetService("CollectionService") local ReplicatedStorage = game:GetService("ReplicatedStorage") local VirtualInputManager = game:GetService("VirtualInputManager") local HttpService = game:GetService("HttpService") local LP = Players.LocalPlayer local Camera = workspace.CurrentCamera do local old = getgenv().__GunSilentAim if old and old.unload then pcall(old.unload) end end local CONFIG = { enabled = true, fov = 20, maxDistance = 600, part = "auto", -- "auto" | "head" | "torso" teamCheck = true, visibleOnly = true, -- only reroute when the shot can actually reach them throughWalls = false, -- ignore cover: the round is reported on the target regardless stickiness = 3, -- degrees of slack for the target already held knife = true, autoFire = false, -- synthetic left click, off by default autoDelay = 0.05, } local VIS = { enabled = true, box = true, fill = false, fillAlpha = 0.35, name = true, distance = true, health = true, dot = true, snapline = false, fovCircle = true, teammates = false, maxDistance = 600, textSize = 12, chams = false, chamsVisibleColor = Color3.fromRGB(0, 255, 0), chamsHiddenColor = Color3.fromRGB(255, 0, 0), chamsTeammates = false, chamsBackupVischeck = true, -- CPU line test decides green/red when the engine depth test fails enemyColor = Color3.fromRGB(255, 70, 70), teamColor = Color3.fromRGB(80, 170, 255), aimColor = Color3.fromRGB(0, 210, 190), textColor = Color3.fromRGB(238, 242, 246), glow = true, glowTeammates = false, glowThroughWalls = true, glowAlpha = 0.15, glowEnemyColor = Color3.fromRGB(255, 40, 40), glowTeamColor = Color3.fromRGB(60, 160, 255), tracers = true, tracerColor = Color3.fromRGB(140, 200, 255), tracerLife = 0.22, tracerThickness = 0.07, marker = true, markerColor = Color3.fromRGB(255, 255, 255), markerSize = 22, markerLife = 0.35, } local STATE = { steered = 0, rays = 0, attempts = 0, blocked = 0, noTarget = 0, target = nil, targetAt = 0, lastRedirect = nil, lastBlocked = nil, lastSeen = nil, errors = 0, lastError = nil, closed = false, ready = false } -- ------------------------------------------------------------------ wait for the weapon system -- The lobby place has no weapon modules at all: wait instead of failing, and say so once. local ComponentsManager, PlayerComponent, GameEvents, HitRemote, DamageRemote do local deadline = os.clock() + 120 while os.clock() < deadline and not (ComponentsManager and GameEvents) do ComponentsManager = ComponentsManager or ReplicatedStorage:FindFirstChild("ComponentsManager") GameEvents = GameEvents or ReplicatedStorage:FindFirstChild("GameEvents") if not (ComponentsManager and GameEvents) then task.wait(1) ReplicatedStorage:GetChildren() end end if ComponentsManager then local ok, module = pcall(require, ComponentsManager) if ok and type(module) == "table" then PlayerComponent = module.Player end end if GameEvents then HitRemote = GameEvents:FindFirstChild("Hit") DamageRemote = GameEvents:FindFirstChild("Damage") end end if not (PlayerComponent and HitRemote and DamageRemote) then warn("[aim] weapon system not in this place yet - hooks skipped") end -- ------------------------------------------------------------------ targets local function tagKind(part) if CollectionService:HasTag(part, "PlayerHead") then return "head" end if CollectionService:HasTag(part, "PlayerTorso") then return "torso" end return "limb" end local function characterOf(part) local model = part while model do model = model:FindFirstAncestorOfClass("Model") if not model then return nil end if model:FindFirstChildOfClass("Humanoid") then return model end end return nil end -- Only real player characters. That one test drops the killcam/spectate clones -- (ReplayPrefabs / ReplayActors / *_ReplayClone) and the camera view model, none of which -- are Players, and it keeps bots out of the way of a PvP round. local function isTarget(model) if not model or model == LP.Character then return false end local player = Players:GetPlayerFromCharacter(model) if not player then return false end if player == LP then return false end if CONFIG.teamCheck and player.Team ~= nil and LP.Team ~= nil and player.Team == LP.Team then return false end local humanoid = model:FindFirstChildOfClass("Humanoid") return humanoid ~= nil and humanoid.Health > 0 end local function findTarget(origin, look) if typeof(origin) ~= "Vector3" or typeof(look) ~= "Vector3" then return nil end local best for _, part in ipairs(CollectionService:GetTagged("PlayerHitRegistration")) do if part:IsA("BasePart") and part.Parent then local model = characterOf(part) if isTarget(model) then local kind = tagKind(part) if CONFIG.part == "auto" or CONFIG.part == kind then local delta = part.Position - origin local distance = delta.Magnitude if distance > 0.5 and distance <= CONFIG.maxDistance then local angle = math.deg(math.acos(math.clamp(look.Unit:Dot(delta.Unit), -1, 1))) if angle <= CONFIG.fov then local score = angle if CONFIG.part == "auto" and kind == "head" then score = score - 0.5 end if STATE.target and STATE.target.model == model then score = score - CONFIG.stickiness end if not best or score < best.score then best = { model = model, part = part, kind = kind, point = part.Position, angle = angle, distance = distance, score = score } end end end end end end end if best then STATE.target = best STATE.targetAt = os.clock() elseif STATE.target and os.clock() - STATE.targetAt > 0.5 then STATE.target = nil end return best end -- ------------------------------------------------------------------ esp local function guiHost() local ok, hui = pcall(gethui) if ok and typeof(hui) == "Instance" then return hui end return game:GetService("CoreGui") end local espGui = Instance.new("ScreenGui") espGui.Name = "SilentAimESP" espGui.IgnoreGuiInset = true espGui.ResetOnSpawn = false espGui.DisplayOrder = 2147483000 espGui.Parent = guiHost() pcall(function() if protectgui then protectgui(espGui) end end) local espLayer = Instance.new("Frame") espLayer.BackgroundTransparency = 1 espLayer.Size = UDim2.fromScale(1, 1) espLayer.BorderSizePixel = 0 espLayer.Parent = espGui local ringHolder = Instance.new("Frame") ringHolder.Name = "FovRing" ringHolder.BackgroundTransparency = 1 ringHolder.AnchorPoint = Vector2.new(0.5, 0.5) ringHolder.Position = UDim2.fromScale(0.5, 0.5) ringHolder.BorderSizePixel = 0 ringHolder.Parent = espLayer local ring = Instance.new("Frame") ring.BackgroundTransparency = 1 ring.Size = UDim2.fromScale(1, 1) ring.BorderSizePixel = 0 ring.Parent = ringHolder local ringCorner = Instance.new("UICorner") ringCorner.CornerRadius = UDim.new(1, 0) ringCorner.Parent = ring local ringStroke = Instance.new("UIStroke") ringStroke.Color = Color3.fromRGB(255, 255, 255) ringStroke.Thickness = 1 ringStroke.Transparency = 0.35 ringStroke.Parent = ring local function newFrame(parent, colour) local frame = Instance.new("Frame") frame.BackgroundColor3 = colour or Color3.new(1, 1, 1) frame.BorderSizePixel = 0 frame.Visible = false frame.Parent = parent return frame end local function newLabel(parent, size) local label = Instance.new("TextLabel") label.BackgroundTransparency = 1 label.Font = Enum.Font.SourceSansSemibold label.TextSize = size or VIS.textSize label.TextColor3 = VIS.textColor label.TextStrokeTransparency = 0.4 label.TextStrokeColor3 = Color3.new(0, 0, 0) label.TextXAlignment = Enum.TextXAlignment.Center label.Visible = false label.Parent = parent return label end local function newState() local state = {} state.holder = Instance.new("Frame") state.holder.Name = "Target" state.holder.BackgroundTransparency = 1 state.holder.BorderSizePixel = 0 state.holder.Visible = false state.holder.Parent = espLayer state.fill = newFrame(state.holder, VIS.enemyColor) state.edges = { newFrame(state.holder, VIS.enemyColor), newFrame(state.holder, VIS.enemyColor), newFrame(state.holder, VIS.enemyColor), newFrame(state.holder, VIS.enemyColor) } state.snap = newFrame(state.holder, VIS.enemyColor) state.hbBg = newFrame(state.holder, Color3.fromRGB(10, 10, 10)) state.hbFill = newFrame(state.holder) state.dot = newFrame(state.holder, VIS.enemyColor) local dotCorner = Instance.new("UICorner") dotCorner.CornerRadius = UDim.new(1, 0) dotCorner.Parent = state.dot state.name = newLabel(state.holder) state.name.Name = "Name" state.dist = newLabel(state.holder) state.dist.Name = "Distance" state.dot.Name = "HeadDot" return state end local espPool = {} local espShown = {} local function colourFor(player) if player and player.TeamColor then return player.TeamColor.Color end return VIS.enemyColor end local function hideState(state) state.holder.Visible = false for _, edge in ipairs(state.edges) do edge.Visible = false end state.fill.Visible = false state.hbBg.Visible = false state.hbFill.Visible = false state.dot.Visible = false state.name.Visible = false state.dist.Visible = false state.snap.Visible = false end local function project(point) local screen, onScreen = Camera:WorldToViewportPoint(point) return Vector2.new(screen.X, screen.Y), onScreen, screen.Z end local function boxFor(model) local ok, cf, size = pcall(function() return model:GetBoundingBox() end) if not ok or not cf or not size then return nil end local half = size * 0.5 local minX, minY, maxX, maxY local anyFront for _, corner in ipairs({ Vector3.new(-half.X, -half.Y, -half.Z), Vector3.new(half.X, -half.Y, -half.Z), Vector3.new(-half.X, half.Y, -half.Z), Vector3.new(half.X, half.Y, -half.Z), Vector3.new(-half.X, -half.Y, half.Z), Vector3.new(half.X, -half.Y, half.Z), Vector3.new(-half.X, half.Y, half.Z), Vector3.new(half.X, half.Y, half.Z), }) do local world = cf * corner local screen, onScreen, depth = project(world) if depth > 0 then anyFront = true minX = minX and math.min(minX, screen.X) or screen.X maxX = maxX and math.max(maxX, screen.X) or screen.X minY = minY and math.min(minY, screen.Y) or screen.Y maxY = maxY and math.max(maxY, screen.Y) or screen.Y end end if not anyFront or not minX then return nil end return minX, minY, maxX, maxY end local espAccum = 0 local function renderEsp() if not VIS.enabled then if #espShown > 0 then for _, model in ipairs(espShown) do local state = espPool[model] if state then hideState(state) end end table.clear(espShown) end ringHolder.Visible = false return end -- the aim cone, drawn where the aim actually measures it if VIS.fovCircle then local viewport = Camera.ViewportSize local half = (viewport.Y * 0.5) * math.tan(math.rad(CONFIG.fov * 0.5)) / math.tan(math.rad(Camera.FieldOfView * 0.5)) local size = math.max(4, math.floor(half * 2)) ringHolder.Size = UDim2.fromOffset(size, size) ringHolder.Visible = true else ringHolder.Visible = false end table.clear(espShown) for _, part in ipairs(CollectionService:GetTagged("PlayerHitRegistration")) do if part:IsA("BasePart") and part.Parent then local model = characterOf(part) local player = model and Players:GetPlayerFromCharacter(model) if player and model ~= LP.Character and not espShown[model] then local humanoid = model:FindFirstChildOfClass("Humanoid") local sameTeam = player.Team == LP.Team if humanoid and humanoid.Health > 0 and (VIS.teammates or not sameTeam) then local minX, minY, maxX, maxY = boxFor(model) if minX then espShown[#espShown + 1] = model if espShown[model] == nil then espShown[model] = true end local state = espPool[model] if not state then state = newState() espPool[model] = state end local colour = sameTeam and VIS.teamColor or colourFor(player) if STATE.target and STATE.target.model == model then colour = VIS.aimColor end local width = math.max(1, maxX - minX) local height = math.max(1, maxY - minY) state.holder.Visible = true if VIS.box then local thickness = 1 state.edges[1].Visible = true state.edges[1].Size = UDim2.fromOffset(width, thickness) state.edges[1].Position = UDim2.fromOffset(minX, minY) state.edges[2].Visible = true state.edges[2].Size = UDim2.fromOffset(width, thickness) state.edges[2].Position = UDim2.fromOffset(minX, maxY - thickness) state.edges[3].Visible = true state.edges[3].Size = UDim2.fromOffset(thickness, height) state.edges[3].Position = UDim2.fromOffset(minX, minY) state.edges[4].Visible = true state.edges[4].Size = UDim2.fromOffset(thickness, height) state.edges[4].Position = UDim2.fromOffset(maxX - thickness, minY) for _, edge in ipairs(state.edges) do edge.BackgroundColor3 = colour end else for _, edge in ipairs(state.edges) do edge.Visible = false end end if VIS.fill then state.fill.Visible = true state.fill.BackgroundColor3 = colour state.fill.BackgroundTransparency = 1 - VIS.fillAlpha state.fill.Size = UDim2.fromOffset(width, height) state.fill.Position = UDim2.fromOffset(minX, minY) else state.fill.Visible = false end if VIS.health and humanoid.MaxHealth > 0 then local fraction = math.clamp(humanoid.Health / humanoid.MaxHealth, 0, 1) state.hbBg.Visible = true state.hbBg.Position = UDim2.fromOffset(minX - 5, minY) state.hbBg.Size = UDim2.fromOffset(3, height) state.hbFill.Visible = true state.hbFill.BackgroundColor3 = Color3.fromRGB(60 + 195 * (1 - fraction), 60 + 195 * fraction, 60) state.hbFill.Size = UDim2.fromOffset(3, math.max(1, height * fraction)) state.hbFill.Position = UDim2.fromOffset(minX - 5, minY + (height * (1 - fraction))) else state.hbBg.Visible = false state.hbFill.Visible = false end if VIS.dot then local head = model:FindFirstChild("Head") local point = head and head.Position or (model:GetPivot().Position + Vector3.new(0, height, 0)) local screen, _, depth = project(point) if depth > 0 then state.dot.Visible = true state.dot.BackgroundColor3 = colour state.dot.Size = UDim2.fromOffset(4, 4) state.dot.Position = UDim2.fromOffset(screen.X - 2, screen.Y - 2) else state.dot.Visible = false end else state.dot.Visible = false end if VIS.snapline then local viewport = Camera.ViewportSize local toX = (minX + maxX) * 0.5 state.snap.Visible = true state.snap.BackgroundColor3 = colour state.snap.Size = UDim2.fromOffset(math.max(1, Vector2.new(toX - viewport.X * 0.5, maxY - viewport.Y).Magnitude), 1) state.snap.AnchorPoint = Vector2.new(0, 0.5) state.snap.Position = UDim2.fromOffset(viewport.X * 0.5, viewport.Y) state.snap.Rotation = math.deg(math.atan2(maxY - viewport.Y, toX - viewport.X * 0.5)) else state.snap.Visible = false end local root = model:FindFirstChild("HumanoidRootPart") local distance = root and (root.Position - Camera.CFrame.Position).Magnitude or 0 if VIS.name then state.name.Visible = true state.name.Text = player.DisplayName state.name.TextColor3 = VIS.textColor state.name.TextSize = VIS.textSize state.name.Position = UDim2.fromOffset(minX - 40, minY - 30) state.name.Size = UDim2.fromOffset(width + 80, 14) else state.name.Visible = false end if VIS.distance then state.dist.Visible = true state.dist.Text = string.format("%d studs", math.floor(distance + 0.5)) state.dist.TextColor3 = VIS.textColor state.dist.TextSize = VIS.textSize state.dist.Position = UDim2.fromOffset(minX - 40, minY - 16) state.dist.Size = UDim2.fromOffset(width + 80, 14) else state.dist.Visible = false end end end end end end for model, state in pairs(espPool) do if not espShown[model] then hideState(state) end if not model.Parent or not Players:GetPlayerFromCharacter(model) then state.holder:Destroy() espPool[model] = nil end end end local espConnection = RunService.RenderStepped:Connect(function() if STATE.closed then return end local ok, err = pcall(renderEsp) if not ok then STATE.errors += 1 STATE.lastError = "esp: " .. tostring(err) end end) -- ------------------------------------------------------------------ vischeck chams -- -- Tag driven: anything tagged "Chams" (Model with a Humanoid, or a BasePart) gets two -- Highlights and, when it needs one, a welded copy of its geometry. -- -- Green DepthMode=Occluded the VISIBLE colour, only where the geometry passes the depth test -- Red DepthMode=AlwaysOnTop the HIDDEN colour, the whole silhouette -- Green has to be composited after red, so it wins wherever the target is actually visible. -- -- Engine behaviour this relies on (measured in Studio 0.743): -- * A part renders at most one Highlight, so the two colours need two copies of the geometry. -- * Highlights on models that contain a Humanoid are composited after highlights on plain models, -- regardless of distance. Plain models are sorted by nearest part centre, which interleaves -- self-overlapping parts, so "Humanoid model last" is the only ordering that holds everywhere. -- * Highlights skip parts with Transparency > 0.01. -- -- The second copy ("ghost") is a set of opaque clones WELDED to the target's parts, so the engine -- moves and animates it with the target. Both silhouettes are exact on every frame: no per-frame -- CFrame writes, update thresholds or tracking error. -- -- Characters (Model with a Humanoid): -- green on the character itself; red on a plain ghost shrunk by `gap` per side, which keeps the -- real surface strictly in front of it, so the green depth test never z-fights with it. -- Everything else: -- red on the target itself; green on a ghost inflated by `gap` per side (strictly in front of -- the real surface) that carries an inert Humanoid, so green is composited last. -- -- gap = GAP_PER_STUD * camera distance, re-applied only when that distance doubles or halves: about -- 10x the measured depth-precision limit, while moving any outline by < 0.1 px. -- -- Per frame: one bounding-sphere frustum test per target. Off-screen targets put their ghost to -- sleep (anchored, welds disabled) so it costs nothing in physics either. local Chams = (function() local TAG = "Chams" local GAP_PER_STUD = 1e-4 -- ghost inset/outset per stud of camera distance local MIN_GAP = 1e-4 local GAP_RESCALE = 2 -- re-apply the gap once the camera distance has changed by this factor local OPAQUE_MAX = 0.01 -- Highlights only render parts at or below this Transparency -- Skinned meshes (dynamic heads) render deformed past their bind pose by a few thousandths of a -- stud; the bone-less ghost clone renders the bind pose, so it needs more clearance. local SKINNED_GAP_SCALE = 4 local MIN_SIZE = 0.001 -- smallest Size Roblox accepts local CULL_RADIUS_SCALE = 1.5 -- slack on the build-pose bounding sphere for animation reach local CULL_MARGIN = 2 -- studs local SLEEP_HYSTERESIS = 2 -- an awake ghost sleeps only once outside this multiple of the sphere -- the two colours are settings rather than constants: changing them repaints the live highlights local colors = { visible = VIS.chamsVisibleColor, hidden = VIS.chamsHiddenColor } local camera = workspace.CurrentCamera local localPlayer = LP -- Welds only run in the physics world, so ghosts live in Workspace rather than under the Camera. local ghostRoot = Instance.new("Folder") ghostRoot.Name = "ChamsGhosts" ghostRoot.Parent = workspace local cameraConn = workspace:GetPropertyChangedSignal("CurrentCamera"):Connect(function() camera = workspace.CurrentCamera end) type Entry = { target: Instance, character: boolean, -- true: green on target, red on shrunk ghost; false: the reverse ghost: Model, red: Highlight, green: Highlight, root: BasePart?, -- camera-distance and culling reference radius: number, -- culling sphere around root awake: boolean, -- ghost welded (true) or anchored and detached (false) src: { BasePart }, dst: { BasePart }, welds: { Weld }, baseSize: { Vector3 }, gapScale: { number }, fileMeshes: { SpecialMesh | false }, baseMeshScale: { Vector3 }, gapDist: number, visible: boolean?, -- CPU line-of-sight verdict, gates the green pass dirty: boolean, conns: { RBXScriptConnection }, -- lifetime of the entry partConns: { RBXScriptConnection }, -- lifetime of the current ghost build } local entries: { [Instance]: Entry } = {} local list: { Entry } = {} local function makeHighlight(adornee: Instance, depthMode: Enum.HighlightDepthMode, color: Color3): Highlight local h = Instance.new("Highlight") h.Adornee = adornee h.DepthMode = depthMode h.FillColor = color h.FillTransparency = 0 h.OutlineTransparency = 1 h.Parent = ghostRoot return h end local function applyGap(e: Entry, dist: number) local gap = math.max(MIN_GAP, dist * GAP_PER_STUD) local sign = if e.character then -2 else 2 local minSize = Vector3.one * MIN_SIZE for i, g in e.dst do local base = e.baseSize[i] local size = (base + Vector3.one * (sign * gap * e.gapScale[i])):Max(minSize) g.Size = size local mesh = e.fileMeshes[i] if mesh then -- FileMesh scale is absolute; scale it by the same ratio as the part box. mesh.Scale = e.baseMeshScale[i] * size / base end end e.gapDist = dist end local function rebuild(e: Entry, camPos: Vector3) e.dirty = false for _, c in e.partConns do c:Disconnect() end table.clear(e.partConns) for _, c in e.ghost:GetChildren() do if c:IsA("BasePart") then c:Destroy() end end table.clear(e.src) table.clear(e.dst) table.clear(e.welds) table.clear(e.baseSize) table.clear(e.gapScale) table.clear(e.fileMeshes) table.clear(e.baseMeshScale) local target = e.target local function markDirty() e.dirty = true end local candidates = if target:IsA("BasePart") then { target } else target:GetDescendants() for _, d in candidates do if not d:IsA("BasePart") then continue end -- Either can change which parts the highlights cover. table.insert(e.partConns, d:GetPropertyChangedSignal("Transparency"):Connect(markDirty)) table.insert(e.partConns, d:GetPropertyChangedSignal("Size"):Connect(markDirty)) if d.Transparency > OPAQUE_MAX then continue end local archivable = d.Archivable d.Archivable = true local g = d:Clone() d.Archivable = archivable local fileMesh: SpecialMesh | false = false for _, child in g:GetChildren() do if child:IsA("DataModelMesh") then if child:IsA("SpecialMesh") and child.MeshType == Enum.MeshType.FileMesh then fileMesh = child end else child:Destroy() -- joints, attachments, decals, scripts, wraps end end for _, tag in g:GetTags() do g:RemoveTag(tag) -- Clone copies tags; a tagged ghost would get its own ghost end g.Anchored = false g.Massless = true g.CanCollide = false g.CanQuery = false g.CanTouch = false g.CastShadow = false g.Transparency = 0 g.CFrame = d.CFrame local w = Instance.new("Weld") w.Part0 = d w.Part1 = g w.Parent = g g.Parent = e.ghost table.insert(e.src, d) table.insert(e.dst, g) table.insert(e.welds, w) table.insert(e.baseSize, d.Size) table.insert(e.gapScale, if d:IsA("MeshPart") and d.HasSkinnedMesh then SKINNED_GAP_SCALE else 1) table.insert(e.fileMeshes, fileMesh) table.insert(e.baseMeshScale, if fileMesh then fileMesh.Scale else Vector3.one) end local root: BasePart? = nil if target:IsA("Model") then root = target.PrimaryPart or target:FindFirstChild("HumanoidRootPart") :: BasePart? end if not root then root = if target:IsA("BasePart") then target else target:FindFirstChildWhichIsA("BasePart", true) end e.root = root local radius = 0 if root then local rootPos = root.Position for _, part in e.src do radius = math.max(radius, (part.Position - rootPos).Magnitude + part.Size.Magnitude * 0.5) end end e.radius = radius * CULL_RADIUS_SCALE + CULL_MARGIN e.visible = nil e.awake = true applyGap(e, if root then (root.Position - camPos).Magnitude else 0) end local function remove(target: Instance) local e = entries[target] if not e then return end entries[target] = nil local i = table.find(list, e) if i then list[i] = list[#list] list[#list] = nil end for _, c in e.conns do c:Disconnect() end for _, c in e.partConns do c:Disconnect() end e.red:Destroy() e.green:Destroy() e.ghost:Destroy() end local function add(target: Instance) if entries[target] or not (target:IsA("Model") or target:IsA("BasePart")) then return end if target == LP.Character or not target:IsDescendantOf(workspace) then return end local character = target:IsA("Model") and target:FindFirstChildOfClass("Humanoid") ~= nil local ghost = Instance.new("Model") ghost.Name = target.Name .. "_ChamsGhost" if not character then -- Inert: only here so the green highlight is composited with the "Humanoid model" group. local h = Instance.new("Humanoid") h.EvaluateStateMachine = false h.RequiresNeck = false h.BreakJointsOnDeath = false h.DisplayDistanceType = Enum.HumanoidDisplayDistanceType.None h.HealthDisplayType = Enum.HumanoidHealthDisplayType.AlwaysOff h.Parent = ghost end ghost.Parent = ghostRoot local e: Entry = { target = target, character = character, ghost = ghost, red = makeHighlight(if character then ghost else target, Enum.HighlightDepthMode.AlwaysOnTop, colors.hidden), green = makeHighlight(if character then target else ghost, Enum.HighlightDepthMode.Occluded, colors.visible), root = nil, radius = 0, awake = true, src = {}, dst = {}, welds = {}, baseSize = {}, gapScale = {}, fileMeshes = {}, baseMeshScale = {}, gapDist = 0, dirty = false, conns = {}, partConns = {}, } if target:IsA("Model") then local function onDescendant(d: Instance) if d:IsA("BasePart") then e.dirty = true -- coalesces accessory/tool/limb churn into one rebuild per frame end end table.insert(e.conns, target.DescendantAdded:Connect(onDescendant)) table.insert(e.conns, target.DescendantRemoving:Connect(onDescendant)) end table.insert(e.conns, target.AncestryChanged:Connect(function() if not target:IsDescendantOf(workspace) then remove(target) end end)) entries[target] = e table.insert(list, e) rebuild(e, if camera then camera.CFrame.Position else Vector3.zero) end local addedSignal = CollectionService:GetInstanceAddedSignal(TAG):Connect(add) local removedSignal = CollectionService:GetInstanceRemovedSignal(TAG):Connect(remove) for _, inst in CollectionService:GetTagged(TAG) do add(inst) end -- Off-screen targets: ghost parts are anchored and their welds disabled, which removes them from -- the physics step (~1 us per welded part per frame). Their highlights are off-screen, so a stale -- ghost is never drawn. local function sleep(e: Entry) e.awake = false for i, g in e.dst do e.welds[i].Enabled = false g.Anchored = true end end local wakeEntries: { Entry } = {} local wakeParts: { BasePart } = {} local wakeCFrames: { CFrame } = {} -- The green pass is meant to be depth tested, but that is not reliable on every client: on -- some builds an Occluded highlight composites like AlwaysOnTop and the whole silhouette reads -- green, even behind a wall. So the depth test is backed by a CPU one: a couple of rays from the -- camera to the target, and the green pass is switched off whenever nothing of them is reachable. -- Red is never gated, so a target behind cover still shows its silhouette. local visParams = RaycastParams.new() visParams.FilterType = Enum.RaycastFilterType.Exclude local function lineClear(from: Vector3, to: Vector3): boolean local delta = to - from if delta.Magnitude < 0.2 then return true end return workspace:Raycast(from, delta, visParams) == nil end local function updateVisibility(camPos: Vector3) if not VIS.chamsBackupVischeck then -- the engine's own depth pass is trusted: green everywhere it passes, red through walls for _, e in list do if e.green.Enabled == false then e.green.Enabled = true e.visible = nil end end return end local ignored = { localPlayer.Character, camera } for _, e in list do local root = e.root if not root then continue end ignored[#ignored + 1] = e.target visParams.FilterDescendantsInstances = ignored local head = if e.target:IsA("Model") then e.target:FindFirstChild("Head") else nil local visible = lineClear(camPos, root.Position) or (head ~= nil and lineClear(camPos, head.Position)) ignored[#ignored] = nil if e.visible ~= visible then e.visible = visible e.green.Enabled = visible end end end local function step() local cam = camera if not cam then return end debug.profilebegin("VischeckChams") local camCF = cam.CFrame local camPos = camCF.Position local look, right, up = camCF.LookVector, camCF.RightVector, camCF.UpVector local vp = cam.ViewportSize local tanY = math.tan(math.rad(cam.FieldOfView) * 0.5) local tanX = tanY * vp.X / vp.Y local secX = math.sqrt(1 + tanX * tanX) local secY = math.sqrt(1 + tanY * tanY) local n = 0 for _, e in list do if e.dirty then rebuild(e, camPos) end local root = e.root if not root then continue end local rel = root.Position - camPos local z = rel:Dot(look) -- Wake at the culling sphere; stay awake until well past it, so targets near the screen -- edge don't toggle every frame. local r = if e.awake then e.radius * SLEEP_HYSTERESIS else e.radius local onScreen = z >= -r and math.abs(rel:Dot(right)) <= z * tanX + r * secX and math.abs(rel:Dot(up)) <= z * tanY + r * secY if not onScreen then if e.awake then sleep(e) end continue end if not e.awake then -- Welds only solve in the next physics step, so place the still-anchored ghost exactly -- for this frame first (moving it after re-welding would drag the target's assembly). e.awake = true table.insert(wakeEntries, e) local src = e.src for i, g in e.dst do n += 1 wakeParts[n] = g wakeCFrames[n] = src[i].CFrame end end local dist = rel.Magnitude if dist > e.gapDist * GAP_RESCALE or dist * GAP_RESCALE < e.gapDist then applyGap(e, dist) end end if wakeEntries[1] then workspace:BulkMoveTo(wakeParts, wakeCFrames, Enum.BulkMoveMode.FireCFrameChanged) for _, e in wakeEntries do for i, g in e.dst do g.Anchored = false e.welds[i].Enabled = true end end table.clear(wakeEntries) table.clear(wakeParts) table.clear(wakeCFrames) end debug.profileend() end local api = {} function api.count() return #list end -- what each live entry is actually made of: which highlight adorns what, in which colour and -- depth mode, and how many parts the ghost carries -- called from the main script's render connection on its own cadence, so the gate does not -- depend on BindToRenderStep being honoured by the executor function api.tickVisibility() updateVisibility(if camera then camera.CFrame.Position else Vector3.zero) return #list end function api.dump() local out = {} for _, e in list do local function describe(h: Highlight) local c = h.FillColor return string.format("%s depth=%s adornee=%s colour=%d,%d,%d", h.Name ~= "" and h.Name or "highlight", string.gsub(tostring(h.DepthMode), "Enum.HighlightDepthMode.", ""), h.Adornee and h.Adornee.Name or "nil", math.floor(c.R * 255 + 0.5), math.floor(c.G * 255 + 0.5), math.floor(c.B * 255 + 0.5)) end out[#out + 1] = { target = e.target.Name, character = e.character, parts = #e.dst, asleep = not e.awake, visible = e.visible, greenEnabled = e.green.Enabled, green = describe(e.green), red = describe(e.red), greenAdorneeHumanoid = e.green.Adornee ~= nil and e.green.Adornee:FindFirstChildOfClass("Humanoid") ~= nil, redAdorneeHumanoid = e.red.Adornee ~= nil and e.red.Adornee:FindFirstChildOfClass("Humanoid") ~= nil, ghostInWorkspace = e.ghost:IsDescendantOf(workspace), ghostParts = (function() local n = 0 for _, c in ipairs(e.ghost:GetChildren()) do if c:IsA("BasePart") then n += 1 end end return n end)(), } end return out, colors.visible, colors.hidden end function api.setColors(visible: Color3, hidden: Color3) colors.visible, colors.hidden = visible, hidden for _, e in list do e.green.FillColor = visible e.red.FillColor = hidden end end -- Binding only while it is on: no frustum test, no highlight and no ghost exists otherwise. function api.setEnabled(on: boolean) if on == api.enabled then return end api.enabled = on if on then RunService:BindToRenderStep("VischeckChams", Enum.RenderPriority.Camera.Value + 1, step) -- tags outlive a disable, so pick up whatever is tagged right now for _, inst in CollectionService:GetTagged(TAG) do add(inst) end else RunService:UnbindFromRenderStep("VischeckChams") for target in pairs(entries) do remove(target) end table.clear(entries) table.clear(list) end end function api.teardown() api.setEnabled(false) addedSignal:Disconnect() removedSignal:Disconnect() cameraConn:Disconnect() ghostRoot:Destroy() end api.enabled = false if VIS.chams then api.setEnabled(true) end return api end)() -- Characters are tagged from the same filter the ESP draws from, so chams and boxes always agree -- about who is in play. local chamsTagged = setmetatable({}, { __mode = "k" }) local function wantsChams(model) if not model or model == LP.Character then return false end local player = Players:GetPlayerFromCharacter(model) if not player then return false end local humanoid = model:FindFirstChildOfClass("Humanoid") if not humanoid or humanoid.Health <= 0 then return false end if player.Team == LP.Team and not VIS.chamsTeammates then return false end local root = model:FindFirstChild("HumanoidRootPart") if root and (root.Position - Camera.CFrame.Position).Magnitude > VIS.maxDistance then return false end return true end -- green is switched off when nothing of a target is reachable, so a target behind cover reads red -- even on clients where an Occluded highlight composites like AlwaysOnTop local visCheckAccum = 0 local visCheckConnection = RunService.RenderStepped:Connect(function(delta) if STATE.closed or not VIS.chams then return end visCheckAccum += delta if visCheckAccum < 0.1 then return end visCheckAccum = 0 local ok, err = pcall(function() Chams.tickVisibility() end) if not ok then STATE.errors += 1 STATE.lastError = "vischeck: " .. tostring(err) end end) local function syncChamsTags() if VIS.chams then local wanted = {} for _, part in ipairs(CollectionService:GetTagged("PlayerHitRegistration")) do local model = characterOf(part) if model and not wanted[model] and wantsChams(model) then wanted[model] = true end end for model in pairs(wanted) do if not chamsTagged[model] then CollectionService:AddTag(model, "Chams") chamsTagged[model] = true end end for model in pairs(chamsTagged) do if not wanted[model] or not model.Parent then pcall(function() CollectionService:RemoveTag(model, "Chams") end) chamsTagged[model] = nil end end elseif next(chamsTagged) then for model in pairs(chamsTagged) do pcall(function() CollectionService:RemoveTag(model, "Chams") end) chamsTagged[model] = nil end end end task.spawn(function() while not STATE.closed do local ok, err = pcall(syncChamsTags) if not ok then STATE.errors += 1 STATE.lastError = "chams: " .. tostring(err) end task.wait(0.5) end end) -- ------------------------------------------------------------------ glow chams -- One Highlight per character, outline off so only the fill shows: the body reads as a -- solid glow instead of an outline. Team toggle decides whether own team is painted too. local glowPool = {} local glowAccum = 0 local glowConnection = RunService.RenderStepped:Connect(function(delta) if STATE.closed then return end glowAccum += delta if glowAccum < 0.1 then return end glowAccum = 0 local active = {} if VIS.glow and not VIS.chams then for _, part in ipairs(CollectionService:GetTagged("PlayerHitRegistration")) do local model = characterOf(part) if model and not active[model] and model ~= LP.Character then local player = Players:GetPlayerFromCharacter(model) local humanoid = model:FindFirstChildOfClass("Humanoid") local root = model:FindFirstChild("HumanoidRootPart") if player and humanoid and humanoid.Health > 0 and root then local sameTeam = player.Team == LP.Team if VIS.glowTeammates or not sameTeam then local dist = (root.Position - Camera.CFrame.Position).Magnitude if dist <= VIS.maxDistance then active[model] = true local highlight = glowPool[model] if not highlight then highlight = Instance.new("Highlight") highlight.Name = "GlowChams" highlight.OutlineTransparency = 1 highlight.FillTransparency = VIS.glowAlpha highlight.Parent = espGui glowPool[model] = highlight end highlight.Adornee = model highlight.FillColor = sameTeam and VIS.glowTeamColor or VIS.glowEnemyColor highlight.FillTransparency = VIS.glowAlpha highlight.DepthMode = VIS.glowThroughWalls and Enum.HighlightDepthMode.AlwaysOnTop or Enum.HighlightDepthMode.Occluded highlight.Enabled = true end end end end end end for model, highlight in pairs(glowPool) do if not active[model] then highlight.Enabled = false if not model.Parent then highlight:Destroy() glowPool[model] = nil end end end end) -- ------------------------------------------------------------------ tracers and impact markers local TweenService = game:GetService("TweenService") local tracerPool, tracerIndex = {}, 0 local markerPool, markerIndex = {}, 0 local function spawnTracer(from, to, colour, life, thickness) if typeof(from) ~= "Vector3" or typeof(to) ~= "Vector3" then return end local delta = to - from if delta.Magnitude < 1 then return end tracerIndex = (tracerIndex % 32) + 1 local part = tracerPool[tracerIndex] if not part or not part.Parent then part = Instance.new("Part") part.Name = "AimTracer" part.Anchored = true part.CanCollide = false part.CanQuery = false part.CanTouch = false part.CastShadow = false part.Material = Enum.Material.Neon part.Transparency = 1 part.Size = Vector3.new(0.07, 0.07, 1) part.Parent = workspace tracerPool[tracerIndex] = part end local size = thickness or 0.07 local start = from + delta.Unit * 1.2 local span = to - start part.Size = Vector3.new(size, size, math.max(span.Magnitude, 0.1)) part.CFrame = CFrame.lookAt(start + span * 0.5, to) part.Color = colour or Color3.fromRGB(140, 200, 255) part.Transparency = 0.05 TweenService:Create(part, TweenInfo.new(life or 0.22), { Transparency = 1 }):Play() end local function spawnMarker(position, colour, size, life) if typeof(position) ~= "Vector3" then return end markerIndex = (markerIndex % 24) + 1 local entry = markerPool[markerIndex] if not entry or not entry.part.Parent then local part = Instance.new("Part") part.Name = "AimHitmark" part.Anchored = true part.CanCollide = false part.CanQuery = false part.CanTouch = false part.CastShadow = false part.Transparency = 1 part.Size = Vector3.new(0.2, 0.2, 0.2) part.Parent = workspace local gui = Instance.new("BillboardGui") gui.Name = "Mark" gui.AlwaysOnTop = true gui.LightInfluence = 0 gui.Adornee = part gui.Size = UDim2.fromOffset(22, 22) gui.Parent = part local arms = {} for i = 1, 2 do local arm = Instance.new("Frame") arm.BackgroundColor3 = Color3.new(1, 1, 1) arm.BorderSizePixel = 0 arm.AnchorPoint = Vector2.new(0.5, 0.5) arm.Position = UDim2.fromScale(0.5, 0.5) arm.Size = UDim2.new(0, 2, 0.82, 0) arm.Rotation = i == 1 and 45 or -45 arm.Parent = gui arms[i] = arm end entry = { part = part, gui = gui, arms = arms } markerPool[markerIndex] = entry end local px = size or 22 local dur = life or 0.35 entry.part.Position = position entry.gui.Size = UDim2.fromOffset(px, px) for _, arm in ipairs(entry.arms) do arm.BackgroundColor3 = colour or Color3.new(1, 1, 1) arm.BackgroundTransparency = 0 end TweenService:Create(entry.gui, TweenInfo.new(dur), { Size = UDim2.fromOffset(px * 0.55, px * 0.55), }):Play() for _, arm in ipairs(entry.arms) do TweenService:Create(arm, TweenInfo.new(dur), { BackgroundTransparency = 1 }):Play() end end -- ------------------------------------------------------------------ the reroute local originalBulletRayCast = PlayerComponent and PlayerComponent.BulletRayCast local originalKnifeRayCast = PlayerComponent and PlayerComponent.KnifeRayCast local function isOurShot(origin, filter) local char = LP.Character if not char or typeof(origin) ~= "Vector3" or type(filter) ~= "table" then return false end for _, entry in ipairs(filter) do if entry == char then return true end end return false end -- One ray, the game's own: cast it at the target instead of at the crosshair and look at -- what actually comes back. The module already skips invisible volumes, IgnoreBullet parts -- and breakable glass, so a wall, a barricade or a body in the way all show up here as "the -- ray did not reach them" rather than as a silent miss. local function redirect(original, origin, direction, maxDist, filter) local target = findTarget(origin, direction) if not target then STATE.noTarget += 1 return original(origin, direction, maxDist, filter) end STATE.attempts += 1 STATE.lastSeen = string.format("%s %s %.1f deg", target.model.Name, target.kind, target.angle) local toPart = target.point - origin if toPart.Magnitude < 0.5 then return original(origin, direction, maxDist, filter) end local hit, extra if CONFIG.throughWalls then -- cast against the target alone, so map geometry between us and them is not part of -- the question. The hit that comes back is still a real part of their body, with its -- own damage tags, so the head/torso/limb classification stays the game's. local params = RaycastParams.new() params.FilterType = Enum.RaycastFilterType.Include params.FilterDescendantsInstances = { target.model } local result = workspace:Raycast(origin, toPart.Unit * maxDist, params) if result then hit = { Instance = result.Instance, Position = result.Position, Normal = result.Normal, Material = result.Material, Distance = result.Distance } end else local ok = pcall(function() hit, extra = original(origin, toPart.Unit, maxDist, filter) end) if not ok then STATE.errors += 1 return original(origin, direction, maxDist, filter) end end local reached = hit and hit.Instance and (hit.Instance == target.part or hit.Instance:IsDescendantOf(target.model)) if reached then STATE.steered += 1 STATE.lastRedirect = { at = os.clock(), start = origin, finish = hit.Position } if VIS.tracers then spawnTracer(origin, hit.Position, VIS.tracerColor, VIS.tracerLife, VIS.tracerThickness) end if VIS.marker then spawnMarker(hit.Position, VIS.markerColor, VIS.markerSize, VIS.markerLife) end return hit, extra end -- the line to them is not clear: with "visible only" the shot is left exactly as the -- player aimed it, otherwise it lands wherever the obstruction is STATE.blocked += 1 STATE.lastBlocked = (hit and hit.Instance and hit.Instance:GetFullName()) or "nothing in the way" if CONFIG.visibleOnly and not CONFIG.throughWalls then return original(origin, direction, maxDist, filter) end return hit, extra end local function wrap(original, name) if type(original) ~= "function" then return nil end return function(origin, direction, maxDist, filter) STATE.rays += 1 if not CONFIG.enabled or typeof(direction) ~= "Vector3" or not isOurShot(origin, filter) then return original(origin, direction, maxDist, filter) end local ok, hit, extra = pcall(function() return redirect(original, origin, direction, maxDist, filter) end) if ok then return hit, extra end STATE.errors += 1 STATE.lastError = tostring(hit) return original(origin, direction, maxDist, filter) end end if PlayerComponent then PlayerComponent.BulletRayCast = wrap(originalBulletRayCast, "bullet") if CONFIG.knife then PlayerComponent.KnifeRayCast = wrap(originalKnifeRayCast, "knife") end end -- The caller builds its trace with the pre-reroute direction. The impact it reports is the -- rerouted one, so Direction is rewritten to the line between that trace's own start and -- end. Table writes only - nothing here can disturb the namecall in flight. local originalNamecall local namecallHook if HitRemote and DamageRemote then namecallHook = newcclosure(function(self, ...) if not STATE.closed and STATE.lastRedirect and (self == HitRemote or self == DamageRemote) then local args = table.pack(...) local ok = pcall(function() local trace = args[args.n] if type(trace) == "table" and typeof(trace.StartPosition) == "Vector3" and typeof(trace.EndPosition) == "Vector3" then local finish = STATE.lastRedirect.finish if finish and (trace.EndPosition - finish).Magnitude < 0.5 and os.clock() - STATE.lastRedirect.at < 0.15 then local delta = trace.EndPosition - trace.StartPosition if delta.Magnitude > 0.01 then trace.Direction = delta.Unit end end end end) if not ok then STATE.errors += 1 end end return originalNamecall(self, ...) end) originalNamecall = hookmetamethod(game, "__namecall", namecallHook) end -- ------------------------------------------------------------------ optional auto fire -- Synthetic left click only: no game functions are called and nothing is captured, so the -- trigger can never be broken by this script. The game's own input handler does the firing. task.spawn(function() while not STATE.closed do local interval = math.max(0.01, CONFIG.autoDelay) if CONFIG.enabled and CONFIG.autoFire and LP.Character then pcall(function() if findTarget(Camera.CFrame.Position, Camera.CFrame.LookVector) then VirtualInputManager:SendMouseButtonEvent(0, 0, 0, true, game, 1) task.delay(0.02, function() pcall(function() VirtualInputManager:SendMouseButtonEvent(0, 0, 0, false, game, 1) end) end) end end) end task.wait(interval) end end) -- ------------------------------------------------------------------ config file local CONFIG_FILE = "gun_silent_aim_config.json" local function saveConfig() if type(writefile) ~= "function" then return false, "no filesystem" end local out = {} for key, value in pairs(CONFIG) do if key ~= "enabled" and key ~= "autoFire" and (type(value) == "number" or type(value) == "boolean" or type(value) == "string") then out["c_" .. key] = value end end for key, value in pairs(VIS) do local kind = typeof(value) if kind == "number" or kind == "boolean" or kind == "string" then out["v_" .. key] = value elseif kind == "Color3" then out["v_" .. key] = { __color = true, r = value.R, g = value.G, b = value.B } end end local ok, encoded = pcall(function() return HttpService:JSONEncode(out) end) if not ok then return false, "encode failed" end if pcall(writefile, CONFIG_FILE, encoded) then return true, "saved" end return false, "write failed" end local function loadConfig() if type(readfile) ~= "function" then return false, "no filesystem" end local ok, data = pcall(readfile, CONFIG_FILE) if not ok or type(data) ~= "string" or #data == 0 then return false, "no saved config" end local decoded ok, decoded = pcall(function() return HttpService:JSONDecode(data) end) if not ok or type(decoded) ~= "table" then return false, "corrupt config" end for key, value in pairs(decoded) do local prefix, name = string.sub(key, 1, 1), string.sub(key, 3) local target = prefix == "c" and CONFIG or prefix == "v" and VIS or nil if target and target[name] ~= nil then if typeof(target[name]) == "Color3" and type(value) == "table" and value.__color then target[name] = Color3.new(value.r or 0, value.g or 0, value.b or 0) elseif type(value) == type(target[name]) then target[name] = value end end end CONFIG.fov = math.clamp(CONFIG.fov, 1, 90) return true, "loaded" end loadConfig() -- ------------------------------------------------------------------ menu local Library = loadstring(game:HttpGet("https://pastebin.com/raw/ncKGkPTW"))() Library.Folders = { Directory = "uip100", Configs = "uip100/Configs", Assets = "uip100/Assets" } for _, folder in pairs(Library.Folders) do if not isfolder(folder) then makefolder(folder) end end pcall(function() Library:ChangeTheme("Accent", Color3.fromRGB(0, 190, 180)) end) local Window = Library:Window({ Name = "Silent Aim", Logo = "90829033870443", MobileButtonText = "Aim" }) local Watermark = Library:Watermark("silent aim") local KeybindList = Library:KeybindList() local page = Window:Page({ Name = "Aim", Columns = 2 }) local visPage = Window:Page({ Name = "Visuals", Columns = 2 }) local main = page:Section({ Name = "Silent aim", Side = 1 }) local extra = page:Section({ Name = "Extra", Side = 2 }) local status = page:Section({ Name = "Status", Side = 2 }) local espSide = visPage:Section({ Name = "ESP", Side = 1 }) local colourSide = visPage:Section({ Name = "Colours", Side = 2 }) local chamsPage = Window:Page({ Name = "Chams", Columns = 2 }) local chamsSide = chamsPage:Section({ Name = "Vischeck chams", Side = 1 }) local chamsColourSide = chamsPage:Section({ Name = "Colours", Side = 2 }) local controls = {} local function track(element, get) controls[#controls + 1] = { element = element, get = get } return element end local function refresh() for _, entry in ipairs(controls) do pcall(function() entry.element:Set(entry.get()) end) end end local function partLabel() return string.upper(string.sub(CONFIG.part, 1, 1)) .. string.sub(CONFIG.part, 2) end track(main:Toggle({ Name = "Enabled", Flag = "S_enabled", Default = CONFIG.enabled, Callback = function(value) CONFIG.enabled = value saveConfig() end, }), function() return CONFIG.enabled end):Keybind({ Flag = "K_aim", Default = Enum.KeyCode.X, Mode = "Toggle", }) track(main:Slider({ Name = "FOV", Flag = "S_fov", Min = 1, Max = 90, Decimals = 1, Suffix = " deg", Default = CONFIG.fov, Callback = function(value) CONFIG.fov = value saveConfig() end, }), function() return CONFIG.fov end) track(main:Slider({ Name = "Max distance", Flag = "S_maxDistance", Min = 50, Max = 1000, Decimals = 1, Suffix = " studs", Default = CONFIG.maxDistance, Callback = function(value) CONFIG.maxDistance = value saveConfig() end, }), function() return CONFIG.maxDistance end) track(main:Dropdown({ Name = "Hit part", Flag = "S_part", Items = { "Auto", "Head", "Torso" }, Default = partLabel(), Callback = function(value) CONFIG.part = string.lower(value) saveConfig() end, }), partLabel) track(main:Toggle({ Name = "Team check", Flag = "S_teamCheck", Default = CONFIG.teamCheck, Callback = function(value) CONFIG.teamCheck = value saveConfig() end, }), function() return CONFIG.teamCheck end) track(main:Toggle({ Name = "Require line of sight", Flag = "S_visibleOnly", Default = CONFIG.visibleOnly, Callback = function(value) CONFIG.visibleOnly = value saveConfig() end, }), function() return CONFIG.visibleOnly end) track(main:Toggle({ Name = "Pass through cover", Flag = "S_throughWalls", Default = CONFIG.throughWalls, Callback = function(value) CONFIG.throughWalls = value saveConfig() end, }), function() return CONFIG.throughWalls end) track(main:Toggle({ Name = "Knife too", Flag = "S_knife", Default = CONFIG.knife, Callback = function(value) CONFIG.knife = value saveConfig() end, }), function() return CONFIG.knife end) track(main:Slider({ Name = "Stickiness", Flag = "S_stickiness", Min = 0, Max = 15, Decimals = 0.1, Suffix = " deg", Default = CONFIG.stickiness, Callback = function(value) CONFIG.stickiness = value saveConfig() end, }), function() return CONFIG.stickiness end) track(espSide:Toggle({ Name = "Enable ESP", Flag = "E_enabled", Default = VIS.enabled, Callback = function(value) VIS.enabled = value saveConfig() end, }), function() return VIS.enabled end) local function visToggle(name, flag, key) return track(espSide:Toggle({ Name = name, Flag = flag, Default = VIS[key], Callback = function(value) VIS[key] = value saveConfig() end, }), function() return VIS[key] end) end visToggle("Box", "E_box", "box") visToggle("Filled box", "E_fill", "fill") visToggle("Name", "E_name", "name") visToggle("Distance", "E_distance", "distance") visToggle("Health bar", "E_health", "health") visToggle("Head dot", "E_dot", "dot") visToggle("Snapline", "E_snapline", "snapline") visToggle("FOV circle", "E_fovCircle", "fovCircle") visToggle("Show teammates", "E_teammates", "teammates") track(espSide:Slider({ Name = "Fill opacity", Flag = "E_fillAlpha", Min = 0.05, Max = 1, Decimals = 0.01, Default = VIS.fillAlpha, Callback = function(value) VIS.fillAlpha = value saveConfig() end, }), function() return VIS.fillAlpha end) track(espSide:Slider({ Name = "Max distance", Flag = "E_maxDistance", Min = 50, Max = 2000, Decimals = 1, Suffix = " studs", Default = VIS.maxDistance, Callback = function(value) VIS.maxDistance = value saveConfig() end, }), function() return VIS.maxDistance end) track(espSide:Slider({ Name = "Text size", Flag = "E_textSize", Min = 8, Max = 22, Decimals = 1, Suffix = " px", Default = VIS.textSize, Callback = function(value) VIS.textSize = value saveConfig() end, }), function() return VIS.textSize end) local function colourRow(name, flag, key) return track(colourSide:Label(name):Colorpicker({ Flag = flag, Default = VIS[key], Callback = function(value) VIS[key] = value saveConfig() end, }), function() return VIS[key] end) end colourRow("Enemy", "E_enemyColor", "enemyColor") colourRow("Teammate", "E_teamColor", "teamColor") colourRow("Aim target", "E_aimColor", "aimColor") colourRow("Text", "E_textColor", "textColor") colourSide:Button({ Name = "Save settings", Callback = function() local ok, message = saveConfig() Library:Notification(tostring(message), 4) end }) colourSide:Button({ Name = "Load settings", Callback = function() local ok, message = loadConfig() refresh() Library:Notification(tostring(message), 4) end }) track(chamsSide:Toggle({ Name = "Enable chams", Flag = "H_chams", Default = VIS.chams, Callback = function(value) VIS.chams = value Chams.setEnabled(value) saveConfig() end, }), function() return VIS.chams end) track(chamsSide:Toggle({ Name = "Backup vischeck (red behind walls)", Flag = "H_chamsBackupVischeck", Default = VIS.chamsBackupVischeck, Callback = function(value) VIS.chamsBackupVischeck = value saveConfig() end, }), function() return VIS.chamsBackupVischeck end) track(chamsSide:Toggle({ Name = "Chams on teammates", Flag = "H_chamsTeammates", Default = VIS.chamsTeammates, Callback = function(value) VIS.chamsTeammates = value saveConfig() end, }), function() return VIS.chamsTeammates end) chamsSide:Label("green = visible, red = behind cover") chamsSide:Label("ghosts sleep off screen") track(chamsColourSide:Label("Visible (through nothing)"):Colorpicker({ Flag = "H_chamsVisibleColor", Default = VIS.chamsVisibleColor, Callback = function(value) VIS.chamsVisibleColor = value Chams.setColors(VIS.chamsVisibleColor, VIS.chamsHiddenColor) saveConfig() end, }), function() return VIS.chamsVisibleColor end) track(chamsColourSide:Label("Hidden (behind cover)"):Colorpicker({ Flag = "H_chamsHiddenColor", Default = VIS.chamsHiddenColor, Callback = function(value) VIS.chamsHiddenColor = value Chams.setColors(VIS.chamsVisibleColor, VIS.chamsHiddenColor) saveConfig() end, }), function() return VIS.chamsHiddenColor end) local glowSide = chamsPage:Section({ Name = "Glow chams", Side = 1 }) local fxSide = chamsPage:Section({ Name = "Tracers & impact", Side = 2 }) track(glowSide:Toggle({ Name = "Glow chams", Flag = "G_glow", Default = VIS.glow, Callback = function(value) VIS.glow = value saveConfig() end, }), function() return VIS.glow end) track(glowSide:Toggle({ Name = "Glow teammates", Flag = "G_glowTeam", Default = VIS.glowTeammates, Callback = function(value) VIS.glowTeammates = value saveConfig() end, }), function() return VIS.glowTeammates end) track(glowSide:Toggle({ Name = "Glow through walls", Flag = "G_glowWalls", Default = VIS.glowThroughWalls, Callback = function(value) VIS.glowThroughWalls = value saveConfig() end, }), function() return VIS.glowThroughWalls end) track(glowSide:Slider({ Name = "Glow fade", Flag = "G_glowAlpha", Min = 0, Max = 0.9, Decimals = 0.01, Default = VIS.glowAlpha, Callback = function(value) VIS.glowAlpha = value saveConfig() end, }), function() return VIS.glowAlpha end) track(glowSide:Label("Enemy glow"):Colorpicker({ Flag = "G_glowEnemy", Default = VIS.glowEnemyColor, Callback = function(value) VIS.glowEnemyColor = value saveConfig() end, }), function() return VIS.glowEnemyColor end) track(glowSide:Label("Teammate glow"):Colorpicker({ Flag = "G_glowTeamColor", Default = VIS.glowTeamColor, Callback = function(value) VIS.glowTeamColor = value saveConfig() end, }), function() return VIS.glowTeamColor end) glowSide:Label("team glow is off unless the toggle is on") track(fxSide:Toggle({ Name = "Bullet tracers", Flag = "F_tracers", Default = VIS.tracers, Callback = function(value) VIS.tracers = value saveConfig() end, }), function() return VIS.tracers end) track(fxSide:Label("Tracer colour"):Colorpicker({ Flag = "F_tracerColor", Default = VIS.tracerColor, Callback = function(value) VIS.tracerColor = value saveConfig() end, }), function() return VIS.tracerColor end) track(fxSide:Slider({ Name = "Tracer life", Flag = "F_tracerLife", Min = 0.05, Max = 1, Decimals = 0.001, Suffix = " s", Default = VIS.tracerLife, Callback = function(value) VIS.tracerLife = value saveConfig() end, }), function() return VIS.tracerLife end) track(fxSide:Slider({ Name = "Tracer thickness", Flag = "F_tracerThickness", Min = 0.01, Max = 0.8, Decimals = 0.01, Default = VIS.tracerThickness, Callback = function(value) VIS.tracerThickness = value saveConfig() end, }), function() return VIS.tracerThickness end) track(fxSide:Toggle({ Name = "Impact hitmarker", Flag = "F_marker", Default = VIS.marker, Callback = function(value) VIS.marker = value saveConfig() end, }), function() return VIS.marker end) track(fxSide:Label("Impact colour"):Colorpicker({ Flag = "F_markerColor", Default = VIS.markerColor, Callback = function(value) VIS.markerColor = value saveConfig() end, }), function() return VIS.markerColor end) track(fxSide:Slider({ Name = "Impact size", Flag = "F_markerSize", Min = 8, Max = 48, Decimals = 1, Suffix = " px", Default = VIS.markerSize, Callback = function(value) VIS.markerSize = value saveConfig() end, }), function() return VIS.markerSize end) track(fxSide:Slider({ Name = "Impact life", Flag = "F_markerLife", Min = 0.1, Max = 1.5, Decimals = 0.001, Suffix = " s", Default = VIS.markerLife, Callback = function(value) VIS.markerLife = value saveConfig() end, }), function() return VIS.markerLife end) chamsColourSide:Button({ Name = "Save settings", Callback = function() local ok, message = saveConfig() Library:Notification(tostring(message), 4) end }) chamsColourSide:Button({ Name = "Load settings", Callback = function() local ok, message = loadConfig() refresh() Chams.setEnabled(VIS.chams) Chams.setColors(VIS.chamsVisibleColor, VIS.chamsHiddenColor) Library:Notification(tostring(message), 4) end }) track(extra:Toggle({ Name = "Auto fire (synthetic click)", Flag = "S_autoFire", Default = CONFIG.autoFire, Callback = function(value) CONFIG.autoFire = value saveConfig() end, }), function() return CONFIG.autoFire end) track(extra:Slider({ Name = "Auto fire delay", Flag = "S_autoDelay", Min = 0.01, Max = 0.3, Decimals = 0.01, Suffix = " s", Default = CONFIG.autoDelay, Callback = function(value) CONFIG.autoDelay = value saveConfig() end, }), function() return CONFIG.autoDelay end) extra:Button({ Name = "Save settings", Callback = function() local ok, message = saveConfig() Library:Notification(tostring(message), 4) end }) extra:Button({ Name = "Load settings", Callback = function() local ok, message = loadConfig() refresh() Library:Notification(tostring(message), 4) end }) extra:Button({ Name = "Unload", Callback = function() pcall(unload) end }) local targetLine = status:Label("target -") local rayLine = status:Label("rays 0") local steerLine = status:Label("rerouted 0") local whyLine = status:Label("why -") local espLine = status:Label("esp -") local hookLine = status:Label("hooks -") local errorLine = status:Label("no errors") Library:CreateSettingsPage(Window, KeybindList, Watermark) refresh() task.spawn(function() while not STATE.closed do task.wait(0.3) pcall(function() Watermark:SetText(string.format("silent aim %s fov %.0f %s", CONFIG.enabled and "on" or "off", CONFIG.fov, CONFIG.part)) local target = STATE.target targetLine:SetText(target and string.format("target %s %s %.0f studs %.1f deg", target.model.Name, target.kind, target.distance, target.angle) or "target -") rayLine:SetText(string.format("shot rays %d", STATE.rays)) steerLine:SetText(string.format("rerouted %d of %d aimed", STATE.steered, STATE.attempts)) whyLine:SetText(string.format("no target %d blocked %d %s", STATE.noTarget, STATE.blocked, STATE.blocked > 0 and (STATE.lastBlocked or "") or (STATE.lastSeen or ""))) hookLine:SetText(string.format("hook %s weapons %s", PlayerComponent and PlayerComponent.BulletRayCast ~= originalBulletRayCast and "on" or "off", STATE.ready and "in place" or (PlayerComponent and "waiting" or "not in this place"))) espLine:SetText(string.format("esp %d targets %s chams %d %s", #espShown, VIS.enabled and "on" or "off", Chams.count(), VIS.chams and "on" or "off")) errorLine:SetText(STATE.errors > 0 and string.format("errors %d: %s", STATE.errors, tostring(STATE.lastError)) or "no errors") end) end end) -- ------------------------------------------------------------------ api function unload() if STATE.closed then return end STATE.closed = true CONFIG.enabled = false CONFIG.autoFire = false if PlayerComponent and originalBulletRayCast then PlayerComponent.BulletRayCast = originalBulletRayCast end if PlayerComponent and originalKnifeRayCast then PlayerComponent.KnifeRayCast = originalKnifeRayCast end if namecallHook and getrawmetatable(game).__namecall == namecallHook then hookmetamethod(game, "__namecall", originalNamecall) end if espConnection then pcall(function() espConnection:Disconnect() end) end if visCheckConnection then pcall(function() visCheckConnection:Disconnect() end) end if glowConnection then pcall(function() glowConnection:Disconnect() end) end pcall(function() for model, highlight in pairs(glowPool) do highlight:Destroy() glowPool[model] = nil end end) pcall(function() for _, part in ipairs(tracerPool) do part:Destroy() end table.clear(tracerPool) end) pcall(function() for _, entry in ipairs(markerPool) do entry.part:Destroy() end table.clear(markerPool) end) pcall(function() espGui:Destroy() end) pcall(function() for model in pairs(chamsTagged) do CollectionService:RemoveTag(model, "Chams") end table.clear(chamsTagged) end) pcall(function() Chams.teardown() end) pcall(function() local lib = getgenv().Library if lib and lib.Unload then lib:Unload() end end) if getgenv().__GunSilentAim == api then getgenv().__GunSilentAim = nil end end local api = { CONFIG = CONFIG, VIS = VIS, STATE = STATE, Chams = Chams, findTarget = findTarget, save = saveConfig, load = loadConfig, unload = unload, } getgenv().__GunSilentAim = api STATE.ready = PlayerComponent ~= nil and originalBulletRayCast ~= nil print(string.format("[aim] %s place=%d team=%s fov=%d rays=%d rerouted=%d", STATE.ready and "ready" or "waiting for the weapon system", game.PlaceId, tostring(LP.Team), CONFIG.fov, STATE.rays, STATE.steered)) return api