i have a brick with a script like this:
script.Parent.Touched:connect(function(hit)
if hit and hit.Parent and hit.Parent:FindFirstChild("Humanoid") then
wait(.1)
hit.Parent.Humanoid.Health = 0
else
hit.Destroy()
end
end)
but whenever something besides a humanoid touches it it wont destroy it
please help

3 comments
Do you want it to be only a player can touch it? Or any object?
If your looking to make a script that kills a player then try this
FE?