Last change
on this file since 1895 was
1883,
checked in by patrick, 21 years ago
|
orxonox/trunk: added envoronment eg. little mountain - its time to talk about further development…
|
File size:
1.1 KB
|
Line | |
---|
1 | |
---|
2 | |
---|
3 | |
---|
4 | #ifndef WORLD_H |
---|
5 | #define WORLD_H |
---|
6 | |
---|
7 | #include <stdlib.h> |
---|
8 | |
---|
9 | #include "npc.h" |
---|
10 | #include "player.h" |
---|
11 | #include "environment.h" |
---|
12 | #include "stdincl.h" |
---|
13 | |
---|
14 | class World { |
---|
15 | |
---|
16 | public: |
---|
17 | World (); |
---|
18 | ~World (); |
---|
19 | |
---|
20 | /* for easier use: map the first two player here */ |
---|
21 | Player *localPlayer; |
---|
22 | Player *player1; |
---|
23 | Player *player2; |
---|
24 | |
---|
25 | /* a list of all players */ |
---|
26 | struct playerList { |
---|
27 | playerList* next; |
---|
28 | Player* player; |
---|
29 | int number; |
---|
30 | }; |
---|
31 | playerList* lastPlayer; |
---|
32 | |
---|
33 | /* a list of all non-player-characters */ |
---|
34 | struct npcList { |
---|
35 | npcList* next; |
---|
36 | NPC* npc; |
---|
37 | int number; |
---|
38 | }; |
---|
39 | npcList* lastNPC; |
---|
40 | |
---|
41 | /* a list of all environmental objects */ |
---|
42 | struct envList { |
---|
43 | envList* next; |
---|
44 | Environment* env; |
---|
45 | int number; |
---|
46 | }; |
---|
47 | envList* lastEnv; |
---|
48 | |
---|
49 | bool addPlayer(Player* player); |
---|
50 | bool removePlayer(Player* player); |
---|
51 | Player* getLocalPlayer(); |
---|
52 | |
---|
53 | bool addNPC(NPC* npc); |
---|
54 | bool removeNPC(NPC* npc); |
---|
55 | |
---|
56 | bool addEnv(Environment* env); |
---|
57 | |
---|
58 | void drawWorld(void); |
---|
59 | void initEnvironement(void); |
---|
60 | void updateWorld(void); |
---|
61 | void testThaTest(void); |
---|
62 | |
---|
63 | private: |
---|
64 | float surface[120][120]; |
---|
65 | |
---|
66 | |
---|
67 | }; |
---|
68 | |
---|
69 | #endif |
---|
Note: See
TracBrowser
for help on using the repository browser.