public class Tile
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
Tile.Type
An enum representing the different types of Tiles that may appear in a
cavern.
|
Constructor and Description |
---|
Tile(int r,
int c,
int g,
Tile.Type t)
Constructs a new Tile parameterized on its row, column, gold, and Type.
|
Modifier and Type | Method and Description |
---|---|
int |
getColumn()
Returns the column of this Tile.
|
int |
getGold()
Returns the amount of gold on this Tile.
|
int |
getOriginalGold() |
int |
getRow()
Returns the row of this Tile.
|
Tile.Type |
getType()
Returns the Type of this Tile.
|
int |
takeGold()
Sets the gold on this Node to 0 and returns the amount "taken"
|
public Tile(int r, int c, int g, Tile.Type t)
r
- The row of this Tilec
- The column of this Tileg
- The gold on this Tilet
- The Type of this Tilepublic int getGold()
public int getOriginalGold()
public int getRow()
public int getColumn()
public Tile.Type getType()
public int takeGold()