summaryrefslogtreecommitdiffstats
path: root/core/src/ch/asynk/tankontank
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2014-10-07 20:45:02 +0200
committerJérémy Zurcher <jeremy@asynk.ch>2014-10-07 20:45:02 +0200
commit1c6560a2e8057470dc33f0767d9480148c31eedc (patch)
treec18b12045dcc6714e125d217d781da1c7c984930 /core/src/ch/asynk/tankontank
parent2fa22466d527d4355066190db28bc64955244023 (diff)
downloadRustAndDust-1c6560a2e8057470dc33f0767d9480148c31eedc.zip
RustAndDust-1c6560a2e8057470dc33f0767d9480148c31eedc.tar.gz
Board: add Tile getTileSafe(GridPoint2)
Diffstat (limited to 'core/src/ch/asynk/tankontank')
-rw-r--r--core/src/ch/asynk/tankontank/engine/Board.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/core/src/ch/asynk/tankontank/engine/Board.java b/core/src/ch/asynk/tankontank/engine/Board.java
index b74dc87..f18403f 100644
--- a/core/src/ch/asynk/tankontank/engine/Board.java
+++ b/core/src/ch/asynk/tankontank/engine/Board.java
@@ -132,6 +132,11 @@ public abstract class Board implements Disposable
return tiles[idx];
}
+ public Tile getTileSafe(GridPoint2 coords)
+ {
+ return getTileSafe(coords.x, coords.y);
+ }
+
public Tile getTileSafe(int col, int row)
{
int colOffset = ((row + 1) / 2);