[209] | 1 | #ifndef SPACESHIP_STEERING_H |
---|
| 2 | #define SPACESHIP_STEERING_H |
---|
| 3 | |
---|
| 4 | #include "OgrePrerequisites.h" |
---|
| 5 | |
---|
| 6 | class SpaceshipSteering |
---|
| 7 | { |
---|
| 8 | public: |
---|
| 9 | SpaceshipSteering(float maxSpeedForward, float maxSpeedRotateUpDown, |
---|
| 10 | float maxSpeedRotateRightLeft, float maxSpeedLoopRightLeft); |
---|
| 11 | void tick(float time); |
---|
| 12 | void moveForward(float moveForward); |
---|
| 13 | void rotateUp(float rotateUp); |
---|
| 14 | void rotateDown(float rotateDown); |
---|
| 15 | void rotateRight(float rotateRight); |
---|
| 16 | void rotateLeft(float rotateLeft); |
---|
| 17 | void loopRight(float loopRight); |
---|
| 18 | void loopLeft(float loopLeft); |
---|
[317] | 19 | void brakeForward(float brakeForward); |
---|
| 20 | void brakeRotate(float brakeRotate); |
---|
| 21 | void brakeLoop(float brakeLoop); |
---|
[209] | 22 | void maxSpeedForward(float maxSpeedForward); |
---|
| 23 | void maxSpeedRotateUpDown(float maxSpeedRotateUpDown); |
---|
| 24 | void maxSpeedRotateRightLeft(float maxSpeedRotateRightLeft); |
---|
| 25 | void maxSpeedLoopRightLeft(float maxSpeedLoopRightLeft); |
---|
| 26 | void addNode(Ogre::SceneNode *steeringNode); |
---|
| 27 | |
---|
| 28 | protected: |
---|
| 29 | Ogre::SceneNode *steeringNode_; |
---|
| 30 | |
---|
| 31 | private: |
---|
| 32 | float moveForward_; |
---|
| 33 | float rotateUp_; |
---|
| 34 | float rotateDown_; |
---|
| 35 | float rotateRight_; |
---|
| 36 | float rotateLeft_; |
---|
| 37 | float loopRight_; |
---|
| 38 | float loopLeft_; |
---|
[317] | 39 | float brakeForward_; |
---|
| 40 | float brakeRotate_; |
---|
| 41 | float brakeLoop_; |
---|
[209] | 42 | |
---|
| 43 | float speedForward_; |
---|
| 44 | float speedRotateUpDown_; |
---|
| 45 | float speedRotateRightLeft_; |
---|
| 46 | float speedLoopRightLeft_; |
---|
| 47 | |
---|
| 48 | float maxSpeedForward_; |
---|
| 49 | float maxSpeedRotateUpDown_; |
---|
| 50 | float maxSpeedRotateRightLeft_; |
---|
| 51 | float maxSpeedLoopRightLeft_; |
---|
| 52 | |
---|
| 53 | float accelerationForward_; |
---|
| 54 | float accelerationRotateUpDown_; |
---|
| 55 | float accelerationRotateRightLeft_; |
---|
| 56 | float accelerationLoopRightLeft_; |
---|
| 57 | |
---|
| 58 | }; |
---|
| 59 | |
---|
| 60 | #endif |
---|