Beispiel #1
0
 private void Validationbtn_Click(object sender, EventArgs e)
 {
     realpl = (int)nudRealPlayer.Value;
     coops  = (int)nudCoOps.Value;
     if (realpl + coops < 2)
     {
         MessageBox.Show("please make sure that here are at least 2 players");
     }
     else
     {
         formdata.setValues(realpl, coops);
         this.Close();
     }
 }
Beispiel #2
0
        /******************************
         * Methods
         *******************************/
        private void button1_Click(object sender, EventArgs e)
        {
            string text = (string)cbxPossibilities.SelectedItem;

            foreach (KeyValuePair <string, int> option in enums)
            {
                if (option.Key == text)
                {
                    data.setValues(option.Value);
                }
            }

            this.Close();
        }