From 1f1d2054d31f2ef1b0aeeecd824a08a83f044855 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Zurcher?= Date: Mon, 12 Jan 2015 23:19:56 +0100 Subject: Board,Map: regroup possiblePaths manipulations in Map --- core/src/ch/asynk/tankontank/engine/Board.java | 1 - core/src/ch/asynk/tankontank/game/Map.java | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/ch/asynk/tankontank/engine/Board.java b/core/src/ch/asynk/tankontank/engine/Board.java index 3b34110..28164ce 100644 --- a/core/src/ch/asynk/tankontank/engine/Board.java +++ b/core/src/ch/asynk/tankontank/engine/Board.java @@ -429,7 +429,6 @@ public abstract class Board implements Disposable, Animation protected void movePawn(final Pawn pawn, PossiblePaths possiblePaths, RunnableAnimation whenDone, MoveToAnimationCb cb) { - possiblePaths.applyToPawn(0); removePawn(pawn); AnimationSequence seq = pawn.getMoveAnimation(possiblePaths.iterator(), (possiblePaths.pathSteps(0) + 2), cb); diff --git a/core/src/ch/asynk/tankontank/game/Map.java b/core/src/ch/asynk/tankontank/game/Map.java index fb7c50a..882d8f5 100644 --- a/core/src/ch/asynk/tankontank/game/Map.java +++ b/core/src/ch/asynk/tankontank/game/Map.java @@ -315,6 +315,7 @@ public abstract class Map extends Board public int moveUnit(Unit unit, Orientation o) { possiblePaths.orientation = o; + possiblePaths.applyToPawn(0); movePawn(unit, possiblePaths, notifyDoneAnimation(unit), objectives); return startMove(unit); -- cgit v1.1-2-g2b99