
Stopwatch + ChessBoard
Where I left off last time the stop watch wouldn’t work that much and just Kept Increasing the number and not working as a timer
I’ve decided to work on a chess project where I can use Ai to help me solve problems if I encounter them
I first started with making my project in VS Code and called it Chessboard. Java

The first line defines the Chessboard class
The new piece [8][8] Represents the total 16 pieces the player starts with each row having eight on each
The setup pieces calls for the pieces to sit in their position
since each piece Represents a spot on the chess board so we can Represents this with an object by making a new file
called Piece. Java to put the pieces

The piece.java is responsible for the spot on the chess so thats why this file is location related
this file is responsible for the pieces moving and how they look aka their color
The codes in line 2 and 3 defines the posittion and color
the returns color and postions puts them on the screen where you can see them
the setPosition gets access and updates the piece’s location
the isValidMove is there to make sure the rules of chess is being met and the player is not going all over the place

Leave a Reply