Universal Script 📌
1.7k Views
249 Executions

Aimlock script open source

Universal Script 📌
neosnapp
neosnapp10K executions
7 months ago
Get an executor
Please login to perform these actions:

Does it work?

No reports yet

No reports yet. Tried it? Be the first to say.

Also noticed:

Description

C to open lock on locks on to the HumanoidRootPart u can change to Head or Torso or smething like this Used ai fully made by neosnapp.

View Raw
--Used ai fully made by neosnapp
--Pls support me report bugs discord : neo_snap_31882

-- Services
local Players = game:GetService("Players")
local RunService = game:GetService("RunService")
local UserInputService = game:GetService("UserInputService")

-- Variables
local LocalPlayer = Players.LocalPlayer
local Camera = workspace.CurrentCamera

-- Configuration
local Settings = {
    LockEnabled = false,
    ToggleKey = Enum.KeyCode.C,
    Smoothness = 0.2,            -- 0.1 to 0.5 (PS5 feel)
    TargetPart = "HumanoidRootPart",
    TeamCheck = false            -- Set to true to ignore teammates
}

-- Function to find the NEAREST player by distance (3D Distance)
local function GetNearestPlayer()
    local target = nil
    local shortestDistance = math.huge -- Start with infinity

    for _, player in pairs(Players:GetPlayers()) do
        if player ~= LocalPlayer and player.Character then
            local root = player.Character:FindFirstChild(Settings.TargetPart)
            local hum = player.Character:FindFirstChild("Humanoid")
            local myRoot = LocalPlayer.Character and LocalPlayer.Character:FindFirstChild("HumanoidRootPart")

            if root and hum and hum.Health > 0 and myRoot then
                if Settings.TeamCheck and player.Team == LocalPlayer.Team then
                    continue
                end

                -- Calculate 3D distance between you and the enemy
                local distance = (myRoot.Position - root.Position).Magnitude
                


Comments

3
Log in to join the conversation. Login
justinsantiagopro11's profile picture
justinsantiagopro117 months ago

it works beautifully, thx a lot for making this

2
neosnapp's profile picture
neosnappUploader7 months ago

''C'' to close/open

1
neosnapp's profile picture
neosnappUploader7 months ago

used ai fully pls support me report bugs discord : neo_snap_31882

1