]> git.localhorst.tv Git - l2e.git/blob - src/battle/states/DefeatState.h
relocate scripts
[l2e.git] / src / battle / states / DefeatState.h
1 #ifndef BATTLE_DEFEATSTATE_H_
2 #define BATTLE_DEFEATSTATE_H_
3
4 namespace battle {
5         class Battle;
6         class BattleState;
7 }
8
9 #include "../../app/State.h"
10 #include "../../math/Vector.h"
11
12 #include <SDL.h>
13
14 namespace battle {
15
16 class DefeatState
17 : public app::State {
18
19 public:
20         DefeatState(
21                         Battle *battle,
22                         BattleState *parent);
23
24 public:
25         virtual void HandleEvents(const app::Input &);
26         virtual void UpdateWorld(Uint32 deltaT);
27         virtual void Render(SDL_Surface *);
28
29 private:
30         virtual void OnEnterState(SDL_Surface *screen);
31         virtual void OnExitState(SDL_Surface *screen);
32         virtual void OnResumeState(SDL_Surface *screen);
33         virtual void OnPauseState(SDL_Surface *screen);
34
35         virtual void OnResize(int width, int height);
36
37 private:
38         void RenderTitleBar(SDL_Surface *screen);
39
40 private:
41         Battle *battle;
42         BattleState *parent;
43         SDL_Surface *cache;
44         SDL_PixelFormat *format;
45         app::Timer<Uint32> timer;
46         math::Vector<int> framePosition;
47         math::Vector<int> frameSize;
48         math::Vector<int> textPosition;
49
50 };
51
52 }
53
54 #endif