summaryrefslogtreecommitdiffstats
path: root/core/src/ch/asynk/tankontank/game
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2015-02-18 15:40:55 +0100
committerJérémy Zurcher <jeremy@asynk.ch>2015-02-18 15:40:55 +0100
commitc565c843058d3a6c28ac1e288fb4ea1d1e529be7 (patch)
tree86b6b95c81d9799397b04f8978d986e933ef97d0 /core/src/ch/asynk/tankontank/game
parent0b35e5b14cc58f87bab6364d236c141b82e03117 (diff)
downloadRustAndDust-c565c843058d3a6c28ac1e288fb4ea1d1e529be7.zip
RustAndDust-c565c843058d3a6c28ac1e288fb4ea1d1e529be7.tar.gz
StateDeployment: show Unit on board, emit the real move after rotation selection
Diffstat (limited to 'core/src/ch/asynk/tankontank/game')
-rw-r--r--core/src/ch/asynk/tankontank/game/states/StateDeployment.java9
1 files changed, 6 insertions, 3 deletions
diff --git a/core/src/ch/asynk/tankontank/game/states/StateDeployment.java b/core/src/ch/asynk/tankontank/game/states/StateDeployment.java
index 3fd9aa5..9fb9a7e 100644
--- a/core/src/ch/asynk/tankontank/game/states/StateDeployment.java
+++ b/core/src/ch/asynk/tankontank/game/states/StateDeployment.java
@@ -101,7 +101,7 @@ public class StateDeployment extends StateCommon
{
selectedUnit = unit;
selectedHex = upHex;
- map.setOnBoard(unit, upHex, entryZone.orientation);
+ map.showOnBoard(unit, upHex, entryZone.orientation);
deployedUnits.add(unit);
entryZone.enable(Hex.AREA, false);
showRotation(unit, upHex);
@@ -122,8 +122,11 @@ public class StateDeployment extends StateCommon
{
map.unselectHex(selectedHex);
map.hideDirections(selectedHex);
- if (o != Orientation.KEEP)
- selectedUnit.setRotation(o.r());
+
+ if (o == Orientation.KEEP)
+ o = entryZone.orientation;
+ map.setOnBoard(selectedUnit, selectedHex, o);
+
ctrl.hud.actionButtons.hide();
ctrl.hud.playerInfo.unitDock.show();
entryZone = null;