PVLEGameHolder Class Reference

Singleton class that gives current game. More...

#include <PVLEGame.h>

Inheritance diagram for PVLEGameHolder:

Inheritance graph
[legend]

List of all members.

Public Member Functions

PVLEGameget ()
template<class T >
T * get ()
 Convinience method that casts the game object into the corresponding T class (with a boost::polymorphic_downcast<>).
void setCurrentGame (PVLEGame *pGame)
 Sets the current game.

Protected Attributes

PVLEGamepGame


Detailed Description

Singleton class that gives current game.

Definition at line 73 of file PVLEGame.h.


Member Function Documentation

template<class T >
T* PVLEGameHolder::get (  )  [inline]

Convinience method that casts the game object into the corresponding T class (with a boost::polymorphic_downcast<>).

Definition at line 79 of file PVLEGame.h.

References pGame.

PVLEGame* PVLEGameHolder::get (  )  [inline]

Definition at line 75 of file PVLEGame.h.

References pGame.

Referenced by Ammo::hitAfter(), and Explosion::hitBefore().

void PVLEGameHolder::setCurrentGame ( PVLEGame pGame  )  [inline]

Sets the current game.

Warning:
This function MUST be called either on app initialisation, or when all threads (3D/Physics/Networking...) have ended their current loop.
Todo:
must be thread safe.

Definition at line 84 of file PVLEGame.h.


Member Data Documentation

Definition at line 87 of file PVLEGame.h.

Referenced by get().


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

Generated on Sun Jan 17 11:39:29 2010 for PVLE (Pro-Vocation Light Engine) by  doxygen 1.5.9