Voxellancer  0.3
A game about voxels in space
 All Classes Functions Pages
Game Class Reference

#include <game.h>

Inheritance diagram for Game:
[legend]
Collaboration diagram for Game:
[legend]

Public Member Functions

GamePlay & gamePlay ()
 
virtual const Scene & scene () const override
 
virtual const CameraHead & cameraHead () const override
 
HMDManager & hmdManager ()
 
Viewer & viewer ()
 
virtual void update (float deltaSec) override
 
void draw ()
 
- Public Member Functions inherited from GameState
 GameState (const std::string &name, GameState *parent)
 
GameState * parentGameState ()
 
virtual void onEntered () override
 
virtual void onLeft () override
 
- Public Member Functions inherited from State
 State (State *parent=nullptr)
 
 State (const std::string &name, State *parent=nullptr)
 
const std::string & name () const
 
void setName (const std::string &name)
 
State * parentState ()
 
const State * parentState () const
 
State * initialSubState ()
 
const State * initialSubState () const
 
void setInitialSubState (State *initialSubState)
 
State * finalSubState ()
 
const State * finalSubState () const
 
void setFinalSubState (State *finalSubState)
 
State * currentSubState ()
 
const State * currentSubState () const
 
void setCurrentSubState (State *substate)
 
bool finished () const
 
std::list< State * > & substates ()
 
const std::list< State * > & substates () const
 
void addSubState (State *state)
 
void removeSubState (State *state)
 
std::list< Transition * > & transitions ()
 
const std::list< Transition * > & transitions () const
 
void addTransition (Transition *transition)
 
void removeTransition (Transition *transition)
 

Static Public Member Functions

static void setup ()
 
static Game * instance ()
 
static void tearDown ()
 

Protected Attributes

std::shared_ptr< HMDManager > m_hmdManager
 
std::unique_ptr< Viewer > m_viewer
 
GamePlay * m_gamePlay
 
- Protected Attributes inherited from GameState
GameState * m_parentGameState
 
- Protected Attributes inherited from State
std::string m_name
 
State * m_parentState
 
std::list< State * > m_subStates
 
std::list< Transition * > m_transitions
 
State * m_initialSubState
 
State * m_finalSubState
 
State * m_currentSubState
 

Static Protected Attributes

static Game * s_instance
 

Additional Inherited Members

- Protected Member Functions inherited from State
State * pathToDescendant (State *descendant)
 
void transit (State *target)
 
void leave ()
 

Detailed Description

Mainstate of the Game, entered once when libraries and context are setup and left just before they are teared down again

Member Function Documentation

void Game::update ( float  deltaSec)
overridevirtual

Performs a Transition from the currentSubState, if such isPossible()

Reimplemented from GameState.


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