Ejemplo n.º 1
0
        private void timer1_Tick(object sender, EventArgs e)
        {
            enGameStatus status = m_game.Status;

            if (status != enGameStatus.InProgress)
            {
                this.toolStripStatusLabel1.Text = "Game Over: " + (m_game.Status == enGameStatus.Lost? "You Lost :(" : "You Won!");
            }
            else
            {
                this.toolStripStatusLabel1.Text = String.Format("Found: {1} out of {0}, Time: {2}", m_game.MineCount, m_game.FlagCount, (DateTime.Now - m_game_start_time).ToString(@"hh\:mm\:ss"));
            }
        }
Ejemplo n.º 2
0
 public GameEngine(Position size)
 {
     m_board  = new GameBoard(11, 12, size);
     m_status = enGameStatus.Live;
 }