summaryrefslogtreecommitdiffstats
path: root/core/src/ch
diff options
context:
space:
mode:
Diffstat (limited to 'core/src/ch')
-rw-r--r--core/src/ch/asynk/rustanddust/engine/Path.java9
1 files changed, 9 insertions, 0 deletions
diff --git a/core/src/ch/asynk/rustanddust/engine/Path.java b/core/src/ch/asynk/rustanddust/engine/Path.java
index 72dcb38..68f1cdc 100644
--- a/core/src/ch/asynk/rustanddust/engine/Path.java
+++ b/core/src/ch/asynk/rustanddust/engine/Path.java
@@ -64,4 +64,13 @@ public class Path implements Disposable, Pool.Poolable
tiles.clear();
pathPool.free(this);
}
+
+ @Override
+ public String toString()
+ {
+ String s = String.format("path(c:%d - r:%b - f:%d)\n", cost, roadMarch, fitness);
+ for (Tile t : tiles)
+ s += String.format(" %s\n", t.toString());
+ return s;
+ }
}