TheCOSCGameProject  1.0
Public Member Functions | List of all members
ValerisGame Class Reference

Manages the core gameplay of Valeris. More...

#include <valerisgame.h>

Public Member Functions

 ValerisGame ()
 Constructor for the ValerisGame class. More...
 
void start (const std::string &color)
 Starts the game. More...
 

Detailed Description

Manages the core gameplay of Valeris.

The ValerisGame class is responsible for initializing the game, managing the player and dungeon, and handling the game's main loop.

Constructor & Destructor Documentation

◆ ValerisGame()

ValerisGame::ValerisGame ( )

Constructor for the ValerisGame class.

Initializes the player, dungeon, and other game-related entities.

Initializes the game by generating a dungeon floor with a specified number of rooms and setting the current room to the starting point.

< Sets the number of rooms in the dungeon.

< Generates the dungeon floor and sets the starting room.

Member Function Documentation

◆ start()

void ValerisGame::start ( const std::string &  color)

Starts the game.

Starts the game and manages the main exploration loop.

Parameters
colorthe color of the text

This method begins the game loop, allowing the player to explore the dungeon and interact with the environment.

The start method enters a loop where the player explores the dungeon, moves between rooms, and interacts with the game world. The player can move in cardinal directions, engage in combat, play games, or view help information.

< Flag to control the exploration loop.

< Gets the player's input for movement or action.

< Move the player to the room to the north.

< Move the player to the room to the south.

< Move the player to the room to the east.

< Move the player to the room to the west.

< Starts the NPC's gambling game if the current room is a gambling room.

< Initiates combat with the enemy.

< Exits the exploration loop and ends the game.

< Exits the exploration loop and ends the game.

< Displays help information from a file.


The documentation for this class was generated from the following files: