This script is supposed to remove it's parent when someone touches it. As of now, it removes itself when anything touches it. I was wondering if it was possible to make it remove itself ONLY when a humanoid touches it.
function touch() script.Parent:remove() end script.Parent.Touched:connect(touch)
script.Parent.Touched:connect(function(hit) if hit.Parent:FindFirstChild("Humanoid") then hit:Destroy() end end)
This will destroy anything that touches it as long as there is a object called Humanoid inside the part's parent