diff options
-rw-r--r-- | core/src/ch/asynk/tankontank/game/Hex.java | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/core/src/ch/asynk/tankontank/game/Hex.java b/core/src/ch/asynk/tankontank/game/Hex.java index b586515..84b2a34 100644 --- a/core/src/ch/asynk/tankontank/game/Hex.java +++ b/core/src/ch/asynk/tankontank/game/Hex.java @@ -113,6 +113,7 @@ public class Hex extends Tile terrainBonus = false; } + int tdef = 0; int def = u.def; switch(terrain) { case HILLS: @@ -124,14 +125,14 @@ public class Hex extends Tile if (u.type != Unit.UnitType.HARD_TARGET) def = u.cdef; if (terrainBonus) - def += 1; + tdef = 1; break; default: def = ((Unit) target).def; break; } - System.err.println(" >= " + def); - return def; + System.err.println(" >= " + def + " + " + tdef); + return (def + tdef); } } |