From bf6bbd5609cd125d8b3e5a7fbe6f2cd49146af49 Mon Sep 17 00:00:00 2001 From: Nao Pross Date: Mon, 19 Nov 2018 00:02:46 +0100 Subject: Add TODOs for various corrections --- src/Tile.java | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'src/Tile.java') 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; } -- cgit v1.2.1