Open Source Silent aim
Keyless

Open Source Silent aim

TTK TestingVoltaraVoltara 470 views 142 executesUpdated Oct 20, 2026
Unrated
00
Lua Script•107 lines (3732 chars)
--[[‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾

-			SCRIPT NAME		:	TTK_Testing_Silent_Aim.luau
-			AUTHOR			:	.voltara. & _x_hexed_x_
-			DESCRIPTION		:	Basic Silent aim
-           NOTE            :   No ai was used.
-                               <3 don't use it kids it's not good for you.

______________________________________________________________________]]--


if (not game:IsLoaded()) then
    game.Loaded:Wait();
end;

local CheckExist = function(test, name, _type)
    local localPlayer = game:GetService('Players').LocalPlayer;
    if (not localPlayer) then
        return game:Shutdown(); -- what how when where?
    elseif (not test or typeof(test) ~= _type) then
        local executor = if (identifyexecutor) then identifyexecutor() else nil;
        return localPlayer:Kick(`env error getgenv().{name} -> {test}\n{executor and `{executor} is not supported.` or 'current executor is not supported'}`);
    end;
    return; -- shh luau lsp warning
end;

local SafeCloneref = function<T>(instance: T): T?
    return if (instance) then cloneref(instance) else nil;
end;

CheckExist(cloneref, 'cloneref', 'function');

CheckExist(debug, 'debug', 'table'); -- HOW BRO HOW
    CheckExist(debug.getupvalue, 'debug.getupvalue', 'function');
    CheckExist(debug.setupvalue, 'debug.setupvalue', 'function');
    CheckExist(debug.setstack, 'debug.setstack', 'function');
    CheckExist(debug.info, 'debug.info', 'function'); -- what how?

local runService = SafeCloneref(game:GetService('RunService'));
local playerTable = debug.getupvalue(rawget(require(game.ReplicatedStorage.Modules.Client.Character.OperatorPresenter), 'RigOf'), 1); -- TODO: add a check :sob:

local camera = SafeCloneref(workspace.CurrentCamera);
local viewportMid = camera.ViewportSize / 2;
camera:GetPropertyChangedSignal('ViewportSize'):Connect(function()
    viewportMid = camera.ViewportSize / 2;
end);

local WorldToScreen = function(pos: Vector3): (Vector2, boolean, number)
    local point, on = camera:WorldToViewportPoint(pos);
    return Vector2.new(point.X, point.Y), on, point.Z;
end;

local target = nil;
runService.Heartbeat:Connect(function()
    local closest, dist = nil, math.huge;

    for self, data in (playerTable) do
        if (rawget(data, 'dead')) then
            continue;
        end;

        local rig: Model = SafeCloneref(rawget(data, 'rig'));
        if (not rig) then
            continue;
        end;

        local teammate = SafeCloneref(rig:FindFirstChildOfClass('Highlight')); -- jank
        if (teammate) then
            continue;
        end;

        local head: MeshPart = SafeCloneref(rig:FindFirstChild('Head'));
        if (not head) then
            continue;
        end;

        local point, on = WorldToScreen(head.Position);
        if (not on) then
            continue;
        end;

        local mag = (point - viewportMid).Magnitude;
        if (mag >= dist) then
            continue;
        end;

        dist, closest = mag, data;
    end;

    target = closest;
end);

-- TODO: add checks but im lazy.
local randomConeDirection = rawget(require(game.ReplicatedStorage.Modules.Shared.SpreadUtil), 'RandomConeDirection');
local oldRandom: Random = debug.getupvalue(randomConeDirection, 1);

local newRandom = newproxy(true);
rawset(getmetatable(newRandom), '__index', function(_, idx)
    if (debug.info(3, 'n') == 'GetFireDirection' and target) then -- TODO: dose rig and head exist?
        debug.setstack(2, 1, CFrame.lookAt(camera.CFrame.Position, rawget(target, 'rig'):FindFirstChild('Head').Position).LookVector);
    end;

    return function()
        return oldRandom:NextNumber();
    end;
end);
debug.setupvalue(randomConeDirection, 1, newRandom);

Features & Information

silent aim :>

Community Comments (0)

No comments yet for this script.

More Scripts for TTK Testing