local FIRE_DELAY = 0.35 local BULLET_THICKNESS = 0.12 local BULLET_FADE_TIME = 0.14 local BULLET_COLOR = Color3.fromRGB(255, 140, 39) -- local Players = game:GetService("Players") local LocalPlayer = Players.LocalPlayer local Gun = LocalPlayer:WaitForChild("Backpack"):WaitForChild("Pistol") local GunEvent = Gun:WaitForChild("GunEvent") local function getHead(part) if not part then return nil end if part:IsA("Model") then return part:FindFirstChild("Head") or part:FindFirstChildWhichIsA("BasePart") end return part end local function createArgs(targetPlayer) if not targetPlayer then return nil end if targetPlayer == LocalPlayer then return nil end local character = targetPlayer.Character if not character then return nil end local head = getHead(character) if not head then return nil end local origin = Gun.Handle.FirePoint.WorldPosition local direction = (head.Position - origin).Unit local hitPos = head.Position return { "fire_bullet", { Normal = direction, HitPart = head, Aiming = false, BulletFadeTime = BULLET_FADE_TIME, UseClientVFX = false, BulletThickness = BULLET_THICKNESS, Hit = hitPos, FirePoint = Gun.Handle.FirePoint, Origin = origin, CT = tick(), BulletTrail = BULLET_COLOR }, { { HUM = character:FindFirstChild("Humanoid"), HI = { Normal = direction, HitPart = head, Hit = hitPos } } }, { Name = "Head", Size = Vector3.new(1,1,1) } } end while true do for _, player in Players:GetPlayers() do if player == LocalPlayer then continue end local args = createArgs(player) if args then pcall(function() GunEvent:FireServer(unpack(args)) end) end end task.wait(FIRE_DELAY) end