Changeset 161 for code/branches/main_reto_vs05/include
- Timestamp:
- Nov 4, 2007, 5:00:41 PM (17 years ago)
- Location:
- code/branches/main_reto_vs05/include
- Files:
-
- 2 added
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/main_reto_vs05/include/Bullet.h
r157 r161 30 30 #define BULLET_H 31 31 32 #include "Ogre .h"32 #include "OgrePrerequisites.h" 33 33 34 using namespace Ogre; 35 36 class Bullet 37 { 38 public: 39 SceneNode *mNode; 40 Entity *mEntity; 41 Vector3 mSpeed; 42 43 Bullet(SceneNode*, Entity*, Vector3); 44 ~Bullet(); 45 46 protected: 47 48 }; 34 #include "Orxonox_prerequisites.h" 49 35 50 36 37 namespace Orxonox { 38 39 class Bullet 40 { 41 public: 42 Ogre::SceneNode *mNode; 43 Ogre::Entity *mEntity; 44 Ogre::Vector3 mSpeed; 45 46 protected: 47 48 public: 49 Bullet(Ogre::SceneNode*, Ogre::Entity*, Ogre::Vector3); 50 ~Bullet(); 51 52 protected: 53 54 }; 55 56 } 57 51 58 #endif /* BULLET_H */ -
code/branches/main_reto_vs05/include/Orxonox.h
r159 r161 30 30 #define ORXONOX_H 31 31 32 #include "Ogre.h" 33 #include "OgreTimer.h" 32 #include "OgrePrerequisites.h" 34 33 35 #include "ogre_control.h" 36 #include "run_manager.h" 34 #include "Orxonox_prerequisites.h" 37 35 38 class Orxonox 39 { 40 public: 41 Orxonox(); 42 virtual ~Orxonox(); 43 virtual void go(); 36 namespace Orxonox { 44 37 45 protected: 46 virtual bool setup(void); 38 class Orxonox 39 { 40 public: 41 Orxonox(); 42 virtual ~Orxonox(); 43 virtual void go(); 47 44 48 virtual void destroy(void); 45 protected: 46 virtual bool setup(void); 49 47 50 protected: 51 OgreControl *ogre_; 52 RunManager *runMgr_; 53 Timer *timer_; 48 virtual void destroy(void); 54 49 55 }; 50 protected: 51 OgreControl *ogre_; 52 RunManager *runMgr_; 53 Ogre::Timer *timer_; 54 55 }; 56 57 } 56 58 57 59 #endif /* ORXONOX_H */ -
code/branches/main_reto_vs05/include/camera_manager.h
r157 r161 30 30 #define CAMERA_MANAGER_H 31 31 32 #include "Ogre .h"32 #include "OgrePrerequisites.h" 33 33 34 using namespace Ogre; 35 36 class CameraManager 37 { 38 public: 39 CameraManager(SceneManager*); 40 ~CameraManager(); 41 42 bool setCameraPosition(int); 43 44 protected: 45 SceneManager *mSceneMgr; 46 Camera *mCamera; 47 }; 34 #include "Orxonox_prerequisites.h" 48 35 49 36 37 namespace Orxonox { 38 39 class CameraManager 40 { 41 public: 42 CameraManager(Ogre::SceneManager*); 43 ~CameraManager(); 44 45 bool setCameraPosition(int); 46 47 protected: 48 Ogre::SceneManager *mSceneMgr; 49 Ogre::Camera *mCamera; 50 }; 51 52 } 53 50 54 #endif /* CAMERA_MANAGER_H */ -
code/branches/main_reto_vs05/include/ogre_control.h
r159 r161 30 30 #define OGRE_CONTROL_H 31 31 32 #include "Ogre.h" 33 #include "OgreConfigFile.h" 32 #include "OgrePrerequisites.h" 33 34 #include "Orxonox_prerequisites.h" 34 35 35 36 36 #if OGRE_PLATFORM == OGRE_PLATFORM_APPLE 37 #include <CoreFoundation/CoreFoundation.h> 38 #endif 37 namespace Orxonox { 39 38 40 using namespace Ogre; 39 class OgreControl 40 { 41 public: 42 OgreControl(); 41 43 42 class OgreControl 43 { 44 public: 45 OgreControl(); 44 virtual ~OgreControl(); 46 45 47 virtual ~OgreControl(); 46 /** Sets up the application - returns false if the user chooses to abandon configuration. */ 47 virtual bool initialise(); 48 48 49 /** Sets up the application - returns false if the user chooses to abandon configuration. */ 50 virtual bool initialise(); 49 virtual Ogre::Root* getRoot(); 51 50 52 virtual Root* getRoot();51 virtual Ogre::RenderWindow* getRenderWindow(); 53 52 54 virtual RenderWindow* getRenderWindow();53 virtual Ogre::String getResourcePath(); 55 54 56 virtual Ogre::String getResourcePath(); 55 protected: 56 /** Configures the application - returns false if the user chooses to abandon configuration. */ 57 virtual bool configure(void); 57 58 58 protected: 59 /** Configures the application - returns false if the user chooses to abandon configuration. */ 60 virtual bool configure(void); 59 /// Method which will define the source of resources (other than current folder) 60 virtual void setupResources(void); 61 61 62 /// Method which will define the source of resources (other than current folder) 63 virtual void setupResources(void); 62 protected: 63 Ogre::Root *root_; 64 Ogre::RenderWindow *window_; 65 Ogre::String resourcePath_; 64 66 65 protected: 66 Root *root_; 67 RenderWindow *window_; 68 Ogre::String resourcePath_; 67 }; 69 68 70 } ;69 } 71 70 72 71 #endif /* OGRE_CONTROL_H */ -
code/branches/main_reto_vs05/include/orxonox_scene.h
r159 r161 30 30 #define ORXONOX_SCENE_H 31 31 32 #include "Ogre .h"32 #include "OgrePrerequisites.h" 33 33 34 using namespace Ogre; 34 #include "Orxonox_prerequisites.h" 35 35 36 class OrxonoxScene37 {38 public:39 OrxonoxScene(SceneManager*);40 36 41 virtual ~OrxonoxScene(); 37 namespace Orxonox { 42 38 43 virtual bool initialise(); 39 class OrxonoxScene 40 { 41 public: 42 OrxonoxScene(Ogre::SceneManager*); 44 43 45 virtual bool tick(unsigned long, Real);44 virtual ~OrxonoxScene(); 46 45 47 protected: 48 /// method where you can perform resource group loading 49 virtual void loadResources(); 46 virtual bool initialise(); 50 47 51 /// Define what is in the scene 52 virtual void createScene(); 48 virtual bool tick(unsigned long, Ogre::Real); 53 49 54 protected: 55 SceneManager* sceneMgr_; 50 protected: 51 /// method where you can perform resource group loading 52 virtual void loadResources(); 56 53 57 //specific variables for test purposes 58 Light *light_; 59 SceneNode *lightNode_; 60 BillboardSet *bbs_; 61 Real distance_; 62 Real radius_; 63 }; 54 /// Define what is in the scene 55 virtual void createScene(); 56 57 protected: 58 Ogre::SceneManager* sceneMgr_; 59 60 //specific variables for test purposes 61 Ogre::Light *light_; 62 Ogre::SceneNode *lightNode_; 63 Ogre::BillboardSet *bbs_; 64 Ogre::Real distance_; 65 Ogre::Real radius_; 66 }; 67 68 } 64 69 65 70 #endif /* ORXONOX_SCENE_H */ -
code/branches/main_reto_vs05/include/orxonox_ship.h
r159 r161 30 30 #define ORXONOX_SHIP_H 31 31 32 #include "Ogre .h"32 #include "OgrePrerequisites.h" 33 33 34 #include "bullet.h" 35 36 using namespace Ogre; 37 38 class OrxonoxShip 39 { 40 public: 41 OrxonoxShip(SceneManager*, SceneNode*); 42 virtual ~OrxonoxShip(); 43 44 virtual bool initialise(); 45 46 void setMainThrust(const Real); 47 void setSideThrust(const Real); 48 void setYThrust(const Real); 49 void turnUpAndDown(const Radian&); 50 void turnLeftAndRight(const Radian&); 51 52 SceneNode* getRootNode(); 53 Vector3 getSpeed(); 54 55 Bullet* fire(); 56 57 bool tick(unsigned long, Real); 58 59 protected: 60 61 protected: 62 SceneManager *sceneMgr_; 63 SceneNode *rootNode_; 64 Entity *shipEntity_; 65 66 Vector3 currentSpeed_; // relative to space 67 Vector3 currentThrust_; // relative to the ship 68 Real baseThrust_; 69 int objectCounter_; 70 Vector3 bulletSpeed_; 71 72 }; 34 #include "Orxonox_prerequisites.h" 73 35 74 36 37 namespace Orxonox { 38 39 class OrxonoxShip 40 { 41 public: 42 OrxonoxShip(Ogre::SceneManager*, Ogre::SceneNode*); 43 virtual ~OrxonoxShip(); 44 45 virtual bool initialise(); 46 47 void setMainThrust(const Ogre::Real); 48 void setSideThrust(const Ogre::Real); 49 void setYThrust(const Ogre::Real); 50 void turnUpAndDown(const Ogre::Radian&); 51 void turnLeftAndRight(const Ogre::Radian&); 52 53 Ogre::SceneNode* getRootNode(); 54 Ogre::Vector3 getSpeed(); 55 56 Bullet* fire(); 57 58 bool tick(unsigned long, Ogre::Real); 59 60 protected: 61 62 protected: 63 Ogre::SceneManager *sceneMgr_; 64 Ogre::SceneNode *rootNode_; 65 Ogre::Entity *shipEntity_; 66 67 Ogre::Vector3 currentSpeed_; // relative to space 68 Ogre::Vector3 currentThrust_; // relative to the ship 69 Ogre::Real baseThrust_; 70 int objectCounter_; 71 Ogre::Vector3 bulletSpeed_; 72 73 }; 74 75 } 76 75 77 #endif /* ORXONOX_SHIP_H */ -
code/branches/main_reto_vs05/include/run_manager.h
r159 r161 30 30 #define RUN_MANAGER_H 31 31 32 #include "Ogre .h"33 #include "Ogre StringConverter.h"34 #include "Ogre Exception.h"32 #include "OgrePrerequisites.h" 33 #include "OgreWindowEventUtilities.h" 34 #include "OgreTextureManager.h" 35 35 36 #include "ogre_control.h"37 #include "orxonox_scene.h" 38 #include " orxonox_ship.h"36 #include <OIS/OISPrereqs.h> 37 38 #include "Orxonox_prerequisites.h" 39 39 40 40 41 //Use this define to signify OIS will be used as a DLL 42 //(so that dll import/export macros are in effect) 43 #define OIS_DYNAMIC_LIB 44 #include <OIS/OIS.h> 41 namespace Orxonox { 45 42 46 using namespace Ogre; 43 // let the class inherit from WindowEventListener in order for the RunMgr 44 // to act as the central point of all the calcuations in Orxonox 45 class RunManager : Ogre::WindowEventListener 46 { 47 public: 48 RunManager(OgreControl*); 49 50 virtual ~RunManager(); 51 52 virtual bool tick(unsigned long, Ogre::Real); 53 54 protected: 55 virtual void createCamera(void); 56 57 virtual void createViewports(void); 47 58 48 59 49 // let the class inherit from WindowEventListener in order for the RunMgr 50 // to act as the central point of all the calcuations in Orxonox 51 class RunManager : WindowEventListener 52 { 53 public: 54 RunManager(OgreControl*); 60 /** EVENT HANDLING **/ 55 61 56 virtual ~RunManager(); 62 //Adjust mouse clipping area 63 virtual void windowResized(Ogre::RenderWindow*); 57 64 58 virtual bool tick(unsigned long, Real); 59 60 protected: 61 virtual void createCamera(void); 62 63 virtual void createViewports(void); 65 //Unattach OIS before window shutdown (very important under Linux) 66 virtual void windowClosed(Ogre::RenderWindow*); 64 67 65 68 66 /** EVENT HANDLING **/ 69 /** INPUT PROCESSING **/ 70 virtual bool processUnbufferedKeyInput(); 67 71 68 //Adjust mouse clipping area 69 virtual void windowResized(RenderWindow*); 70 71 //Unattach OIS before window shutdown (very important under Linux) 72 virtual void windowClosed(RenderWindow*); 72 virtual bool processUnbufferedMouseInput(); 73 73 74 74 75 /** INPUT PROCESSING **/ 76 virtual bool processUnbufferedKeyInput(); 75 /** OUTPUT **/ 77 76 78 virtual bool processUnbufferedMouseInput();77 virtual void updateStats(void); 79 78 79 virtual void showDebugOverlay(bool); 80 80 81 /** OUTPUT **/ 81 protected: 82 Ogre::SceneManager *sceneMgr_; 83 Ogre::RenderWindow *window_; 84 Ogre::Camera *camera_; 85 OgreControl *ogre_; 86 OrxonoxScene *backgroundScene_; 87 OrxonoxShip *playerShip_; 82 88 83 virtual void updateStats(void); 89 bool statsOn_; 90 std::string debugText_; 84 91 85 virtual void showDebugOverlay(bool); 92 unsigned int screenShotCounter_; 93 // just to stop toggles flipping too fast 94 Ogre::Real timeUntilNextToggle_; 95 bool leftButtonDown_; 96 Ogre::TextureFilterOptions filtering_; 97 int aniso_; 86 98 87 protected: 88 OgreControl *ogre_; 89 SceneManager *sceneMgr_; 90 RenderWindow *window_; 91 OrxonoxScene *backgroundScene_; 92 Camera *camera_; 93 OrxonoxShip *playerShip_; 99 int sceneDetailIndex_; 100 Ogre::Overlay* debugOverlay_; 94 101 95 bool statsOn_; 96 std::string debugText_; 102 //OIS Input devices 103 OIS::InputManager* inputManager_; 104 OIS::Mouse* mouse_; 105 OIS::Keyboard* keyboard_; 106 OIS::JoyStick* joystick_; 97 107 98 unsigned int screenShotCounter_; 99 // just to stop toggles flipping too fast 100 Real timeUntilNextToggle_; 101 bool leftButtonDown_; 102 TextureFilterOptions filtering_; 103 int aniso_; 108 const Ogre::Real mouseSensitivity_; 104 109 105 int sceneDetailIndex_; 106 Overlay* debugOverlay_; 110 // Bullet array 111 Bullet **bullets_; 112 int bulletsSize_; 113 int bulletsIndex_; 107 114 108 //OIS Input devices 109 OIS::InputManager* inputManager_; 110 OIS::Mouse* mouse_; 111 OIS::Keyboard* keyboard_; 112 OIS::JoyStick* joystick_; 115 // previously elapsed render time 116 unsigned long totalTime_; 113 117 114 const Real mouseSensitivity_;118 }; 115 119 116 // Bullet array 117 Bullet **bullets_; 118 int bulletsSize_; 119 int bulletsIndex_; 120 121 // previously elapsed render time 122 unsigned long totalTime_; 123 124 }; 120 } 125 121 126 122 #endif /* RUN_MANAGER_H */ -
code/branches/main_reto_vs05/include/weapon_manager.h
r157 r161 30 30 #define WEAPON_MANAGER_H 31 31 32 #include "Ogre .h"32 #include "OgrePrerequisites.h" 33 33 34 using namespace Ogre; 35 36 class WeaponManager 37 { 38 public: 39 WeaponManager(SceneManager*); 40 virtual ~WeaponManager(); 41 42 protected: 43 44 }; 34 #include "Orxonox_prerequisites.h" 45 35 46 36 37 namespace Orxonox { 38 39 class WeaponManager 40 { 41 public: 42 WeaponManager(Ogre::SceneManager*); 43 virtual ~WeaponManager(); 44 45 protected: 46 47 }; 48 49 } 50 47 51 #endif /* WEAPON_MANAGER_H */
Note: See TracChangeset
for help on using the changeset viewer.