Last change
on this file since 6319311 was 6319311, checked in by Dmitry Portnoy <dportnoy@…>, 11 years ago |
Some redfinition issues related to winsock2 are fixed and a few allegro rendering functions are now in GameRender
|
-
Property mode
set to
100644
|
File size:
809 bytes
|
Line | |
---|
1 | #ifndef _GAME_H
|
---|
2 | #define _GAME_H
|
---|
3 |
|
---|
4 | #include "Compiler.h"
|
---|
5 |
|
---|
6 | #include <string>
|
---|
7 | #include <map>
|
---|
8 |
|
---|
9 | #ifdef WINDOWS
|
---|
10 | #define WIN32_LEAN_AND_MEAN
|
---|
11 | #endif
|
---|
12 |
|
---|
13 | #include <allegro5/allegro_font.h>
|
---|
14 |
|
---|
15 | #include "Player.h"
|
---|
16 | #include "WorldMap.h"
|
---|
17 |
|
---|
18 | using namespace std;
|
---|
19 |
|
---|
20 | class Game {
|
---|
21 | private:
|
---|
22 | unsigned int id;
|
---|
23 | string name;
|
---|
24 | map<unsigned int, Player*> players;
|
---|
25 | WorldMap* worldMap;
|
---|
26 | int blueScore;
|
---|
27 | int redScore;
|
---|
28 |
|
---|
29 | public:
|
---|
30 | Game();
|
---|
31 | Game(string name, string filepath);
|
---|
32 |
|
---|
33 | ~Game();
|
---|
34 |
|
---|
35 | string getName();
|
---|
36 | int getNumPlayers();
|
---|
37 | map<unsigned int, Player*>& getPlayers();
|
---|
38 | int getBlueScore();
|
---|
39 | int getRedScore();
|
---|
40 | WorldMap* getMap();
|
---|
41 |
|
---|
42 | void setId(unsigned int id);
|
---|
43 | bool addPlayer(Player* p);
|
---|
44 | bool removePlayer(unsigned int id);
|
---|
45 | void setBlueScore(int score);
|
---|
46 | void setRedScore(int score);
|
---|
47 | };
|
---|
48 |
|
---|
49 | #endif
|
---|
Note:
See
TracBrowser
for help on using the repository browser.