20.07.2014, 13:05
use a variable with MAX_TEAM_PLAYERS, assign the player's team to team 1. add if team 1 is more than team 2 then set the player to team 2, otherwise, set them to team 1. if team 1 = MAX_TEAM_PLAYERS then set it to the other team, else return an error message that the server is full.