Changeset 2077 in orxonox.OLD for orxonox/trunk/src/world.h
- Timestamp:
- Jul 5, 2004, 9:51:48 PM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/world.h
r2036 r2077 1 /** 2 Class representating the game-world 3 4 It contains a list of players (if multiplayer game), a list of Non-Player-Characters (nps), a list of Environment Entities. All this things together are building the orxonox-world. This class also handels the story-line (track), the world start/stop, init/uninit abilities. It is the middle point of every orxonox world. 5 */ 1 6 2 7 #ifndef WORLD_H … … 6 11 class NPC; 7 12 class Environment; 13 class WorldEntity; 14 15 template<class T> class List; 8 16 9 17 18 19 //! World Class 20 /** 21 Class for World representation 22 23 It contains a list of players (if multiplayer game), a list of Non-Player-Characters (nps), a list of Environment Entities. All this things together are building the orxonox-world. This class also handels the story-line (track), the world start/stop, init/uninit abilities. It is the middle point of every orxonox world. 24 */ 10 25 class World { 11 26 … … 14 29 ~World (); 15 30 16 float primitiveMove;17 31 18 /* for easier use: map the first two player here */19 Player *localPlayer;20 Player *player1;21 Player *player2;22 32 23 /* a list of all players */ 33 float primitiveMove; //!< deprecated, do not use 34 35 Player *localPlayer; //!< a pointer to the local player object 36 Player *player1; //!< a pointer to the second player object 37 Player *player2; //!< a pointer to the third player object 38 39 /* 24 40 struct playerList { 25 41 playerList* next; … … 29 45 playerList* lastPlayer; 30 46 31 /* a list of all non-player-characters */32 47 struct npcList { 33 48 npcList* next; … … 37 52 npcList* lastNPC; 38 53 39 /* a list of all environmental objects */40 54 struct envList { 41 55 envList* next; … … 44 58 }; 45 59 envList* lastEnv; 60 */ 46 61 47 62 48 63 void loadWorld(); 64 void unloadWorld(); 65 void pauseWorld(); 66 void saveGameState(char* filename); 67 49 68 50 69 bool addPlayer(Player* player); … … 54 73 bool removeNPC(NPC* npc); 55 74 bool addEnv(Environment* env); 75 bool removeEnv(Environment* env); 56 76 77 57 78 void drawWorld(void); 58 79 void initEnvironement(void); … … 63 84 64 85 private: 65 float surface[120][120]; 66 float step; 86 float surface[120][120]; //!< deprecated: used to build a surface 87 float step; //!< this is the step 88 89 List<WorldEntity*> *playerList; //!< the list of players, usualy very short 90 List<WorldEntity*> *npcList; //!< list of non player characters (npc) 91 List<WorldEntity*> *envList; //!< list of environment objects 67 92 68 93
Note: See TracChangeset
for help on using the changeset viewer.