Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/branches/terrain.old/src/world_entities/creatures/fps_player.h @ 10763

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

merged the presentation back

File size: 1.6 KB
Line 
1/*!
2 * @file fps_player.h
3 * Implements a playable for fps games
4 */
5
6#ifndef _FPS_PLAYER_H
7#define _FPS_PLAYER_H
8
9
10#include "playable.h"
11
12
13class AimingSystem;
14
15
16class FPSPlayer : public Playable
17{
18
19  public:
20    FPSPlayer(const TiXmlElement* root = NULL);
21    virtual ~FPSPlayer();
22
23    virtual void loadParams(const TiXmlElement* root);
24
25    virtual void setPlayDirection(const Quaternion& rot, float speed = 0.0f);
26
27    virtual void enter();
28    virtual void leave();
29
30    virtual void reset();
31
32    virtual void destroy(WorldEntity* killer);
33    virtual void respawn();
34
35    virtual void tick(float time);
36    virtual void draw() const;
37
38
39    virtual void process(const Event &event);
40
41  private:
42    void init();
43
44    bool                  bLeft;
45    bool                  bRight;
46    bool                  bForward;
47    bool                  bBackward;
48    bool                  bJump;              //!< jumping
49    bool                  bPosBut;             //!< position button
50    bool                  bFire;              //!< fire button
51
52    float                 xMouse;             //!< mouse moved in x-Direction
53    float                 yMouse;             //!< mouse moved in y-Direction
54
55
56    float                 heading;
57    float                 attitude;
58
59    PNode                 cameraNode;
60
61    float                 fallVelocity;        //!< velocity for falling down
62    float                 jumpForce;           //!< the jump force
63
64    bool                  initWeapon;
65
66    AimingSystem*         aimingSystem;        //!< aiming system of the player
67
68    float                 damageTicker;        //!< ticker for dealing damage
69};
70
71#endif
Note: See TracBrowser for help on using the repository browser.