
Key Required

getgenv().Enabled = true
local Players = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local Camera = workspace.CurrentCamera
local LocalPlayer = Players.LocalPlayer
local RaycastModule = require(ReplicatedStorage:WaitForChild("Events"):WaitForChild("Modules"):WaitForChild("RaycastModule"))
local AIM_CONE = 85
local PREDICTION = 0.045
local function GetClosestTarget()
local Closest, Shortest = nil, math.huge
local CamPos, CamLook = Camera.CFrame.Position, Camera.CFrame.LookVector
local Center = Vector2.new(Camera.ViewportSize.X/2, Camera.ViewportSize.Y/2)
for _, Player in ipairs(Players:GetPlayers()) do
if Player == LocalPlayer or (Player.Team and Player.Team == LocalPlayer.Team) then continue end
local Char = Player.Character
if not Char then continue end
local Head, Hum = Char:FindFirstChild("Head"), Char:FindFirstChildOfClass("Humanoid")
if not (Head and Hum and Hum.Health > 0) then continue end
local Dir = (Head.Position - CamPos).Unit
local Angle = math.deg(math.acos(CamLook:Dot(Dir)))
if Angle < AIM_CONE then
local ScreenPos, OnScreen = Camera:WorldToViewportPoint(Head.Position)
if OnScreen then
local Dist = (Vector2.new(ScreenPos.X, ScreenPos.Y) - Center).Magnitude
if Dist < Shortest then
Shortest = Dist
Closest = Head
end
end
end
end
return Closest
end
for i, f in pairs(RaycastModule) do
if typeof(f) == "function" then
RaycastModule[i] = function(...)
if not getgenv().Enabled then return f(...) end
local Target = GetClosestTarget()
if not Target then return f(...) end
local Pred = Target.Position + (Target.Velocity * PREDICTION)
return Target, Pred, Vector3.zero
end
end
end



This is my first time making this type of script, hope y'all like it 🤗
@meowtology it's good😄
Yow U Have Script That give Gamepass And Source
@Oehx no 😕
W
Fire
why if im execute it my guns dont work like im clicking on it and nothing its bugged me everyx round i have revolver idk
I loved it, man! The only problem is that I got banned. * that game, but at least I had fun :D