|
CBG
0.1
Compendium of board games
|
#include <GameWithXYSelector.h>
Public Member Functions | |
| GameWithXYSelector (const int amountOfPlayers, const int columns, const int rows) | |
Public Member Functions inherited from Game | |
| Game (const int amountOfPlayers, const int columns, const int rows) | |
| virtual | ~Game () |
| virtual void | start () |
Protected Member Functions | |
| void | drawScreen () const |
| Prints out the board and the players pieces. More... | |
| int | getPoint (string message, int range) const |
| Prompts with message to get a point between 0 and range. More... | |
| int | getOpposition () const |
| Returns the opposition. More... | |
Protected Member Functions inherited from Game | |
| void | clearScreen () const |
| Clears the terminal window. More... | |
| virtual bool | getMove ()=0 |
| Gets input from the player detailing which move they wish to make. More... | |
| virtual int | isOver ()=0 |
| Defines whether or not the game is over. More... | |
Additional Inherited Members | |
Protected Attributes inherited from Game | |
| int | currentPlayer |
| Holds the position in the players array of the current player. More... | |
| Player ** | players |
| Holds all of the games players. More... | |
| Square ** | grid |
| Holds all of the squares that makes up the games grid. More... | |
| const int | amountOfPlayers |
| Holds the length of the players array. More... | |
| const int | columns |
| Holds the amount of columns within the grid. More... | |
| const int | rows |
| Holds the amount of rows within the grid. More... | |
Common functions between games that use X, Y selectors.
| GameWithXYSelector::GameWithXYSelector | ( | const int | amountOfPlayers, |
| const int | columns, | ||
| const int | rows | ||
| ) |
|
protectedvirtual |
Prints out the board and the players pieces.
Prints out the board and all the players pieces.
Implements Game.
|
protected |
Returns the opposition.
|
protected |
Prompts with message to get a point between 0 and range.
Prints out the board and the players pieces. Prompts with message to get a point between 0 and range.