-
Notifications
You must be signed in to change notification settings - Fork 0
/
Square.cs
46 lines (42 loc) · 970 Bytes
/
Square.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace Minesweeper
{
[Serializable]
public class Square
{
public Square()
{
IsFlagged = false;
Number = -1;
IsMine = false;
}
/// <summary>
/// Whether the square has been flagged as a mine by the player
/// </summary>
public bool IsFlagged
{
get;
set;
}
/// <summary>
/// The number of the square for after is has been uncovered.
/// When square is not uncovered, Number equals -1
/// </summary>
public int Number
{
get;
set;
}
/// <summary>
/// Whether the square is a mine
/// </summary>
public bool IsMine
{
get;
set;
}
}
}