--// Cache
local select = select
local pcall, getgenv, next, Vector2, mathclamp, type, mousemoverel = select(1,
pcall, getgenv, next, [Link], [Link], type, mousemoverel or (Input and
[Link]))
--// Preventing Multiple Processes
pcall(function()
getgenv().[Link]:Exit()
end)
--// Environment
getgenv().Aimbot = {}
local Environment = getgenv().Aimbot
--// Services
local RunService = game:GetService("RunService")
local UserInputService = game:GetService("UserInputService")
local TweenService = game:GetService("TweenService")
local Players = game:GetService("Players")
local Camera = [Link]
local LocalPlayer = [Link]
--// Variables
local RequiredDistance, Typing, Running, Animation, ServiceConnections = 2000,
false, false, nil, {}
--// Script Settings
[Link] = {
Enabled = true,
TeamCheck = true,
AliveCheck = true,
WallCheck = false, -- Laggy
Sensitivity = 0, -- Animation length (in seconds) before fully locking onto
target
ThirdPerson = false, -- Uses mousemoverel instead of CFrame to support
locking in third person (could be choppy)
ThirdPersonSensitivity = 3, -- Boundary: 0.1 - 5
TriggerKey = "MouseButton2",
Toggle = false,
LockPart = "Head" -- Body part to lock on
}
[Link] = {
Enabled = true,
Visible = true,
Amount = 90,
Color = [Link](255, 255, 255),
LockedColor = [Link](255, 70, 70),
Transparency = 0.5,
Sides = 60,
Thickness = 1,
Filled = false
}
[Link] = [Link]("Circle")
--// Functions
local function CancelLock()
[Link] = nil
if Animation then Animation:Cancel() end
[Link] = [Link]
end
local function GetClosestPlayer()
if not [Link] then
RequiredDistance = ([Link] and
[Link] or 2000)
for _, v in next, Players:GetPlayers() do
if v ~= LocalPlayer then
if [Link] and
[Link]:FindFirstChild([Link]) and
[Link]:FindFirstChildOfClass("Humanoid") then
if [Link] and [Link] ==
[Link] then continue end
if [Link] and
[Link]:FindFirstChildOfClass("Humanoid").Health <= 0 then continue end
if [Link] and
#(Camera:GetPartsObscuringTarget({[Link][[Link]].Positi
on}, [Link]:GetDescendants())) > 0 then continue end
local Vector, OnScreen =
Camera:WorldToViewportPoint([Link][[Link]].Position)
local Distance =
(Vector2(UserInputService:GetMouseLocation().X,
UserInputService:GetMouseLocation().Y) - Vector2(Vector.X, Vector.Y)).Magnitude
if Distance < RequiredDistance and OnScreen then
RequiredDistance = Distance
[Link] = v
end
end
end
end
elseif (Vector2(UserInputService:GetMouseLocation().X,
UserInputService:GetMouseLocation().Y) -
Vector2(Camera:WorldToViewportPoint([Link][[Link]
[Link]].Position).X,
Camera:WorldToViewportPoint([Link][[Link]
art].Position).Y)).Magnitude > RequiredDistance then
CancelLock()
end
end
--// Typing Check
[Link] =
[Link]:Connect(function()
Typing = true
end)
[Link] =
[Link]:Connect(function()
Typing = false
end)
--// Main
local function Load()
[Link] =
[Link]:Connect(function()
if [Link] and [Link]
then
[Link] = [Link]
[Link] =
[Link]
[Link] = [Link]
[Link] = [Link]
[Link] = [Link]
[Link] =
[Link]
[Link] = [Link]
[Link] =
Vector2(UserInputService:GetMouseLocation().X,
UserInputService:GetMouseLocation().Y)
else
[Link] = false
end
if Running and [Link] then
GetClosestPlayer()
if [Link] then
if [Link] then
[Link] =
mathclamp([Link], 0.1, 5)
local Vector =
Camera:WorldToViewportPoint([Link][[Link]
art].Position)
mousemoverel((Vector.X -
UserInputService:GetMouseLocation().X) *
[Link], (Vector.Y -
UserInputService:GetMouseLocation().Y) *
[Link])
else
if [Link] > 0 then
Animation = TweenService:Create(Camera,
[Link]([Link], [Link],
[Link]), {CFrame = [Link]([Link],
[Link][[Link]].Position)})
Animation:Play()
else
[Link] =
[Link]([Link],
[Link][[Link]].Position)
end
end
[Link] = [Link]
end
end
end)
[Link] =
[Link]:Connect(function(Input)
if not Typing then
pcall(function()
if [Link] ==
[Link][[Link]] then
if [Link] then
Running = not Running
if not Running then
CancelLock()
end
else
Running = true
end
end
end)
pcall(function()
if [Link] ==
[Link][[Link]] then
if [Link] then
Running = not Running
if not Running then
CancelLock()
end
else
Running = true
end
end
end)
end
end)
[Link] =
[Link]:Connect(function(Input)
if not Typing then
if not [Link] then
pcall(function()
if [Link] ==
[Link][[Link]] then
Running = false; CancelLock()
end
end)
pcall(function()
if [Link] ==
[Link][[Link]] then
Running = false; CancelLock()
end
end)
end
end
end)
end
--// Functions
[Link] = {}
function [Link]:Exit()
for _, v in next, ServiceConnections do
v:Disconnect()
end
if [Link] then [Link]:Remove() end
getgenv().[Link] = nil
getgenv().Aimbot = nil
Load = nil; GetClosestPlayer = nil; CancelLock = nil
end
function [Link]:Restart()
for _, v in next, ServiceConnections do
v:Disconnect()
end
Load()
end
function [Link]:ResetSettings()
[Link] = {
Enabled = true,
TeamCheck = true,
AliveCheck = true,
WallCheck = false,
Sensitivity = 0, -- Animation length (in seconds) before fully locking
onto target
ThirdPerson = false, -- Uses mousemoverel instead of CFrame to support
locking in third person (could be choppy)
ThirdPersonSensitivity = 3, -- Boundary: 0.1 - 5
TriggerKey = "MouseButton2",
Toggle = false,
LockPart = "Head" -- Body part to lock on
}
[Link] = {
Enabled = true,
Visible = true,
Amount = 90,
Color = [Link](255, 255, 255),
LockedColor = [Link](255, 70, 70),
Transparency = 0.5,
Sides = 60,
Thickness = 1,
Filled = false
}
end
--// Load
Load()