HeadBall  1.0
A game
Public Member Functions | Private Member Functions | Private Attributes | List of all members
HeadBall::Game Class Reference

Class where game loop is processed. More...

#include <Game.hpp>

Collaboration diagram for HeadBall::Game:
Collaboration graph

Public Member Functions

 Game (int width, int height, std::string title)
 Construct a new Game object. More...
 

Private Member Functions

void run ()
 Run the game loop. More...
 

Private Attributes

const float dt = 1.0f / 60.0f
 The delta time for framerate management. More...
 
sf::Clock _clock
 The clock for getting ti. More...
 
GameDataRef _data = std::make_shared <GameData> ( )
 The shared pointer of game data. More...
 

Detailed Description

Class where game loop is processed.

Constructor & Destructor Documentation

◆ Game()

HeadBall::Game::Game ( int  width,
int  height,
std::string  title 
)

Construct a new Game object.

Parameters
width
height
title

Member Function Documentation

◆ run()

void HeadBall::Game::run ( )
private

Run the game loop.

Member Data Documentation

◆ _clock

sf::Clock HeadBall::Game::_clock
private

The clock for getting ti.

◆ _data

GameDataRef HeadBall::Game::_data = std::make_shared <GameData> ( )
private

The shared pointer of game data.

◆ dt

const float HeadBall::Game::dt = 1.0f / 60.0f
private

The delta time for framerate management.


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