Esempio n. 1
0
        private void BtnCheck_Click(object sender, EventArgs e)
        {
            this.Hide(); //the form disappears
            FrmHighScores FrmHighScore2 = new FrmHighScores();

            FrmHighScore2.ShowDialog(); //this shows the form as a modal dialog box.
            this.Close();               //this closes the form to complete the form change
        }
Esempio n. 2
0
        private void CheckScore()
        {
            if (score == 5)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score5;
            }

            if (score == 10)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score10;
            }
            if (score == 15)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score15;
            }
            if (score == 20)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score20;
            }
            if (score == 25)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score25;
            }
            if (score == 30)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score30;
            }
            if (score == 35)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score35;
            }
            if (score == 40)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score40;
            }
            if (score == 45)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score45;
            }
            if (score == 50)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score50;
            }
            if (score == 55)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score55;
            }
            if (score == 60)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score60;
            }
            if (score == 65)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score65;
            }
            if (score == 70)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score70;
            }
            if (score == 75)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score75;
            }
            if (score == 80)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score80;
            }
            if (score == 85)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score85;
            }
            if (score == 90)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score90;
            }

            if (score == 95)
            {
                pictureBox5.BackgroundImage = Properties.Resources.score95;
            }
            if (score == 100)
            {
                tmrGood.Enabled      = false;
                tmrBad.Enabled       = false;
                tmrCountdown.Enabled = false;
                MessageBox.Show("level completed");
                pictureBox5.BackgroundImage = Properties.Resources.score100;
                level = 5;


                this.Hide();                //the form disappears
                FrmHighScores FrmHighScore2 = new FrmHighScores();
                FrmHighScore2.ShowDialog(); //this shows the form as a modal dialog box.
                this.Close();               //this closes the form to complete the form change;
            }
        }