diff options
Diffstat (limited to 'core')
-rw-r--r-- | core/src/ch/asynk/tankontank/game/Ctrl.java | 1 | ||||
-rw-r--r-- | core/src/ch/asynk/tankontank/game/Map.java | 9 | ||||
-rw-r--r-- | core/src/ch/asynk/tankontank/game/battles/BattleTest.java | 1 |
3 files changed, 10 insertions, 1 deletions
diff --git a/core/src/ch/asynk/tankontank/game/Ctrl.java b/core/src/ch/asynk/tankontank/game/Ctrl.java index 09b5c5d..24f496c 100644 --- a/core/src/ch/asynk/tankontank/game/Ctrl.java +++ b/core/src/ch/asynk/tankontank/game/Ctrl.java @@ -62,6 +62,7 @@ public class Ctrl implements Disposable this.map = battle.getMap(); battle.setup(this, map); + this.map.init(); this.player = battle.getPlayer(); this.opponent = battle.opponent(player); diff --git a/core/src/ch/asynk/tankontank/game/Map.java b/core/src/ch/asynk/tankontank/game/Map.java index 3b1a5b4..625f0f2 100644 --- a/core/src/ch/asynk/tankontank/game/Map.java +++ b/core/src/ch/asynk/tankontank/game/Map.java @@ -306,7 +306,12 @@ public abstract class Map extends Board implements MoveToAnimationCb, ObjectiveS return r; } - // STATES ENTRY -> + // Ctrl Methods + + public void init() + { + actionDone(); + } public void turnDone() { @@ -325,6 +330,8 @@ public abstract class Map extends Board implements MoveToAnimationCb, ObjectiveS } } + // STATES ENTRY -> + public boolean enterBoard(Unit unit, Hex to, int allowedMoves) { Orientation entry = findBestEntry(unit, to, allowedMoves); diff --git a/core/src/ch/asynk/tankontank/game/battles/BattleTest.java b/core/src/ch/asynk/tankontank/game/battles/BattleTest.java index f2f7fd4..e844d15 100644 --- a/core/src/ch/asynk/tankontank/game/battles/BattleTest.java +++ b/core/src/ch/asynk/tankontank/game/battles/BattleTest.java @@ -122,6 +122,7 @@ public class BattleTest extends BattleCommon setUnit(map, usPlayer, UnitId.US_INFANTRY, 5, 3, Orientation.NORTH_WEST, usExit); setUnit(map, usPlayer, UnitId.US_AT_GUN, 10, 3, Orientation.SOUTH, usExit); usPlayer.turnEnd(); + map.init(); map.turnDone(); } } |