/// <summary> /// Initialize the Pig Game Form. /// </summary> public Pig_Game_Form() { InitializeComponent(); Pig_Single_Die_Game.SetUpGame(); pigLabelWhosTurnTo.Text = Pig_Single_Die_Game.GetFirstPlayersName(); Pig_rollOrHoldLabel.Text = "Roll die"; holdButton.Enabled = false; }
private void YesRadio_CheckedChanged(object sender, EventArgs e) { Pig_Single_Die_Game.SetUpGame(); // Reset the game RollBtn.Enabled = true; // Enable the roll button again GameTerminal.Enabled = false; // Disable the play again choice FormUpdate(); yesButton.Checked = false; }
}//end of HoldButton_Click /// <summary> /// Setup game, updates WhoseTurnToLabel, updates textbox, unchecks YesOption button /// Disables groupbox. /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void YesOption_CheckedChanged(object sender, EventArgs e) { Pig_Single_Die_Game.SetUpGame(); WhoseTurnToLabel.Text = "Player 1"; PlayerOneTotalTextBox.Text = ""; PlayerTwoTotalTextBox.Text = ""; YesOption.Checked = false; AnotherGameGroupBox.Enabled = false; }//end of YesOption_Checked
public PigGameForm() { InitializeComponent(); Pig_Single_Die_Game.SetUpGame(); SetDieImage(); lblWhoseTurn.Text = Pig_Single_Die_Game.GetFirstPLayersName().ToString(); SetRollMessage(); SetPlayerScores(); }
public Pig_Game_Form() { InitializeComponent(); Pig_Single_Die_Game.SetUpGame(); FormUpdate(); }
public Pig_Game_Form() { InitializeComponent(); Pig_Single_Die_Game.SetUpGame(); PictureBox.Image = Images.GetDieImage(Pig_Single_Die_Game.GetFaceValue()); }