Run it
Copy the script and paste it into your executor.
-- discord.gg/d66H53XCsX
local Players = game:GetService("Players")
local Workspace = game:GetService("Workspace")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local LocalPlayer = Players.LocalPlayer
local Character = LocalPlayer.Character or LocalPlayer.CharacterAdded:Wait()
HumanoidRootPart = Character:(, )
utility = {}
utility.()
_, tool (Character:())
tool:() tool:()
tool
utility.(maxDistance)
closestNPC, minDist = , maxDistance
_, obj (Workspace:())
root = obj:()
humanoid = obj:()
root humanoid humanoid.Health > Players:(obj)
distance = (HumanoidRootPart.Position - root.Position).Magnitude
distance < minDist
closestNPC, minDist = humanoid, distance
closestNPC
utility.(weapon, state)
ammo = state:()
ammo ammo.Value == state.IsReloading.Value
ReplicatedStorage.Remotes.Weapon.Reload:(Workspace:(), weapon)
.() ammo.Value >
utility.(npc, weapon, state)
npc weapon state
ammo = state:()
ammo ammo.Value >
ReplicatedStorage.Remotes.Weapon.Shoot:(Workspace:(), weapon, HumanoidRootPart.CFrame, { [] = npc })
.()
npc = utility.()
weapon = utility.()
weapon
state = weapon:()
state
utility.(weapon, state)
utility.(npc, weapon, state)
made by wynnech <3 IF YOU WANT TO USE THIS IN YOUR SCRIPT PLEASE CREDIT ME

Dead Rails