ksquares
Introduction
KSquares is a KDE implementation of the game "squares"
Overview
The overall game is masterminded from KSquaresWindow. That class creates a KSquaresGame object which handles the game logic such as moving from player to player and tracking when points are scored. The information for each player is stored in KSquaresPlayer of which KSquaresGame has an array. When a KSquaresGame event occurs it emits a signal which is picked up by the KSquaresWindow and passed onto the GameBoardScene which is responsible for holding the information about the game board. The GameBoardScene emits signal when a line is drawn which passes via the KSquaresWindow back to KSquaresGame.
Layout of indices
In KSquaresGame, GameBoardScene and aiController there is a consistent indexing rule for accesing the tables.
For the list of squares and their owners, the indices simply count from left to right along the top row of the board, then along the second row etc.
For the list of lines and whether they're drawn, the indices count from left to right along the top row of horizontal lines, then (left to right) along the first row of vertical lines etc.
TODO
- Todo:
- A more obvious sign of where the computer player has moved
- Todo:
- Logo/initials/colour/etc. for players squares
- Todo:
- Themeable game board. Subclass all the QGraphicsItems and handle the theming there :D QGraphicsLineItem (feint lines, completed lines), QGraphicsEllipseItem (dots), QGraphicsRectItem(completed squares)
- Todo:
- foreach for QLists in AI class
- Todo:
- valgrind
- Todo:
- Not yet Hints
- Todo:
- Not yet Network play
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:18:39 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.