Package com.takenoko.actions.improvement
Class ApplyImprovementFromInventoryAction
java.lang.Object
com.takenoko.actions.improvement.ApplyImprovementAction
com.takenoko.actions.improvement.ApplyImprovementFromInventoryAction
- All Implemented Interfaces:
Action
,DefaultAction
public class ApplyImprovementFromInventoryAction
extends ApplyImprovementAction
implements DefaultAction
Action to apply an improvement from the inventory.
-
Field Summary
FieldsFields inherited from class com.takenoko.actions.improvement.ApplyImprovementAction
positionVector
-
Constructor Summary
ConstructorsConstructorDescriptionApplyImprovementFromInventoryAction
(ImprovementType improvementType, PositionVector positionVector) -
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
canBePlayed
(Board board, BotState botState) boolean
execute
(Board board, BotManager botManager) Executes the action on the board and the bot manager.int
hashCode()
-
Field Details
-
improvementType
-
-
Constructor Details
-
ApplyImprovementFromInventoryAction
public ApplyImprovementFromInventoryAction(ImprovementType improvementType, PositionVector positionVector)
-
-
Method Details
-
execute
Description copied from interface:Action
Executes the action on the board and the bot manager.- Specified by:
execute
in interfaceAction
- Overrides:
execute
in classApplyImprovementAction
- Parameters:
board
- the boardbotManager
- the bot manager- Returns:
- the action result
-
canBePlayed
-
equals
- Overrides:
equals
in classApplyImprovementAction
-
hashCode
public int hashCode()- Overrides:
hashCode
in classApplyImprovementAction
-