Class PlaceTileAction

java.lang.Object
com.takenoko.actions.tile.PlaceTileAction
All Implemented Interfaces:
Action
Direct Known Subclasses:
PlaceTileWithImprovementAction

public class PlaceTileAction extends Object implements Action
This class represents the action of placing a tile on the board.
  • Field Details

    • tile

      protected final Tile tile
    • positionVector

      private final PositionVector positionVector
  • Constructor Details

    • PlaceTileAction

      public PlaceTileAction(Tile tile, PositionVector positionVector)
      Constructor for the PlaceTileAction class.
      Parameters:
      tile - the tile to place
      positionVector - the position vector where to place the tile
  • Method Details

    • execute

      public ActionResult execute(Board board, BotManager botManager)
      Place the tile on the board and display a message.
      Specified by:
      execute in interface Action
      Parameters:
      board - the board
      botManager - the bot manager
      Returns:
      the action result
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object