Devlog: Chess Game Design
After a long and tough development cycle I finally got the chess board to work! It was like climbing a mountain just getting all the pieces to show up on the board correctly.. The hard work paid off. Everything works as it should: all the pieces are the size and their positions are accurate.
Architecture and Class Breakdown
My game code uses object-oriented programming. The structure is broken down into two parts:
Piece Classes: Classes for each chess piece. Each piece has its movement rules, boundary checks and capture rules. For example Pawns, Knights, Bishops, Rooks, Queens and Kings all have rules.
The Board Class: The Board class the most difficult by far. It took a lot of time to get all the pieces to show up in the places.
Dealing with Layout
The development process had alignment problems. First I had to figure out the correct board size for screen resolutions. It was a headache. If there was any space around the grid it broke the rendering math. That made it hard to calculate coordinates.
When the board grid was fixed the piece sizes looked weird. I tried to scale the vector assets. It didn’t work. I decided to take an approach. I took a screenshot of chess pieces cut them into sprites and used those. It worked.
Future Plans (next devlog - finishing touches):
Next I’m planning on fitting the theme better with using chess puzzles (It just fits the theme more, like a puzzle fits with the other mini games more) Then I want to connect the minigames together like after finishing one level you go to next.