Class MoveSquarePrevAction<G extends GameObject<G,​A,​R>,​A extends MapArchObject<A>,​R extends Archetype<G,​A,​R>>

    • Constructor Detail

      • MoveSquarePrevAction

        public MoveSquarePrevAction​(@NotNull
                                    @NotNull SelectedSquareModel<G,​A,​R> selectedSquareModel,
                                    @Nullable
                                    @Nullable MapManager<G,​A,​R> mapManager)
        Creates a new instance.
        Parameters:
        selectedSquareModel - the selected square model to update
        mapManager - the map manager to track or null
    • Method Detail

      • moveSquarePrev

        @ActionMethod
        public void moveSquarePrev()
        Action method that selects the previous game object.
      • doAction

        protected boolean doAction​(boolean performAction,
                                   @Nullable
                                   G gameObject)
        Description copied from class: AbstractMoveSquareAction
        Executes the action.
        Specified by:
        doAction in class AbstractMoveSquareAction<G extends GameObject<G,​A,​R>,​A extends MapArchObject<A>,​R extends Archetype<G,​A,​R>>
        Parameters:
        performAction - whether the action should be performed
        gameObject - the current game object or null if none is selected
        Returns:
        whether the action was or can be performed