[608] | 1 | #ifndef _SpaceShip_H__ |
---|
| 2 | #define _SpaceShip_H__ |
---|
| 3 | |
---|
[708] | 4 | #include <OgrePrerequisites.h> |
---|
| 5 | #include <OIS/OISMouse.h> |
---|
[608] | 6 | |
---|
[708] | 7 | #include "../OrxonoxPrereqs.h" |
---|
| 8 | |
---|
[608] | 9 | #include "Model.h" |
---|
[768] | 10 | #include "../tools/BillboardSet.h" |
---|
[633] | 11 | |
---|
[708] | 12 | class TiXmlElement; // Forward declaration |
---|
[608] | 13 | |
---|
| 14 | namespace orxonox |
---|
| 15 | { |
---|
[708] | 16 | class ParticleInterface; // Forward declaration |
---|
| 17 | |
---|
[729] | 18 | class _OrxonoxExport SpaceShip : public Model, public OIS::MouseListener |
---|
[608] | 19 | { |
---|
| 20 | public: |
---|
| 21 | SpaceShip(); |
---|
| 22 | ~SpaceShip(); |
---|
[697] | 23 | void setConfigValues(); |
---|
[608] | 24 | virtual void loadParams(TiXmlElement* xmlElem); |
---|
| 25 | virtual void tick(float dt); |
---|
[736] | 26 | |
---|
[608] | 27 | bool mouseMoved(const OIS::MouseEvent &e); |
---|
[643] | 28 | bool mousePressed(const OIS::MouseEvent &e, OIS::MouseButtonID id); |
---|
| 29 | bool mouseReleased(const OIS::MouseEvent &e, OIS::MouseButtonID id); |
---|
[608] | 30 | |
---|
| 31 | |
---|
| 32 | private: |
---|
[786] | 33 | Vector3 testvector_; |
---|
[647] | 34 | bool bInvertYAxis_; |
---|
[608] | 35 | bool setMouseEventCallback_; |
---|
[644] | 36 | bool bLMousePressed_; |
---|
| 37 | bool bRMousePressed_; |
---|
[608] | 38 | |
---|
[644] | 39 | Ogre::SceneNode* camNode_; |
---|
| 40 | |
---|
[708] | 41 | ParticleInterface* tt_; |
---|
[608] | 42 | |
---|
[633] | 43 | BillboardSet redBillboard_; |
---|
| 44 | BillboardSet greenBillboard_; |
---|
| 45 | Ogre::SceneNode* redNode_; |
---|
| 46 | Ogre::SceneNode* greenNode_; |
---|
| 47 | float blinkTime_; |
---|
| 48 | |
---|
[661] | 49 | BillboardSet crosshairNear_; |
---|
| 50 | BillboardSet crosshairFar_; |
---|
| 51 | Ogre::SceneNode* chNearNode_; |
---|
| 52 | Ogre::SceneNode* chFarNode_; |
---|
| 53 | |
---|
[643] | 54 | float timeToReload_; |
---|
| 55 | float reloadTime_; |
---|
| 56 | |
---|
[647] | 57 | float maxSideAndBackSpeed_; |
---|
| 58 | float maxSpeed_; |
---|
| 59 | float maxRotation_; |
---|
| 60 | float translationAcceleration_; |
---|
| 61 | float rotationAcceleration_; |
---|
| 62 | float translationDamping_; |
---|
| 63 | float rotationDamping_; |
---|
| 64 | |
---|
| 65 | Radian maxRotationRadian_; |
---|
| 66 | Radian rotationAccelerationRadian_; |
---|
| 67 | Radian rotationDampingRadian_; |
---|
| 68 | Radian zeroRadian_; |
---|
| 69 | Radian mouseXRotation_; |
---|
| 70 | Radian mouseYRotation_; |
---|
| 71 | |
---|
| 72 | float mouseX_; |
---|
| 73 | float mouseY_; |
---|
| 74 | |
---|
[626] | 75 | int emitterRate_; |
---|
[608] | 76 | }; |
---|
[729] | 77 | ExportClass(SpaceShip, Orxonox); |
---|
[608] | 78 | } |
---|
| 79 | |
---|
[673] | 80 | #endif /* _SpaceShip_H__ */ |
---|