Just looking around to see if anyone else is experiencing this issue. Teamcollection.GetAgents returns all members on a team, however this completely breaks when players leave the game.
To recreate the issue, create a lobby and have a friend join and leave several times, the Playspace players will remain correct but the TeamAgents will grow with every join filling up an array with garbage.
if (TeamAgents:= TeamCollection.GetAgents[Teams[0]])
{
# Should print the correct number of players in a lobby
Print("Players: {PlaySpace.GetPlayers().Length}");
# Prints the number of players on the team, or at least it should.
Print("TeamAgents: {TeamAgents.Length}");
}