4 * Created on: Apr 8, 2012
8 #ifndef APP_APPLICATION_H_
9 #define APP_APPLICATION_H_
14 #include "../sdl/InitScreen.h"
26 Application(sdl::InitScreen *screen, State *initialState);
29 Application(const Application &);
30 Application &operator =(const Application &);
37 void ChangeState(State *);
38 void PushState(State *);
41 Input &Buttons() { return input; }
42 const Input &Buttons() const { return input; }
43 Timers<Uint32> &GlobalTimers() { return globalTimers; }
54 State *CurrentState();
55 bool StateChangePending() const { return !stateChanges.empty(); }
57 void RealChangeState(State *);
58 void RealPushState(State *);
64 void UpdateWorld(Uint32 deltaT);
68 sdl::InitScreen *screen;
69 std::stack<State *> states;
70 std::queue<StateCommand> stateChanges;
71 Timers<Uint32> globalTimers;
79 #endif /* APP_APPLICATION_H_ */