Changeset 6498 in orxonox.OLD for trunk/src/util/state.h
- Timestamp:
- Jan 11, 2006, 9:58:22 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/util/state.h
r6468 r6498 7 7 #define _STATE_H 8 8 9 9 10 // FORWARD DECLARATION 10 11 class PNode; 11 12 class WorldEntity; 13 class Player; 14 class SkyBox; 15 class StoryEntity; 12 16 class ObjectManager; 13 class SkyBox;14 class Player;15 17 16 18 … … 34 36 static inline PNode* getCameraTarget() { return State::cameraTarget; }; 35 37 36 /** @returns the Local Player */ 37 static inline Player* localsPlayer() { return State::_localPlayer; }; 38 /** @param localPlayer the local Player */ 39 static inline void setLocalPlayer(Player* localPlayer) { State::_localPlayer = localPlayer; }; 40 38 //////////////// 39 /// SKYBOX /// 40 //////////////// 41 41 /** @returns the current SkyBox */ 42 static inline SkyBox* skyBox() { return State::_skyBox; };42 static inline SkyBox* getSkyBox() { return State::skyBox; }; 43 43 /** @param skyBox the SkyBox */ 44 static inline SkyBox* setSkyBox(SkyBox* skyBox) { State::_skyBox = skyBox; }; 45 44 static inline SkyBox* setSkyBox(SkyBox* skyBox) { State::skyBox = skyBox; }; 46 45 47 46 ////////////////////// … … 53 52 static inline ObjectManager* getObjectManager() { return State::objectManager; }; 54 53 54 static inline void setResolution(unsigned int resX, unsigned int resY) { State::resX = resX; State::resY = resY; }; 55 static inline unsigned int getResX() { return State::resX; }; 56 static inline unsigned int getResY() { return State::resY; }; 55 57 56 static inline void setResolution(unsigned int resX, unsigned int resY) { State::_resX = resX; State::_resY = resY; }; 57 static inline unsigned int resX() { return State::_resX; }; 58 static inline unsigned int resY() { return State::_resY; }; 58 ////////////////////// 59 /// STORY-ENTITY /// 60 ////////////////////// 61 /** @param storyEntity sets the current StoryEntity that is been played */ 62 static inline void setCurrentStoryEntity(StoryEntity* storyEntity) { State::storyEntity = storyEntity; }; 63 /** @returns the current StoryEntity played */ 64 static inline StoryEntity* getCurrentStoryEntity() { return State::storyEntity; }; 59 65 60 ///////////////////////// 61 /// WORLD_ENTITY_LIST /// 62 ///////////////////////// 66 ////////////// 67 /// PLAYER /// 68 ////////////// 69 /** @param player sets the current local player */ 70 static inline void setPlayer(Player* player) { State::player = player; }; 71 /** @returns the local player*/ 72 static inline Player* getPlayer() { return State::player; }; 73 74 63 75 64 76 private: … … 68 80 static PNode* cameraTarget; //!< A reference to the cameraTarget 69 81 static PNode* nullParent; //!< A reference to the Null-PNode. 70 static ObjectManager* objectManager; //!< A referenct to the current ObjectManager 82 static ObjectManager* objectManager; //!< A reference to the current ObjectManager 83 static StoryEntity* storyEntity; //!< A reference to the current StoryEntity played 84 static Player* player; //!< A reference to the Player 71 85 72 static Player* _localPlayer; //!< The Local Player. 73 static SkyBox* _skyBox; //!< The SkyBox used in the current world. 74 static unsigned int _resX; //!< The X Resolution of the screen. 75 static unsigned int _resY; //!< The Y Resolution of the screen. 86 static SkyBox* skyBox; //!< The SkyBox used in the current world. 87 static unsigned int resX; //!< The X Resolution of the screen. 88 static unsigned int resY; //!< The Y Resolution of the screen. 76 89 }; 77 90
Note: See TracChangeset
for help on using the changeset viewer.