Yo i got this team door script when i touch it i don't die and i want the door to kill how to do it ?
Door = script.Parent
------------------------------------
modelname="Desert Military Team"
------------------------------------
function onTouched(hit)
print("Door Hit")
local human = hit.Parent:FindFirstChild("Humanoid")
if (human ~= nil ) then
if game.Players:playerFromCharacter(hit.Parent).TeamColor==game.Teams:findFirstChild(modelname).TeamColor then
Door.CanCollide = false
Door.Transparency = 0.5
wait(2)
Door.CanCollide = true
Door.Transparency = 0
print("Human touched door")
end
end
end
connection = Door.Touched:connect(onTouched)

1 comment
thank you