diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2016-04-22 11:13:12 +0200 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2016-04-22 11:13:12 +0200 |
commit | 366c2fdda57bf6b8dac4980c7de51d189296630c (patch) | |
tree | 3a1e68cd262ff6fd0f25c3665f860b2b8f107924 /core/src/ch/asynk | |
parent | 2909874fec33a83a70310d9aabe201c2d0d858b1 (diff) | |
download | RustAndDust-366c2fdda57bf6b8dac4980c7de51d189296630c.zip RustAndDust-366c2fdda57bf6b8dac4980c7de51d189296630c.tar.gz |
Unit: do not substract road march bonus to a 0 cost move
Diffstat (limited to 'core/src/ch/asynk')
-rw-r--r-- | core/src/ch/asynk/rustanddust/game/Unit.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/src/ch/asynk/rustanddust/game/Unit.java b/core/src/ch/asynk/rustanddust/game/Unit.java index 836ac93..a55c7b3 100644 --- a/core/src/ch/asynk/rustanddust/game/Unit.java +++ b/core/src/ch/asynk/rustanddust/game/Unit.java @@ -296,7 +296,7 @@ public class Unit extends HeadedPawn public void move() { int cost = move.cost; - if (move.roadMarch) { + if ((cost > 0) && move.roadMarch) { cost -= getRoadMarchBonus(); if (cost < 1) cost = 1; } |