From 2e5814992288aea9358ca940a678dbf22d2e7fc6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Zurcher?= Date: Mon, 7 Dec 2015 13:09:18 +0100 Subject: get rid of orientation HexOverlay --- android/assets/data/hex-overlays.atlas | 33 ++++++++------------- android/assets/data/hex-overlays.png | Bin 153936 -> 149778 bytes assets/hex-overlays/05_exit.png | Bin 0 -> 3530 bytes assets/hex-overlays/05_orientation.png | Bin 691 -> 0 bytes assets/hex-overlays/10_exit.png | Bin 3530 -> 0 bytes core/src/ch/asynk/rustanddust/game/Hex.java | 3 +- core/src/ch/asynk/rustanddust/game/Map.java | 2 -- .../asynk/rustanddust/game/states/StateBreak.java | 2 -- .../asynk/rustanddust/game/states/StateRotate.java | 2 -- 9 files changed, 14 insertions(+), 28 deletions(-) create mode 100644 assets/hex-overlays/05_exit.png delete mode 100644 assets/hex-overlays/05_orientation.png delete mode 100644 assets/hex-overlays/10_exit.png diff --git a/android/assets/data/hex-overlays.atlas b/android/assets/data/hex-overlays.atlas index 0d424ff..f2a929b 100644 --- a/android/assets/data/hex-overlays.atlas +++ b/android/assets/data/hex-overlays.atlas @@ -6,78 +6,71 @@ filter: Nearest,Nearest repeat: none 00_fog rotate: false - xy: 304, 288 + xy: 2, 2 size: 190, 217 orig: 190, 217 offset: 0, 0 index: -1 01_select rotate: false - xy: 496, 288 + xy: 304, 265 size: 190, 217 orig: 190, 217 offset: 0, 0 index: -1 02_area rotate: false - xy: 688, 288 + xy: 496, 265 size: 190, 217 orig: 190, 217 offset: 0, 0 index: -1 03_move rotate: false - xy: 880, 391 + xy: 880, 368 size: 100, 114 orig: 100, 114 offset: 0, 0 index: -1 04_directions rotate: false - xy: 2, 244 + xy: 2, 221 size: 300, 261 orig: 300, 261 offset: 0, 0 index: -1 -05_orientation +05_exit rotate: false - xy: 2, 2 - size: 230, 240 - orig: 230, 240 + xy: 541, 149 + size: 100, 114 + orig: 100, 114 offset: 0, 0 index: -1 06_objective rotate: false - xy: 234, 25 + xy: 688, 265 size: 190, 217 orig: 190, 217 offset: 0, 0 index: -1 07_hold_objective rotate: false - xy: 426, 69 + xy: 194, 2 size: 190, 217 orig: 190, 217 offset: 0, 0 index: -1 08_objective_ge rotate: false - xy: 618, 185 + xy: 386, 162 size: 153, 101 orig: 153, 101 offset: 0, 0 index: -1 09_objective_us rotate: false - xy: 618, 85 + xy: 386, 62 size: 153, 98 orig: 153, 98 offset: 0, 0 index: -1 -10_exit - rotate: false - xy: 773, 172 - size: 100, 114 - orig: 100, 114 - offset: 0, 0 - index: -1 diff --git a/android/assets/data/hex-overlays.png b/android/assets/data/hex-overlays.png index b5cbe69..90334d2 100644 Binary files a/android/assets/data/hex-overlays.png and b/android/assets/data/hex-overlays.png differ diff --git a/assets/hex-overlays/05_exit.png b/assets/hex-overlays/05_exit.png new file mode 100644 index 0000000..8aacfd9 Binary files /dev/null and b/assets/hex-overlays/05_exit.png differ diff --git a/assets/hex-overlays/05_orientation.png b/assets/hex-overlays/05_orientation.png deleted file mode 100644 index 2b1d06d..0000000 Binary files a/assets/hex-overlays/05_orientation.png and /dev/null differ diff --git a/assets/hex-overlays/10_exit.png b/assets/hex-overlays/10_exit.png deleted file mode 100644 index 8aacfd9..0000000 Binary files a/assets/hex-overlays/10_exit.png and /dev/null differ diff --git a/core/src/ch/asynk/rustanddust/game/Hex.java b/core/src/ch/asynk/rustanddust/game/Hex.java index e6cab3f..76d224f 100644 --- a/core/src/ch/asynk/rustanddust/game/Hex.java +++ b/core/src/ch/asynk/rustanddust/game/Hex.java @@ -29,12 +29,11 @@ public class Hex extends Tile public static final int AREA = 2; public static final int MOVE = 3; public static final int DIRECTIONS = 4; - public static final int ORIENTATION = 5; + public static final int EXIT = 5; public static final int OBJECTIVE = 6; public static final int OBJECTIVE_HOLD = 7; public static final int OBJECTIVE_GE = 8; public static final int OBJECTIVE_US = 9; - public static final int EXIT = 10; public Terrain terrain; public int roads; diff --git a/core/src/ch/asynk/rustanddust/game/Map.java b/core/src/ch/asynk/rustanddust/game/Map.java index 5ce653e..def903f 100644 --- a/core/src/ch/asynk/rustanddust/game/Map.java +++ b/core/src/ch/asynk/rustanddust/game/Map.java @@ -614,8 +614,6 @@ public abstract class Map extends Board implements MoveToAnimationCb, ObjectiveS public void hideMove(Hex hex) { enableOverlayOn(hex, Hex.MOVE, false); } public void showDirections(Hex hex) { enableOverlayOn(hex, Hex.DIRECTIONS, true); } public void hideDirections(Hex hex) { enableOverlayOn(hex, Hex.DIRECTIONS, false); } - public void showOrientation(Hex hex, Orientation o) { enableOverlayOn(hex, Hex.ORIENTATION, o, true); } - public void hideOrientation(Hex hex) { enableOverlayOn(hex, Hex.ORIENTATION, false); } public void showExit(Hex hex) { enableOverlayOn(hex, Hex.EXIT, true); } public void hideExit(Hex hex) { enableOverlayOn(hex, Hex.EXIT, false); } diff --git a/core/src/ch/asynk/rustanddust/game/states/StateBreak.java b/core/src/ch/asynk/rustanddust/game/states/StateBreak.java index f1e40f6..89a9224 100644 --- a/core/src/ch/asynk/rustanddust/game/states/StateBreak.java +++ b/core/src/ch/asynk/rustanddust/game/states/StateBreak.java @@ -25,7 +25,6 @@ public class StateBreak extends StateCommon map.hideBreakUnits(); map.hideMove(to); map.hideDirections(to); - map.hideOrientation(to); if (activeUnit != null) map.hideMove(activeUnit.getHex()); } @@ -66,7 +65,6 @@ public class StateBreak extends StateCommon if (ctrl.cfg.mustValidate) { map.hideDirections(to); - map.showOrientation(to, o); ctrl.hud.actionButtons.show(Buttons.DONE.b); } else { doRotation(o); diff --git a/core/src/ch/asynk/rustanddust/game/states/StateRotate.java b/core/src/ch/asynk/rustanddust/game/states/StateRotate.java index 4d91740..5a10471 100644 --- a/core/src/ch/asynk/rustanddust/game/states/StateRotate.java +++ b/core/src/ch/asynk/rustanddust/game/states/StateRotate.java @@ -44,7 +44,6 @@ public class StateRotate extends StateCommon map.unselectHex(activeUnit.getHex()); map.hidePath(to); map.hideDirections(to); - map.hideOrientation(to); map.pathBuilder.clear(); to = null; } @@ -101,7 +100,6 @@ public class StateRotate extends StateCommon if (ctrl.cfg.mustValidate) { map.hideDirections(to); - map.showOrientation(to, o); ctrl.hud.actionButtons.show(Buttons.DONE.b | ((ctrl.cfg.canCancel) ? Buttons.ABORT.b : 0)); } else { execute(); -- cgit v1.1-2-g2b99