Ok so here is the local script
Player = game.Players.LocalPlayer
Mouse = Player:GetMouse()
Ammo = 1
Mouse.KeyDown:connect(function(key)
key = key:lower()
if key == "f" and Ammo >0 then
local x = Instance.new("Part", workspace)
x.Size = Vector3.new(20,0,0)
x.Shape = "Ball"
x.BrickColor = BrickColor.new ("Toothpaste")
x.Material = "Neon"
x.Transparency = 0.2
x.TopSurface = "Smooth"
x.BottomSurface = "Smooth"
x.CanCollide = false
x.CFrame = Player.Character.Torso.CFrame * CFrame.new(0,-1,-5)
local v = Instance.new("BodyVelocity", x)
v.velocity = Player.Character.Torso.CFrame.lookVector * 90
v.maxForce = Vector3.new(math.huge, math.huge, math.huge)
Ammo = Ammo -1
wait(1)
Ammo = 1
local S = script["Script"]:clone()
S.Parent = x
x.Parent = workspace
wait(2)
x:remove()
end
end)
But i made it so it can attack but gets that error heres the script that won't work.
script.Parent.Touched:connect(function(hit)
if hit.Parent:FindFirstChild("Zombie")~=nil then
hit.Parent.Zombie.Health = hit.Parent.Zombie.Health - 4
script.Parent.remove()
end
end)
could someone tell me whats wrong and put the script down there thanks :D

3 comments
Also, use :Destroy() because :Remove() is deprecated.
Format your code correctly.
yeah sorry here it is