summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2015-01-12 23:19:56 +0100
committerJérémy Zurcher <jeremy@asynk.ch>2015-01-12 23:19:56 +0100
commit1f1d2054d31f2ef1b0aeeecd824a08a83f044855 (patch)
tree888504f47da177734342660c69fe996566cf888c /core
parent3d0a4d1c4c38ea87c2d7fcb284904de37a11aaf6 (diff)
downloadRustAndDust-1f1d2054d31f2ef1b0aeeecd824a08a83f044855.zip
RustAndDust-1f1d2054d31f2ef1b0aeeecd824a08a83f044855.tar.gz
Board,Map: regroup possiblePaths manipulations in Map
Diffstat (limited to 'core')
-rw-r--r--core/src/ch/asynk/tankontank/engine/Board.java1
-rw-r--r--core/src/ch/asynk/tankontank/game/Map.java1
2 files changed, 1 insertions, 1 deletions
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);