Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/branches/bsp_model/src/world_entities/creatures/fps_player.h @ 8686

Last change on this file since 8686 was 8686, checked in by patrick, 18 years ago

bsp: fps player extension

File size: 1.1 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 FPSPlayer : public Playable
14{
15
16  public:
17    FPSPlayer(const TiXmlElement* root = NULL);
18    virtual ~FPSPlayer();
19
20    virtual void loadParams(const TiXmlElement* root);
21
22    virtual void setPlayDirection(const Quaternion& rot, float speed = 0.0f);
23
24    virtual void enter();
25    virtual void leave();
26
27    virtual void reset();
28
29
30    virtual void tick(float time);
31    virtual void draw() const;
32
33
34    virtual void process(const Event &event);
35
36  private:
37    void init();
38
39    bool                  bLeft;
40    bool                  bRight;
41    bool                  bForward;
42    bool                  bBackward;
43    bool                  bJump;              //!< jumping
44
45    float                 xMouse;             //!< mouse moved in x-Direction
46    float                 yMouse;             //!< mouse moved in y-Direction
47    Quaternion            mouseDir;           //!< the direction where the player wants to fly
48
49    float                 angleX;
50    float                 angleY;
51
52};
53
54#endif
Note: See TracBrowser for help on using the repository browser.