GameState Class Reference

The GameState object is a base class which is implemented through derived sub-classes. More...

Inheritance diagram for GameState:

Inheritance graph
[legend]
Collaboration diagram for GameState:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 GameState ()
 Constructor.
virtual ~GameState ()
 Deconstructor.
virtual void init ()
 Initialises the GameState.
virtual void clear ()
 Clears the GameState.
virtual void update (f32 deltaTime)
 Updates the GameState.
virtual void render ()
 Renders the GameState.
void refAdd ()
 Increases the reference counter.
void refRelease ()
 Decreases the reference counter.
const EntitygetBaseEntity () const
 Returns a pointer to the base pointer of the GameState.
void onUpdate (f32 deltaTime)
 Sends the "onUpdate" event to all entities subscribed to this state.
void onRender ()
 Sends the "onUpdate" event to all entities subscribed to this state.
void onPause ()
 Sends the "onPause" event to all entities subscribed to this state.
void onUnPause ()
 Sends the "onUnPause" event to all entities subscribed to this state.

Static Public Member Functions

static GameStaterefFactory ()
 Will be used to instanciate objects of this class.

Protected Attributes

EntitymBaseEntity

Friends

class ScriptedGameState


Detailed Description

The GameState object is a base class which is implemented through derived sub-classes.

Definition at line 28 of file GameState.h.


Constructor & Destructor Documentation

GameState::GameState (  ) 

Constructor.

Definition at line 26 of file GameState.cpp.

GameState::~GameState (  )  [virtual]

Deconstructor.

Definition at line 40 of file GameState.cpp.


Member Function Documentation

void GameState::clear (  )  [virtual]

Clears the GameState.

Reimplemented in ScriptedGameState.

Definition at line 53 of file GameState.cpp.

const Entity * GameState::getBaseEntity (  )  const

Returns a pointer to the base pointer of the GameState.

Definition at line 90 of file GameState.cpp.

void GameState::init (  )  [virtual]

Initialises the GameState.

Reimplemented in ScriptedGameState.

Definition at line 47 of file GameState.cpp.

void GameState::onPause (  ) 

Sends the "onPause" event to all entities subscribed to this state.

Note:
For internal use only!

Definition at line 109 of file GameState.cpp.

void GameState::onRender (  ) 

Sends the "onUpdate" event to all entities subscribed to this state.

Note:
For internal use only!

Definition at line 103 of file GameState.cpp.

void GameState::onUnPause (  ) 

Sends the "onUnPause" event to all entities subscribed to this state.

Note:
For internal use only!

Definition at line 115 of file GameState.cpp.

void GameState::onUpdate ( f32  deltaTime  ) 

Sends the "onUpdate" event to all entities subscribed to this state.

Note:
For internal use only!

Definition at line 97 of file GameState.cpp.

void GameState::refAdd (  ) 

Increases the reference counter.

Note:
For internal use only!

Definition at line 77 of file GameState.cpp.

GameState * GameState::refFactory (  )  [static]

Will be used to instanciate objects of this class.

Note:
For internal use only!

Definition at line 71 of file GameState.cpp.

void GameState::refRelease (  ) 

Decreases the reference counter.

Note:
For internal use only!

Definition at line 83 of file GameState.cpp.

void GameState::render (  )  [virtual]

Renders the GameState.

Reimplemented in ScriptedGameState.

Definition at line 65 of file GameState.cpp.

void GameState::update ( f32  deltaTime  )  [virtual]

Updates the GameState.

Parameters:
deltaTime The time that has passed since the last update.

Reimplemented in ScriptedGameState.

Definition at line 59 of file GameState.cpp.


Friends And Related Function Documentation

friend class ScriptedGameState [friend]

Definition at line 30 of file GameState.h.


Member Data Documentation

Definition at line 83 of file GameState.h.


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

Generated on Wed Jun 10 22:26:25 2009 for Sirrf - Simple Irrlicht Framework by  doxygen 1.5.8