Base class for all games.
More...
#include "Game.hpp"
|
| Game ()=default |
| Constructs a new Game object.
|
virtual | ~Game ()=default |
| Destructs the Game object.
|
virtual void | Play () final |
| The main orchestration loop for all games.
|
| Game (const Game &p_game)=delete |
| Disable constructing a new Game object using copy constructor.
|
| Game (const Game &&p_game)=delete |
| Disable constructing a new Game object using move constructor.
|
Game & | operator= (const Game &p_game)=delete |
| Disable constructing a new Game object using copy assignment operator.
|
Game & | operator= (const Game &&p_game)=delete |
| Disable constructing a new Game object using move assignment operator.
|
|
virtual void | SetupGame ()=0 |
| Clears and sets all member variables to their game start default.
|
virtual void | GetUserOptions ()=0 |
| Prompt the user for their choice on various game-related options.
|
virtual void | UpdateGameInformation ()=0 |
| Updates GameInformation to match the current state of the game.
|
virtual bool | IsGameOver ()=0 |
| Check whether the game is over.
|
virtual void | ToggleCurrentPlayer ()=0 |
| Change the current player to the other player.
|
virtual bool | IsCurrentTurnUsers ()=0 |
| Check whether the current turn should be executed by the user.
|
virtual void | ExecuteUserCommand ()=0 |
| Prompt the user to enter their command for the current turn.
|
virtual void | ExecuteComputerCommand ()=0 |
| Get a random command from the computer.
|
virtual void | GameOver ()=0 |
| Display the game over message and prompt the user whether they would like to play again or quit the game.
|
virtual void | RestartGame ()=0 |
| Update variables to allow for the game to be restarted with the same user options.
|
virtual void | ResetGame ()=0 |
| Update variables to allow for the game to be reset and so the user will be asked for new options.
|
Base class for all games.
Definition at line 15 of file Game.hpp.
◆ Game() [1/2]
TerminalGames::Game::Game |
( |
const Game & | p_game | ) |
|
|
delete |
Disable constructing a new Game object using copy constructor.
- Parameters
-
◆ Game() [2/2]
TerminalGames::Game::Game |
( |
const Game && | p_game | ) |
|
|
delete |
Disable constructing a new Game object using move constructor.
- Parameters
-
◆ Play()
virtual void TerminalGames::Game::Play |
( |
| ) |
|
|
inlinefinalvirtual |
The main orchestration loop for all games.
Definition at line 31 of file Game.hpp.
◆ operator=() [1/2]
Game & TerminalGames::Game::operator= |
( |
const Game & | p_game | ) |
|
|
delete |
Disable constructing a new Game object using copy assignment operator.
- Parameters
-
◆ operator=() [2/2]
Game & TerminalGames::Game::operator= |
( |
const Game && | p_game | ) |
|
|
delete |
Disable constructing a new Game object using move assignment operator.
- Parameters
-
◆ SetupGame()
virtual void TerminalGames::Game::SetupGame |
( |
| ) |
|
|
privatepure virtual |
◆ GetUserOptions()
virtual void TerminalGames::Game::GetUserOptions |
( |
| ) |
|
|
privatepure virtual |
◆ UpdateGameInformation()
virtual void TerminalGames::Game::UpdateGameInformation |
( |
| ) |
|
|
privatepure virtual |
◆ IsGameOver()
virtual bool TerminalGames::Game::IsGameOver |
( |
| ) |
|
|
privatepure virtual |
◆ ToggleCurrentPlayer()
virtual void TerminalGames::Game::ToggleCurrentPlayer |
( |
| ) |
|
|
privatepure virtual |
◆ IsCurrentTurnUsers()
virtual bool TerminalGames::Game::IsCurrentTurnUsers |
( |
| ) |
|
|
privatepure virtual |
◆ ExecuteUserCommand()
virtual void TerminalGames::Game::ExecuteUserCommand |
( |
| ) |
|
|
privatepure virtual |
◆ ExecuteComputerCommand()
virtual void TerminalGames::Game::ExecuteComputerCommand |
( |
| ) |
|
|
privatepure virtual |
◆ GameOver()
virtual void TerminalGames::Game::GameOver |
( |
| ) |
|
|
privatepure virtual |
◆ RestartGame()
virtual void TerminalGames::Game::RestartGame |
( |
| ) |
|
|
privatepure virtual |
◆ ResetGame()
virtual void TerminalGames::Game::ResetGame |
( |
| ) |
|
|
privatepure virtual |
The documentation for this class was generated from the following file: