diff options
Diffstat (limited to 'src/Tile.java')
-rw-r--r-- | src/Tile.java | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/Tile.java b/src/Tile.java index f2548f7..7420a2a 100644 --- a/src/Tile.java +++ b/src/Tile.java @@ -5,11 +5,20 @@ public class Tile { CLEAR, GRASS, WATER, MOUNTAIN, NONE }; + // TODO: make public private final int x, y; + // TODO: make final private Type type; + // TODO: refractor to inRange; private boolean selected; - private boolean cursorOnIt; + // TODO: it would be better if the MapScene had a member tileUnderCursor + private boolean cursorOnIt; // underCursor? + // TODO: make final, or make a table to match type to cost private double cost; + // TODO: remove and make here a method + // double distanceFrom(Tile other); + // or a method in Map.java + // double distanceBetween(Tile firstTile, Tile secondTile); private double distance; public Tile(Type type, int x, int y) { @@ -64,6 +73,7 @@ public class Tile { return this.type; } + // TODO: remove this feature and make the member final public void setType(Type type) { this.type = type; switch (this.type) { @@ -99,6 +109,7 @@ public class Tile { return this.selected; } + // TODO: rename to isInRange() and this.selected => inRange public boolean isSelected() { return this.selected; } |