checked board
This commit is contained in:
parent
1d9958b398
commit
5fafd75e4f
|
|
@ -4,28 +4,36 @@ import java.util.ArrayList;
|
|||
|
||||
public class Board {
|
||||
|
||||
private int width;
|
||||
private int height;
|
||||
private ArrayList<Piece> pieces;
|
||||
private int turnNumber;
|
||||
private boolean turnWhite;
|
||||
|
||||
public Board(int colNum, int lineNum) {
|
||||
//TODO
|
||||
this.width = colNum;
|
||||
this.height = lineNum;
|
||||
this.pieces = new ArrayList<>();
|
||||
}
|
||||
|
||||
public int getWidth() {
|
||||
//TODO
|
||||
return 0;
|
||||
|
||||
return width;
|
||||
}
|
||||
|
||||
public int getHeight() {
|
||||
//TODO
|
||||
return 0;
|
||||
|
||||
return height;// the above part set the checked board
|
||||
}
|
||||
|
||||
public int getTurnNumber() {
|
||||
//TODO
|
||||
return 0;
|
||||
return this.turnNumber;
|
||||
}
|
||||
|
||||
public boolean isTurnWhite() {
|
||||
//TODO
|
||||
return false;
|
||||
return this.turnWhite;
|
||||
}
|
||||
|
||||
public void setPiece(boolean isWhite, PieceType type, int x, int y) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue