The way you’re handling parenting, network ownership aside, also plays a part in this. The way you’re doing it is pretty bad for performance. Specifically how you set properties before the parent.
Therefore, I suggest you combine network ownership with appropriate instancing. Set properties, then the parent. After everything’s done, put the bullet in the workspace.
local bullet = Instance.new("Part")
bullet.CFrame = CFrame.new(script.Parent.Barrel.CFrame.Position, mousepos)
local attachment1 = Instance.new("Attachment")
attachment1.Position = Vector3.new(0, 0.12, 0)
attachment1.Parent = bullet
local attachment2 = Instance.new("Attachment")
attachment2.Position = Vector3.new(0, -0.12, 0)
attachment2.Parent = bullet
local trail = script.BulletTrail:Clone()
trail.Attachment0 = attachment1
trail.Attachment1 = attachment2
trail.Parent = bullet
local velocity = Instance.new("BodyVelocity")
velocity.Velocity = bullet.CFrame.LookVector * module.bulletspread
bullet.Parent = workspace
bullet:SetNetworkOwner(nil)