x = script.Parent.Parent.Terminal
if script.Parent.Humanoid.Health < 1 then
msg = Instance.new("Message")
msg.Parent = game.Workspace
msg.Text = "The (Team Name) Has Won!"
x:remove()
wait(5)
msg:remove()
script.Parent:remove()
end
Alright, so here is my intent for this script. This is inside a model with a humanoid. When the humanoid's health gets to 0, I'm trying to make it display a message saying a certain team has won, and then it is supposed to delete a similar model that has a different name. For some reason, though, this isn't happening when make it's health 0. Can someone explain why?

2 comments
Are you looping this or using the Humanoid.HealthChanged event to check if the health is less than 1? Also it would be easier to use the Humanoid.Died event instead of those but not required.
Thanks for the help. I've got a bit of experience with re-purposing scripts and I can write very basic things from scratch, but I'm trying to expand into more advanced areas.