예제 #1
0
        private char GetCellCharacter(BoardCell cell)
        {
            if (cell.IsMarked)
            {
                return('X');
            }

            if (!cell.IsRevealed)
            {
                return('.');
            }

            if (cell.HasMine)
            {
                return('*');
            }

            if (cell.MineCount == 0)
            {
                return(' ');
            }

            return(cell.MineCount.ToString()[0]);
        }