summaryrefslogtreecommitdiffstats
path: root/core/src/ch/asynk
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2015-12-07 16:33:36 +0100
committerJérémy Zurcher <jeremy@asynk.ch>2015-12-07 16:33:36 +0100
commit9bf546c98ce624417f12765437491070de1ddea2 (patch)
treed60ceb9ea20098b5ce5edeef61807fc14b431ebc /core/src/ch/asynk
parent850611c14531be449fb2d1c71815eea44bc982df (diff)
downloadRustAndDust-9bf546c98ce624417f12765437491070de1ddea2.zip
RustAndDust-9bf546c98ce624417f12765437491070de1ddea2.tar.gz
Map: pathsToggleHex(Hex) swallows togglePathOverlay(Hex)
Diffstat (limited to 'core/src/ch/asynk')
-rw-r--r--core/src/ch/asynk/rustanddust/game/Map.java8
-rw-r--r--core/src/ch/asynk/rustanddust/game/states/StateMove.java1
2 files changed, 2 insertions, 7 deletions
diff --git a/core/src/ch/asynk/rustanddust/game/Map.java b/core/src/ch/asynk/rustanddust/game/Map.java
index 6a5c8a9..d11525a 100644
--- a/core/src/ch/asynk/rustanddust/game/Map.java
+++ b/core/src/ch/asynk/rustanddust/game/Map.java
@@ -180,6 +180,8 @@ public abstract class Map extends Board implements MoveToAnimationCb, ObjectiveS
public int pathsToggleHex(Hex hex)
{
+ boolean enable = !hex.isOverlayEnabled(Hex.MOVE);
+ enableOverlayOn(hex, Hex.MOVE, enable);
return paths.toggleCtrlTile(hex);
}
@@ -517,12 +519,6 @@ public abstract class Map extends Board implements MoveToAnimationCb, ObjectiveS
// SHOW / HIDE
- public void togglePathOverlay(Hex hex)
- {
- boolean enable= !hex.isOverlayEnabled(Hex.MOVE);
- enableOverlayOn(hex, Hex.MOVE, enable);
- }
-
public enum UnitType
{
MOVEABLE,
diff --git a/core/src/ch/asynk/rustanddust/game/states/StateMove.java b/core/src/ch/asynk/rustanddust/game/states/StateMove.java
index 762c476..6410c67 100644
--- a/core/src/ch/asynk/rustanddust/game/states/StateMove.java
+++ b/core/src/ch/asynk/rustanddust/game/states/StateMove.java
@@ -173,7 +173,6 @@ public class StateMove extends StateCommon
//
} else {
map.pathsHide();
- map.togglePathOverlay(hex);
s = map.pathsToggleHex(hex);
map.pathsShow();
}