From 342a78a5a458f2606300723c91badc23e4db81b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Zurcher?= Date: Sat, 1 Nov 2014 12:47:44 +0100 Subject: Map: toggleAttackAssist: return boolean --- core/src/ch/asynk/tankontank/game/Map.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/core/src/ch/asynk/tankontank/game/Map.java b/core/src/ch/asynk/tankontank/game/Map.java index 06d0b8a..26a7e06 100644 --- a/core/src/ch/asynk/tankontank/game/Map.java +++ b/core/src/ch/asynk/tankontank/game/Map.java @@ -144,16 +144,18 @@ public abstract class Map extends Board return s; } - public void toggleAttackAssist(Unit unit) + public boolean toggleAttackAssist(Unit unit) { if (activatedPawns.contains(unit)) { activatedPawns.remove(unit); unit.hideAttack(); unit.showAttackAssist(); + return false; } else { activatedPawns.add(unit); unit.showAttack(); unit.hideAttackAssist(); + return true; } } -- cgit v1.1-2-g2b99