Class MovementSourceIsHomeValidator

java.lang.Object
games.stendhal.server.entity.mapstuff.game.movevalidator.MovementSourceIsHomeValidator
All Implemented Interfaces:
MoveValidator

public class MovementSourceIsHomeValidator extends Object implements MoveValidator
Was this item pulled from its home place?
Author:
hendrik
  • Constructor Details

    • MovementSourceIsHomeValidator

      public MovementSourceIsHomeValidator()
  • Method Details

    • validate

      public boolean validate(GameBoard board, Player player, BoardToken token, int xIndex, int yIndex)
      Description copied from interface: MoveValidator
      validates a move
      Specified by:
      validate in interface MoveValidator
      Parameters:
      board - the game board
      player - player doing the move
      token - the token which was moved
      xIndex - target x-index
      yIndex - target y-index
      Returns:
      true, if the move is valid, false otherwise