-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMenuState.hpp
More file actions
70 lines (52 loc) · 1.45 KB
/
MenuState.hpp
File metadata and controls
70 lines (52 loc) · 1.45 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
//================================================//
#ifndef __MENUSTATE_HPP__
#define __MENUSTATE_HPP__
//================================================//
#include "AppState.hpp"
#include "SharedData.hpp"
#include "GUILayerMenuState.hpp"
#include "Sound.hpp"
//================================================//
class MenuState : public AppState
{
public:
MenuState(void);
DECLARE_APPSTATE_CLASS(MenuState);
void enter(void);
void exit(void);
bool pause(void);
void resume(void);
void createScene(void);
void createGUI(void);
void destroyGUI(void);
// OIS::KeyListener
bool keyPressed(const OIS::KeyEvent& arg);
bool keyReleased(const OIS::KeyEvent& arg);
// OIS::MouseListener
bool mouseMoved(const OIS::MouseEvent& arg);
bool mousePressed(const OIS::MouseEvent& arg, OIS::MouseButtonID id);
bool mouseReleased(const OIS::MouseEvent& arg, OIS::MouseButtonID id);
// GUI
void handleGUIEvent(void);
// update
void update(double timeSinceLastFrame);
private:
// Ogre
Ogre::AnimationState* m_animState;
Ogre::Camera* m_pCamera;
// GUI
GUILayer* m_GUIRootLayer;
GUILayer* m_GUINewGameLayer;
GUILayer* m_GUILoadGameLayer;
GUILayer* m_GUIOptionsLayer;
GUILayer* m_GUICreditsLayer;
int m_GUIEventId;
std::vector<GUILayer*> m_GUILayers;
// FMOD
Sound* m_pMusic;
// misc.
bool m_bQuit;
};
//================================================//
#endif
//================================================//