I get a compiler error in gamestate.h and I'm not sure what's causing it because introstate.h is setup in a similar manner but working fine. The error message is:
|In member function 'void GameState::ChangeState(GameEngine*, GameState*)':|
|error: invalid use of incomplete type 'class GameEngine'|
|error: forward declaration of 'class GameEngine'|
In `gamestate.h' you are dereferencing the pointer, a forward declare is not good enough.
Post `gameengine.h'.
By the way, ¿why is `ChangeState()' a member function if you don't use the state of the caller? (or better, ¿why don't you use the state instead of passing a pointer? void ChangeState(GameEngine* game) { game->ChangeState(this); } )