From 40363ea5a2e5fbc96569bc97fce0ca207f05f0e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Zurcher?= Date: Thu, 13 Nov 2014 23:43:55 +0100 Subject: Ctrl: endPlayerTurn() -> abortPlayerTurn() --- core/src/ch/asynk/tankontank/game/Ctrl.java | 6 ++++++ core/src/ch/asynk/tankontank/game/Hud.java | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/core/src/ch/asynk/tankontank/game/Ctrl.java b/core/src/ch/asynk/tankontank/game/Ctrl.java index 8c54a72..4fe91f1 100644 --- a/core/src/ch/asynk/tankontank/game/Ctrl.java +++ b/core/src/ch/asynk/tankontank/game/Ctrl.java @@ -230,4 +230,10 @@ public class Ctrl implements Disposable { game.setScreen(new OptionsScreen(game)); } + + public void abortPlayerTurn() + { + state.abort(); + swicthPlayer(); + } } diff --git a/core/src/ch/asynk/tankontank/game/Hud.java b/core/src/ch/asynk/tankontank/game/Hud.java index f39a1e7..5b1ae3b 100644 --- a/core/src/ch/asynk/tankontank/game/Hud.java +++ b/core/src/ch/asynk/tankontank/game/Hud.java @@ -162,7 +162,7 @@ public class Hud implements Disposable { case END_TURN: if (okCancel.ok) - ctrl.endPlayerTurn(); + ctrl.abortPlayerTurn(); okCancel.visible = false; break; case END_GAME: -- cgit v1.1-2-g2b99