Пример #1
0
        /// <summary>
        /// Calls the raiseFunction and updates appropriate values when button is pressed
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void enterRaise_Click(object sender, EventArgs e)
        {
            int raiseInt = Int32.Parse(raiseInput.Text);

            if (raiseInt > scorekeeper.playerCurrency)
            {
                MessageBox.Show("The value entered is more than you have!\n Enter a lower value");
            }
            else if (raiseInt <= scorekeeper.currentBet)
            {
                MessageBox.Show("The amount you entered is lower than or equal to the current bet!\n Enter a higher value");
            }
            else
            {
                scorekeeper.raiseFunction(raiseInt);
                updateValues();
                endBet();
            }
        }