Examples of MoveValidator


Examples of games.stendhal.server.entity.mapstuff.game.movevalidator.MoveValidator

   * @param token  moved token
   */
  public void onTokenMoved(Player player, BoardToken token) {
    int xIndex = getXIndex(token.getX());
    int yIndex = getYIndex(token.getY());
    MoveValidator validator = new TicTacToeMovementValidatorChain();
    if (!validator.validate(this, player, token, xIndex, yIndex)) {
      token.undoMove();
      return;
    }
 
    completeMove(xIndex, yIndex, token);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.