diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2014-10-07 20:45:02 +0200 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2014-10-07 20:45:02 +0200 |
commit | 1c6560a2e8057470dc33f0767d9480148c31eedc (patch) | |
tree | c18b12045dcc6714e125d217d781da1c7c984930 /core | |
parent | 2fa22466d527d4355066190db28bc64955244023 (diff) | |
download | RustAndDust-1c6560a2e8057470dc33f0767d9480148c31eedc.zip RustAndDust-1c6560a2e8057470dc33f0767d9480148c31eedc.tar.gz |
Board: add Tile getTileSafe(GridPoint2)
Diffstat (limited to 'core')
-rw-r--r-- | core/src/ch/asynk/tankontank/engine/Board.java | 5 |
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); |