Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/trunk/src/world_entities/space_ships/helicopter.h @ 6005

Last change on this file since 6005 was 6005, checked in by bensch, 18 years ago

orxonox/trunk: automatic LOD-loading

File size: 2.1 KB
Line 
1
2/*!
3 * @file helicopter.h
4 * Implements the Control of a Helicopter
5 */
6
7#ifndef _HELICOPTER_H
8#define _HELICOPTER_H
9
10#include "playable.h"
11
12
13class Helicopter : public Playable
14{
15
16  public:
17
18    Helicopter();
19    Helicopter(const char* fileName);
20    Helicopter(const TiXmlElement* root);
21    virtual ~Helicopter();
22
23    void init();
24    void loadParams(const TiXmlElement* root);
25
26    void addWeapon(Weapon* weapon );
27    void removeWeapon(Weapon* weapon);
28
29    virtual void postSpawn();
30    virtual void leftWorld();
31
32    virtual void collidesWith(WorldEntity* entity, const Vector& location);
33    virtual void tick(float time);
34    virtual void draw() const;
35
36    virtual void process(const Event &event);
37
38
39
40  private:
41
42    void calculateVelocity(float time);
43    void weaponAction();
44
45    // !! temporary !!
46    void ADDWEAPON();
47
48    bool                  bUp;                //!< up button pressed.
49    bool                  bDown;              //!< down button pressed.
50    bool                  bLeft;              //!< left button pressed.
51    bool                  bRight;             //!< right button pressed.
52    bool                  bAscend;            //!< ascend button pressed.
53    bool                  bDescend;           //!< descend button presses.
54    bool                  bFire;              //!< fire button pressed.
55    bool                  bRollL;             //!< rolling button pressed (left)
56    bool                  bRollR;             //!< rolling button pressed (right)
57
58    float                 xMouse;             //!< mouse moved in x-Direction
59    float                 yMouse;             //!< mouse moved in y-Direction
60    float                 mouseSensitivity;   //!< the mouse sensitivity
61    float                 cycle;              //!< hovercycle
62
63    Vector                velocity;           //!< the velocity of the player.
64    Vector                velocityDir;        //!< the direction of the velocity of the spaceship
65    float                 travelSpeed;        //!< the current speed of the player (to make soft movement)
66    float                 acceleration;       //!< the acceleration of the player.
67
68};
69
70#endif /* _HELICOPTERS_H */
Note: See TracBrowser for help on using the repository browser.