summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
Diffstat (limited to 'core')
-rw-r--r--core/src/ch/asynk/tankontank/game/Hex.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/core/src/ch/asynk/tankontank/game/Hex.java b/core/src/ch/asynk/tankontank/game/Hex.java
index 6e89df4..5fa1ee6 100644
--- a/core/src/ch/asynk/tankontank/game/Hex.java
+++ b/core/src/ch/asynk/tankontank/game/Hex.java
@@ -39,7 +39,12 @@ public class Hex extends Tile
public String toString()
{
- return "(" + col + ";" + row + ") [" + x + ";" + y + "] " + "t:" + terrain + " r:" + roads;
+ return String.format("(%d;%d) [%f;%f] t:%s r:%d", col, row, x, y, terrain, roads);
+ }
+
+ public String toShort()
+ {
+ return String.format("(%d;%d)", col, row);
}
public Hex(float x, float y, int col, int row, TextureAtlas atlas)