X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fapp%2FApplication.h;h=cf1261b28f1a8c8799c3ce8aa2a5217af9ef3ab2;hb=a01c2f05b5a6493d7fe097eb15e5337a095992ae;hp=853d0cb25cefc91897beeaa41e7365f027a2604a;hpb=2a0eca649009f78028db286a67a532429cab5b88;p=l2e.git diff --git a/src/app/Application.h b/src/app/Application.h index 853d0cb..cf1261b 100644 --- a/src/app/Application.h +++ b/src/app/Application.h @@ -9,6 +9,7 @@ #define APP_APPLICATION_H_ #include "Input.h" +#include "Timer.h" #include "../sdl/InitScreen.h" #include @@ -40,6 +41,7 @@ public: void Quit(); Input &Buttons() { return input; } const Input &Buttons() const { return input; } + Timers &GlobalTimers() { return globalTimers; } private: struct StateCommand { @@ -51,6 +53,7 @@ private: private: State *CurrentState(); + bool StateChangePending() const { return !stateChanges.empty(); } void UpdateState(); void RealChangeState(State *); void RealPushState(State *); @@ -66,6 +69,7 @@ private: sdl::InitScreen *screen; std::stack states; std::queue stateChanges; + Timers globalTimers; Input input; Uint32 last;