diff options
-rw-r--r-- | core/src/ch/asynk/tankontank/game/Map.java | 5 | ||||
-rw-r--r-- | core/src/ch/asynk/tankontank/game/states/StateMove.java | 6 |
2 files changed, 3 insertions, 8 deletions
diff --git a/core/src/ch/asynk/tankontank/game/Map.java b/core/src/ch/asynk/tankontank/game/Map.java index a756819..390b517 100644 --- a/core/src/ch/asynk/tankontank/game/Map.java +++ b/core/src/ch/asynk/tankontank/game/Map.java @@ -370,11 +370,6 @@ public abstract class Map extends Board implements MoveToAnimationCb, ObjectiveS public int exitBoard(Unit unit) { - // if (unit.justEntered()) { - // objectives.revert(); - // unit.reset(); - // } - return process(unit, pathBuilder.getExitMove()); } diff --git a/core/src/ch/asynk/tankontank/game/states/StateMove.java b/core/src/ch/asynk/tankontank/game/states/StateMove.java index f81035d..cce19a6 100644 --- a/core/src/ch/asynk/tankontank/game/states/StateMove.java +++ b/core/src/ch/asynk/tankontank/game/states/StateMove.java @@ -101,7 +101,7 @@ public class StateMove extends StateCommon public void touchUp() { if (upHex == activeUnit.getHex()) { - if (to !=null) + if (to != null) map.hidePath(to); to = null; map.pathBuilder.clear(); @@ -123,7 +123,7 @@ public class StateMove extends StateCommon } if (s == 1) { - if (!checkExit(activeUnit, to)) + if (!checkExit(activeUnit, upHex)) ctrl.setState(StateType.ROTATE); } } @@ -149,8 +149,8 @@ public class StateMove extends StateCommon map.showPossibleMoves(); map.selectHex(hex); activeUnit.enableOverlay(Unit.MOVE, false); - checkExit(activeUnit, hex); ctrl.hud.notify(activeUnit.toString()); + checkExit(activeUnit, hex); } private int collectPaths(Hex hex) |