|
| | Pawn (int x, int y, PieceColor color) |
| |
| boolean | makeMove (ChessBoard chessBoard, int moveToX, int moveToY) |
| |
| boolean | isValidMove (ChessBoard chessBoard, int moveToX, int moveToY) |
| |
| void | replacePawn (ChessBoard chessBoard) |
| |
| char | boardCharacter () |
| |
| | ChessPiece (int x, int y, PieceColor color) |
| |
| boolean | makeMove (ChessBoard chessBoard, int moveToX, int moveToY) |
| |
| char | boardCharacter () |
| |
| boolean | isValidMove (ChessBoard chessBoard, int moveToX, int moveToY) |
| |
| int [] | getCoordinates () |
| |
| PieceColor | getColor () |
| |
◆ Pawn()
| Pawn.Pawn |
( |
int |
x, |
|
|
int |
y, |
|
|
PieceColor |
color |
|
) |
| |
|
inline |
- Parameters
-
| x | coordinate |
| y | coordinate |
| color | of piece |
◆ boardCharacter()
| char Pawn.boardCharacter |
( |
| ) |
|
|
inline |
character representation on board
- Returns
◆ isValidMove()
| boolean Pawn.isValidMove |
( |
ChessBoard |
chessBoard, |
|
|
int |
moveToX, |
|
|
int |
moveToY |
|
) |
| |
|
inline |
- Parameters
-
| chessBoard | we are playing on |
| moveToX | where we want piece to move x |
| moveToY | where we want piece to move y |
- Returns
- whether legal move
◆ makeMove()
| boolean Pawn.makeMove |
( |
ChessBoard |
chessBoard, |
|
|
int |
moveToX, |
|
|
int |
moveToY |
|
) |
| |
|
inline |
- Parameters
-
| chessBoard | we are playing on |
| moveToX | where we are moving piece to |
| moveToY | where we are moving piece to |
- Returns
- whether move was made
◆ replacePawn()
- Parameters
-
| chessBoard | chessboard we are playing on changes pawn we are playing with either Queen (1) or Knight (2) from user input |
The documentation for this class was generated from the following file: