-
Notifications
You must be signed in to change notification settings - Fork 0
/
Env.h
49 lines (42 loc) · 860 Bytes
/
Env.h
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
#ifndef __ENV_H__
#define __ENV_H__
#include "Singleton.hpp"
#include <pthread.h>
namespace ID
{
class Window;
};
class Abstract_Screen;
class Main_Screen;
class Host_Screen;
class Join_Screen;
class Option_Screen;
class Credit_Screen;
class Lobby_Screen;
class Game_Screen;
class Env : public Singleton<Env>
{
friend class Singleton<Env>;
public:
Env();
~Env();
int Init(ID::Window* window);
void SwitchScreen(Abstract_Screen* as);
public:
bool alive;
char nickname[21];
int height;
int width;
pthread_mutex_t dataMutex;
pthread_mutex_t displayMutex;
ID::Window* window;
Abstract_Screen* focusScreen;
Main_Screen* mainScreen;
Host_Screen* hostScreen;
Join_Screen* joinScreen;
Option_Screen* optionScreen;
Credit_Screen* creditScreen;
Lobby_Screen* lobbyScreen;
Game_Screen* gameScreen;
};
#endif