diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2015-01-21 22:16:17 +0100 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2015-01-21 22:16:17 +0100 |
commit | 9e4385e8874dc8807eb40913c07f45e6fdfcf8d2 (patch) | |
tree | abae44bb3afcf63b93d651bba86314347a02a781 /core | |
parent | b9f8cf9e93acd762f2c9f743c599f300e3f7d4ca (diff) | |
download | RustAndDust-9e4385e8874dc8807eb40913c07f45e6fdfcf8d2.zip RustAndDust-9e4385e8874dc8807eb40913c07f45e6fdfcf8d2.tar.gz |
StateMove: when unit just entered, do not propose to exit already
Diffstat (limited to 'core')
-rw-r--r-- | core/src/ch/asynk/tankontank/game/states/StateMove.java | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/core/src/ch/asynk/tankontank/game/states/StateMove.java b/core/src/ch/asynk/tankontank/game/states/StateMove.java index 4794d35..27bc6af 100644 --- a/core/src/ch/asynk/tankontank/game/states/StateMove.java +++ b/core/src/ch/asynk/tankontank/game/states/StateMove.java @@ -181,6 +181,8 @@ public class StateMove extends StateCommon private boolean checkExit(Unit unit, Hex hex) { + if ((hex == unit.getHex()) && (unit.justEntered())) + return false; Zone exitZone = ctrl.battle.getExitZone(unit); if ((exitZone == null) || !exitZone.contains(hex)) return false; |