Example #1
0
 //remove the player who left from his team
 public override void OnPlayerLeftRoom(Player otherPlayer)
 {
     if (!IsMasterClient)
     {
         return;
     }
     TeamExt.RemovePlayerFromTeam(otherPlayer, m_maxTeamSize, m_minTeamCount);
 }
Example #2
0
 //assign each new joined player to a team
 public override void OnPlayerEnteredRoom(Player newPlayer)
 {
     if (!IsMasterClient)
     {
         return;
     }
     TeamExt.AssignToSmallest(newPlayer, m_maxTeamSize, m_minTeamCount);
 }