1 | /* |
---|
2 | * ORXONOX - the hottest 3D action shooter ever to exist |
---|
3 | * |
---|
4 | * |
---|
5 | * License notice: |
---|
6 | * |
---|
7 | * This program is free software: you can redistribute it and/or modify |
---|
8 | * it under the terms of the GNU General Public License as published by |
---|
9 | * the Free Software Foundation, either version 3 of the License, or |
---|
10 | * (at your option) any later version. |
---|
11 | * |
---|
12 | * This program is distributed in the hope that it will be useful, |
---|
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
15 | * GNU General Public License for more details. |
---|
16 | * |
---|
17 | * You should have received a copy of the GNU General Public License |
---|
18 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
---|
19 | * |
---|
20 | * |
---|
21 | * Author: |
---|
22 | * Reto Grieder |
---|
23 | * Co-authors: |
---|
24 | * ... |
---|
25 | * |
---|
26 | */ |
---|
27 | |
---|
28 | |
---|
29 | #ifndef ORXONOX_SHIP_H |
---|
30 | #define ORXONOX_SHIP_H |
---|
31 | |
---|
32 | #include "OgrePrerequisites.h" |
---|
33 | |
---|
34 | #include "orxonox_prerequisites.h" |
---|
35 | |
---|
36 | |
---|
37 | namespace orxonox { |
---|
38 | |
---|
39 | class OrxonoxShip |
---|
40 | { |
---|
41 | public: |
---|
42 | OrxonoxShip(Ogre::SceneManager*, Ogre::SceneNode*, weapon::BulletManager*); |
---|
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 | InertialNode* getRootNode(); |
---|
54 | Ogre::Vector3 getSpeed(); |
---|
55 | |
---|
56 | weapon::BaseWeapon* getMainWeapon(); |
---|
57 | |
---|
58 | int getAmmoStock(); |
---|
59 | |
---|
60 | bool tick(unsigned long, Ogre::Real); |
---|
61 | |
---|
62 | protected: |
---|
63 | |
---|
64 | protected: |
---|
65 | Ogre::SceneManager *sceneMgr_; |
---|
66 | //Ogre::SceneNode *rootNode_; |
---|
67 | InertialNode *rootNode_; |
---|
68 | Ogre::Entity *shipEntity_; |
---|
69 | |
---|
70 | //Ogre::Vector3 currentSpeed_; // relative to space |
---|
71 | Ogre::Vector3 currentThrust_; // relative to the ship |
---|
72 | Ogre::Real baseThrust_; |
---|
73 | int objectCounter_; |
---|
74 | |
---|
75 | weapon::BulletManager *bulletManager_; |
---|
76 | //Ogre::Vector3 bulletSpeed_; |
---|
77 | |
---|
78 | weapon::BaseWeapon *mainWeapon_; |
---|
79 | weapon::WeaponStation *railGunStation_; |
---|
80 | |
---|
81 | weapon::AmmunitionDump *ammoDump_; |
---|
82 | }; |
---|
83 | |
---|
84 | } |
---|
85 | |
---|
86 | #endif /* ORXONOX_SHIP_H */ |
---|