Class Triton
java.lang.Object
it.polimi.ingsw.server.controller.god.God
it.polimi.ingsw.server.controller.god.Triton
public class Triton extends God
Represents the card of the God Triton.
Allows to follow the instructions and to apply the effect of this specific God.
-
Field Summary
Fields Modifier and Type Field Description java.lang.Stringdescription -
Constructor Summary
Constructors Constructor Description Triton(GodController godController) -
Method Summary
Modifier and Type Method Description voidevolveTurn(Worker worker)The evolution of the turn for the player that holds the Triton God card is different from the abstract implementation.java.lang.StringgetDescription()GodControllergetGodController()Methods inherited from class it.polimi.ingsw.server.controller.god.God
build, move, toString, updateBuildMap, updateMoveMap, win
-
Field Details
-
description
public final java.lang.String description- See Also:
- Constant Field Values
-
-
Constructor Details
-
Method Details
-
evolveTurn
public void evolveTurn(Worker worker) throws UnableToMoveException, UnableToBuildException, WinExceptionThe evolution of the turn for the player that holds the Triton God card is different from the abstract implementation. The player, if the selected worker stands on the perimeter of the board, can choose if he wants to move again his worker.- Overrides:
evolveTurnin classGod- Parameters:
worker- Selected worker that will act in the current turn.- Throws:
UnableToBuildException- The worker isn't allowed to build anywhere.UnableToMoveException- The worker isn't allowed to move anywhere.WinException- The worker has reached the third level of a building and so wins the game.
-
getGodController
- Overrides:
getGodControllerin classGod
-
getDescription
public java.lang.String getDescription()- Specified by:
getDescriptionin classGod
-