From d314ab2da61edd9326f9d364ea439964e6a00a80 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Zurcher?= Date: Tue, 29 Mar 2016 16:49:11 +0200 Subject: Map4Orders: add prepareReplayLastTurn() --- core/src/ch/asynk/rustanddust/game/map/Map4Orders.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/core/src/ch/asynk/rustanddust/game/map/Map4Orders.java b/core/src/ch/asynk/rustanddust/game/map/Map4Orders.java index 269f0e7..ff0e01f 100644 --- a/core/src/ch/asynk/rustanddust/game/map/Map4Orders.java +++ b/core/src/ch/asynk/rustanddust/game/map/Map4Orders.java @@ -133,6 +133,15 @@ public abstract class Map4Orders extends Map3Animations } } + public void prepareReplayLastTurn() + { + int s = orders.size(); + while (s > 0) { + s -= 1; + replayOrders.add(orders.get(s)); + } + } + public Order stepReplay() { int s = replayOrders.size(); -- cgit v1.1-2-g2b99