From 02d7ef1dd8a4464c772c0855ad9629066405c1a4 Mon Sep 17 00:00:00 2001 From: Daniel Grigencha Date: Sun, 1 Dec 2024 23:28:50 +0100 Subject: [PATCH] Updated 'ChoosePieceState' class. Updated the 'ChoosePieceState' to work correctly as a state automaton. --- .../automaton/game/turn/ChoosePieceState.java | 47 ++++++++++++++++++- 1 file changed, 46 insertions(+), 1 deletion(-) diff --git a/Projekte/mdga/model/src/main/java/pp/mdga/server/automaton/game/turn/ChoosePieceState.java b/Projekte/mdga/model/src/main/java/pp/mdga/server/automaton/game/turn/ChoosePieceState.java index 0ee5f273..63479370 100644 --- a/Projekte/mdga/model/src/main/java/pp/mdga/server/automaton/game/turn/ChoosePieceState.java +++ b/Projekte/mdga/model/src/main/java/pp/mdga/server/automaton/game/turn/ChoosePieceState.java @@ -49,12 +49,57 @@ public void exit() { /** * This method will be used to return currentState attribute of ChoosePieceState class. * - * @return currentState as a + * @return currentState as a ChoosePieceAutomatonState object. */ public ChoosePieceAutomatonState getCurrentState() { return this.currentState; } + /** + * This method will be used to return noPieceState attribute of ChoosePieceState class. + * + * @return noPieceState as a NoOPieceState object. + */ + public NoPieceState getNoPieceState() { + return this.noPieceState; + } + + /** + * This method will be used to return noTurnState attribute of ChoosePieceState class. + * + * @return noTurnState as a NoTurnState object. + */ + public NoTurnState getNoTurnState() { + return this.noTurnState; + } + + /** + * This method will be used to return waitingPieceState attribute of ChoosePieceState class. + * + * @return waitingPieceState as a WaitingPieceState object. + */ + public WaitingPieceState getWaitingPieceState() { + return this.waitingPieceState; + } + + /** + * This method will be used to return startPieceState attribute of ChoosePieceState class. + * + * @return startPieceState as a StartPieceState object. + */ + public StartPieceState getStartPieceState() { + return this.startPieceState; + } + + /** + * This method will be used to return selectPieceState attribute of ChoosePieceState class. + * + * @return selectPieceState as a SelectPieceState object. + */ + public SelectPieceState getSelectPieceState() { + return this.selectPieceState; + } + /** * This method will be used to set currentState attribute of ChoosePieceState class to the given state parameter. * In Addition, the currentState will be exited, changed and entered.