]> git.localhorst.tv Git - l2e.git/blob - src/app/State.h
fixed SDL inclusion in application classes
[l2e.git] / src / app / State.h
1 /*
2  * State.h
3  *
4  *  Created on: Apr 8, 2012
5  *      Author: holy
6  */
7
8 #ifndef APP_APPLICATIONSTATE_H_
9 #define APP_APPLICATIONSTATE_H_
10
11 #include <SDL.h>
12
13 namespace app {
14
15 class Application;
16
17 class State {
18
19 public:
20         virtual ~State() { };
21
22 public:
23         /// do some setup
24         /// @param ctrl the Application running the state
25         virtual void EnterState(Application &ctrl, SDL_Surface *screen) = 0;
26         virtual void ExitState() = 0;
27
28         virtual void HandleEvent(const SDL_Event &) = 0;
29         virtual void UpdateWorld(float deltaT) = 0;
30         virtual void Render(SDL_Surface *) = 0;
31
32 };
33
34 }
35
36 #endif /* APP_STATE_H_ */