java.lang.Object
antichess.Piece
antichess.Knight
- public class Knight
- extends Piece
This class contains the rules that apply to Knight.
| Fields inherited from class antichess.Piece |
BISHOP, BLACK, BLUE, dcol, drow, EMPTY, FIRSTCOLOR, FIRSTPIECE, KING, KNIGHT, LASTCOLOR, LASTPIECE, offsets, PAWN, PIECECOUNT, PIECEVALUE, playerColorString, QUEEN, RED, ROOK, slide, WHITE |
|
Constructor Summary |
Knight(char letter,
Board b,
int col,
int row,
int color)
Creates a new piece. |
| Methods inherited from class antichess.Piece |
addEmpty, canAttackLocation, equals, equals, getAllValidMoves, getBoard, getChar, getCol, getColor, getLastCol, getLastRow, getMoved, getNormalMoves, getOpponentColor, getOpponentColor, getOtherMoves, getRow, getStandardValidMoves, getSwitchMoves, getType, getValidMoves, getValidMovesNormalChess, isGameOver, isGameOver, isGameOverNormalChess, isLoseNormalChess, isTie, isTie, isTieNormalChess, isValidMove, isWin, isWin, kingInCheck, makeCaptureMove, makeGeneratedMove, makeGeneratedMove, makeMove, makeMove, makeMove, makeMove, makeOtherMove, setBoard, setColor, setLastLocation, setLocation, setMoved, swapPieces, toString, undoCaptureMove, undoMove, undoOtherMove |
Knight
public Knight(char letter,
Board b,
int col,
int row,
int color)
- Creates a new piece.
copyPiece
public Piece copyPiece(Board b)
- Creates a copy to a new board
- Overrides:
copyPiece in class Piece