Example #1
0
 private void AddDuo()
 {
     if (!String.IsNullOrWhiteSpace(txtDuo1.Text) && txtDuo1.Text.Length > 0 && !String.IsNullOrWhiteSpace(txtDuo2.Text) && txtDuo2.Text.Length > 0)
     {
         Player teammate = new Player(null, txtDuo2.Text, 0);
         pList.AddDuo(new Player(teammate, txtDuo1.Text, 2));
         txtDuo1.Clear();
         txtDuo2.Clear();
         txtDuo1.Select();
         txtDuo1.Focus();
         lblCount.Text = "Total Players: " + pList.totalPlayers;
     }
 }
Example #2
0
 public Player(Player team, String playerName, int playerCount)
 {
     teammate = team;
     name = playerName;
     count = playerCount;
 }
Example #3
0
 public void AddSolo(Player player)
 {
     playerList.Add(player);
     soloCount++;
     totalPlayers++;
 }
Example #4
0
 public void AddDuo(Player player)
 {
     playerList.Add(player);
     duoCount++;
     totalPlayers += 2;
 }