From a4582632c685e146bfebb03ce10bf2a0082ae73a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Zurcher?= Date: Sat, 7 May 2016 17:43:59 +0200 Subject: Map4Orders: fix unit orientation on replay ENTER order --- core/src/ch/asynk/rustanddust/game/map/Map4Orders.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/core/src/ch/asynk/rustanddust/game/map/Map4Orders.java b/core/src/ch/asynk/rustanddust/game/map/Map4Orders.java index 05cc569..c30e6bd 100644 --- a/core/src/ch/asynk/rustanddust/game/map/Map4Orders.java +++ b/core/src/ch/asynk/rustanddust/game/map/Map4Orders.java @@ -287,8 +287,11 @@ public abstract class Map4Orders extends Map3Animations break; case ENTER: claim(unit, move.from); - if (order.replay) - unit.setOnTile(move.from, Orientation.NORTH.r()); + if (order.replay) { + Orientation entry = findBestEntry(unit, move.from, unit.entryZone.allowedMoves); + // Hex from = (Hex) getAdjTileAt(move.from, entry); + unit.setOnTile(move.from, entry.opposite().r()); + } playMoveSound(unit); moveUnit(unit, move, this, order.replay); break; -- cgit v1.1-2-g2b99