for key, object in ipairs(game.Players:GetPlayers()) do
object.TeamColor = BrickColor.new("Medium stone grey")
end
I have this script that changes all the players team from an auto assignable "Really black" one, to "Medium stone grey" which is not auto assignable, but the problem is after the switch, if the players die, they remain on Medium stone grey, instead of switching back to "Really black." This is what i have tried:
for key, object in ipairs(game.Players:GetPlayers()) do
object.TeamColor = BrickColor.new("Medium stone grey")
break
end
But it didn't work. Can anyone help?

2 comments
Thank you so much!
@ThatOneKid7590 np