public class Queen extends Piece { public Queen(Cell cell, Color color) { super(cell, color); } @Override public boolean isValidMove(Cell c, Cell board[][]) { return (( (this.getCell().getCol() == c.getCol()) || (this.getCell().getRow() == c.getRow()) || (Math.abs(this.getCell().getCol() - c.getCol()) == Math.abs(this.getCell().getRow() - c.getRow())) ) && c.isEmpty() ); } }