diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2016-03-29 14:15:56 +0200 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2016-03-29 14:15:56 +0200 |
commit | 96f927c4dbcda4b0964f0bc7eac1c31730b943cb (patch) | |
tree | 218ae64f1afd9d6769166e85b68579d38fd17a44 /core | |
parent | 5212023ffbec3690d51fd9d1544321e4669bd964 (diff) | |
download | RustAndDust-96f927c4dbcda4b0964f0bc7eac1c31730b943cb.zip RustAndDust-96f927c4dbcda4b0964f0bc7eac1c31730b943cb.tar.gz |
Ctrl: replayLastOrder -> synched
Diffstat (limited to 'core')
-rw-r--r-- | core/src/ch/asynk/rustanddust/game/Ctrl.java | 6 | ||||
-rw-r--r-- | core/src/ch/asynk/rustanddust/game/ctrl/Solo.java | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/core/src/ch/asynk/rustanddust/game/Ctrl.java b/core/src/ch/asynk/rustanddust/game/Ctrl.java index e1f63b4..4303ed7 100644 --- a/core/src/ch/asynk/rustanddust/game/Ctrl.java +++ b/core/src/ch/asynk/rustanddust/game/Ctrl.java @@ -38,7 +38,7 @@ public abstract class Ctrl implements Disposable public boolean blockMap; public boolean blockHud; private Hex touchedHex; - protected boolean replayLastOrder; + protected boolean synched; private final State selectState; private final State pathState; @@ -84,7 +84,7 @@ public abstract class Ctrl implements Disposable this.blockMap = false; this.blockHud = false; this.touchedHex = null; - this.replayLastOrder = false; + this.synched = false; this.selectState = new StateSelect(); this.pathState = new StateMove(); @@ -111,7 +111,7 @@ public abstract class Ctrl implements Disposable setState(battle.getState()); - if (replayLastOrder) { + if (!synched) { map.prepareReplayLastAction(); setState(StateType.REPLAY); } else { diff --git a/core/src/ch/asynk/rustanddust/game/ctrl/Solo.java b/core/src/ch/asynk/rustanddust/game/ctrl/Solo.java index 20d70b1..c9de875 100644 --- a/core/src/ch/asynk/rustanddust/game/ctrl/Solo.java +++ b/core/src/ch/asynk/rustanddust/game/ctrl/Solo.java @@ -25,14 +25,14 @@ public class Solo extends Ctrl battle.getPlayer().id = me; battle.getOpponent().id = other; battle.initialDeployment(); - replayLastOrder = false; + synched = true; } else { GameRecord r = game.db.loadGame(gameId); if (r != null) { load(Marshal.Mode.STATE, r.state); load(Marshal.Mode.ORDERS, r.orders); battle.getMap().clearMarshalUnits(); - replayLastOrder = !r.synched; + synched = r.synched; r.dispose(); } else System.err.println("TODO : null GameRecord"); |