Esempio n. 1
0
 private void btLv5_Click(object sender, EventArgs e)
 {
     Level5 f2 = new Level5();
     this.Hide();
     f2.ShowDialog();
     this.Close();
 }
Esempio n. 2
0
        private void bt_Replay_Click(object sender, EventArgs e)
        {
            this.Hide();
            string level_restart = string.Empty;

            if (Variabile.nivel_actual == 1)
            {
                Level1 lv = new Level1(); lv.ShowDialog();
            }
            else if (Variabile.nivel_actual == 2)
            {
                Level2 lv = new Level2(); lv.ShowDialog();
            }
            else if (Variabile.nivel_actual == 3)
            {
                Level3 lv = new Level3(); lv.ShowDialog();
            }
            else if (Variabile.nivel_actual == 4)
            {
                Level4 lv = new Level4(); lv.ShowDialog();
            }
            else
            {
                Level5 lv = new Level5(); lv.ShowDialog();
            }
            this.Close();
        }
Esempio n. 3
0
        private void btReset_Click(object sender, EventArgs e)
        {
            timer1.Stop();
            Level5 f2 = new Level5();

            this.Hide();
            f2.ShowDialog();
            this.Close();
        }
Esempio n. 4
0
        private void timer1_Tick(object sender, EventArgs e)
        {
            if (timeLeft > 0)
            {
                timeLeft         = timeLeft - 1;
                lbTimpRamas.Text = timeLeft + "";
            }
            else
            {
                timer1.Stop();
                lbTimpRamas.Text = "0";

                MessageBox.Show("Time is up, try again!");

                Level5 f2 = new Level5();
                this.Hide();
                f2.ShowDialog();
                this.Close();
            }
        }