diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2014-11-28 21:30:44 +0100 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2014-11-28 21:30:44 +0100 |
commit | 0e88585c271f77bda99b6f8eadb078cc4f58e233 (patch) | |
tree | 05d10ac9286981e3b3f89dc17e30071ab8b5d38f /core/src/ch | |
parent | 5c1be4afb822d80ed6dbd33f5c2772aa9f426ea4 (diff) | |
download | RustAndDust-0e88585c271f77bda99b6f8eadb078cc4f58e233.zip RustAndDust-0e88585c271f77bda99b6f8eadb078cc4f58e233.tar.gz |
StateMove: changeUnit() do not set MOVE overlay if has moved
Diffstat (limited to 'core/src/ch')
-rw-r--r-- | core/src/ch/asynk/tankontank/game/states/StateMove.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/core/src/ch/asynk/tankontank/game/states/StateMove.java b/core/src/ch/asynk/tankontank/game/states/StateMove.java index 32050a2..be09ed6 100644 --- a/core/src/ch/asynk/tankontank/game/states/StateMove.java +++ b/core/src/ch/asynk/tankontank/game/states/StateMove.java @@ -133,7 +133,8 @@ public class StateMove extends StateCommon { if (activeUnit != null ) { map.unselectHex(activeUnit.getHex()); - activeUnit.enableOverlay(Unit.MOVE, true); + if (activeUnit.canMove()) + activeUnit.enableOverlay(Unit.MOVE, true); } activeUnit = unit; Hex hex = activeUnit.getHex(); |