-I am wanting this script to be able to be copy and pasted from ServerStorage into workspace and work perfectly fine.
Here is the Script:
function changeTeams(player)
wait(1)
local deadPlayer = game.Players:GetPlayerFromCharacter(player)
if deadPlayer ~= nil then
deadPlayer.TeamColor = BrickColor.new("Bright green")
end
end
function deathCheck(character)
character.Humanoid.Died:connect(function()
changeTeams(character)
end)
end
function playerAdded(player)
player.CharacterAdded:connect(deathCheck)
end
game.Players.PlayerAdded:connect(playerAdded)
-I got the script to work, but I cant however make it work after pasting it from server storage or disabling and undisabling it.

7 comments
this is very confusing, because you set all of your parameters/arguments to player.
fixed it so it works but, Cant past from server sotrage
You can't paste this script into Workspace. The Event PlayerAdded only fires once per player, and that's when they first enter. When you copy it, that event needs to fire again before it will work.
Is there a way to make it so that if your on a certain team and you die, you change to another
I could help, but That would mean i'd have to re-write it.
You can just explain me what to write where and ill rewrite it :p But if you rewrite it and it works I can accept your answer
I found your main problem (Edited Answer)