-
Notifications
You must be signed in to change notification settings - Fork 1
/
Move.java
38 lines (35 loc) · 907 Bytes
/
Move.java
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
/** MineSweeper
* @author Chase Carnaroli
*
* Move class represents the move made by the player
*
* INSTANCE VARIABLES
* Location loc // location of the click
* Click move // type of click made by the user
*
* METHODS
* getLocation() -> Location // returns location
* getClickType() -> Click // returns click type
*/
public class Move
{
// instance variables
private Location loc; // location of the click
private Click move; // type of click made by the user
/**
* Constructor for objects of class Move
*/
public Move(Location loc, Click move)
{
this.loc = loc;
this.move = move;
}
// returns location
public Location getLocation(){
return loc;
}
// returns click type
public Click getClickType(){
return move;
}
}