From eac3e6b04638127c8fa5c10d92e1c3bbf0bee421 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Zurcher?= Date: Fri, 22 Apr 2016 00:00:46 +0200 Subject: Unit: do not call setMoved if cost is 0 --- core/src/ch/asynk/rustanddust/game/Unit.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/ch/asynk/rustanddust/game/Unit.java b/core/src/ch/asynk/rustanddust/game/Unit.java index e415ee3..836ac93 100644 --- a/core/src/ch/asynk/rustanddust/game/Unit.java +++ b/core/src/ch/asynk/rustanddust/game/Unit.java @@ -304,7 +304,7 @@ public class Unit extends HeadedPawn if (cost > mpLeft) RustAndDust.debug("ERROR: Movement point exceeded: " + cost + "/" + mpLeft + " please report"); - if (move.isFinal()) + if ((cost > 0) && move.isFinal()) setMoved(); mpLeft -= cost; -- cgit v1.1-2-g2b99