]> git.localhorst.tv Git - l2e.git/blob - src/battle/states/SelectItem.h
extracted battle logic into a class
[l2e.git] / src / battle / states / SelectItem.h
1 #ifndef BATTLE_SELECTITEM_H_
2 #define BATTLE_SELECTITEM_H_
3
4 namespace battle {
5         class Battle;
6         class SelectAttackType;
7 }
8
9 #include "../../app/State.h"
10 #include "../../math/Vector.h"
11
12 namespace battle {
13
14 class SelectItem
15 : public app::State {
16
17 public:
18         SelectItem(Battle *battle, SelectAttackType *parent);
19
20 public:
21         virtual void HandleEvents(const app::Input &);
22         virtual void UpdateWorld(Uint32 deltaT);
23         virtual void Render(SDL_Surface *);
24
25 private:
26         virtual void OnEnterState(SDL_Surface *screen);
27         virtual void OnExitState(SDL_Surface *screen);
28         virtual void OnResumeState(SDL_Surface *screen);
29         virtual void OnPauseState(SDL_Surface *screen);
30
31         virtual void OnResize(int width, int height);
32
33 private:
34         void RenderFrame(SDL_Surface *);
35         void RenderHeadline(SDL_Surface *);
36         void RenderMenu(SDL_Surface *);
37
38 private:
39         Battle *battle;
40         SelectAttackType *parent;
41         math::Vector<int> framePosition;
42         math::Vector<int> frameSize;
43         math::Vector<int> headlinePosition;
44         math::Vector<int> menuPosition;
45
46 };
47
48 }
49
50 #endif