summaryrefslogtreecommitdiffstats
path: root/core/src/ch/asynk/tankontank/game
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2014-11-17 17:45:37 +0100
committerJérémy Zurcher <jeremy@asynk.ch>2014-11-17 17:45:37 +0100
commita1f6fb835be0b32ec3023a92ae28be6872ae14a2 (patch)
treecc485fb5248c949e5e8534a1784e29584c8c2e47 /core/src/ch/asynk/tankontank/game
parent16a272a9c485aec8687d2960de47af1a683c0f12 (diff)
downloadRustAndDust-a1f6fb835be0b32ec3023a92ae28be6872ae14a2.zip
RustAndDust-a1f6fb835be0b32ec3023a92ae28be6872ae14a2.tar.gz
Ctrl: do correct calls to battle.getPlayer(...)
Diffstat (limited to 'core/src/ch/asynk/tankontank/game')
-rw-r--r--core/src/ch/asynk/tankontank/game/Ctrl.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/core/src/ch/asynk/tankontank/game/Ctrl.java b/core/src/ch/asynk/tankontank/game/Ctrl.java
index 16a6a57..4ec8606 100644
--- a/core/src/ch/asynk/tankontank/game/Ctrl.java
+++ b/core/src/ch/asynk/tankontank/game/Ctrl.java
@@ -53,8 +53,8 @@ public class Ctrl implements Disposable
this.cfg = game.config;
game.ctrl = this;
- this.player = battle.getPlayer(true, false);
- this.opponent = battle.getPlayer(false, false);
+ this.player = battle.getPlayer(true, true);
+ this.opponent = battle.getPlayer(false, true);
this.map = battle.getMap();
battle.setup(this, map);
@@ -121,10 +121,10 @@ public class Ctrl implements Disposable
private void startPlayerTurn()
{
player.turnStart();
+ hud.update();
hud.notify(player.getName() + "'s turn", 2, Position.MIDDLE_CENTER, true);
if (battle.getReinforcement(this))
hud.notify("You have reinforcement", 2, Position.MIDDLE_CENTER, true);
- hud.update();
setState(battle.getState(player));
}
@@ -183,8 +183,8 @@ public class Ctrl implements Disposable
if (player.isDeploymentDone() && opponent.isDeploymentDone()) {
endPlayerTurn();
- player = battle.getPlayer(true, true);
- opponent = battle.getPlayer(false, true);
+ player = battle.getPlayer(true, false);
+ opponent = battle.getPlayer(false, false);
startPlayerTurn();
} else
switchPlayer();