Orxonox  0.0.5 Codename: Arcturus
Pacman.h
Go to the documentation of this file.
1 /*
2  * ORXONOX - the hottest 3D action shooter ever to exist
3  * > www.orxonox.net <
4  *
5  *
6  * License notice:
7  *
8  * This program is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU General Public License
10  * as published by the Free Software Foundation; either version 2
11  * of the License, or (at your option) any later version.
12  *
13  * This program is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License
19  * along with this program; if not, write to the Free Software
20  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
21  *
22  * Author:
23  * Marc Dreher
24  * Co-authors:
25  * ...
26  *
27  */
28 
35 #ifndef _Pacman_H__
36 #define _Pacman_H__
37 
38 #include "PacmanGelb.h"
39 #include "PacmanGhost.h"
40 #include "PacmanPointSphere.h"
41 #include "PacmanPointAfraid.h"
42 
43 
44 #include "core/EventIncludes.h"
45 #include "core/command/Executor.h"
47 
48 #include "gamestates/GSLevel.h"
49 #include "chat/ChatManager.h"
50 #include <vector>
51 
52 // ! HACK
53 #include "infos/PlayerInfo.h"
54 
56 
57 #include "gametypes/Deathmatch.h"
58 #include "tools/Timer.h"
59 
60 namespace orxonox
61 {
62 
64  {
65  public:
66  Pacman(Context* context);
67 
68  virtual void start() override;
69  virtual void end() override;
70 
71  virtual void tick(float dt) override;
72 
73  PacmanGelb* getPlayer();
74  int getPoints();
75  bool getAfraid();
76  int getTimer();
77  int getLives();
78  int getLevel();
79  int getTotalpoints();
80  bool isdead();
81 
82  private:
83 
84  void levelUp();
85  bool collis(Vector3 one, Vector3 other);
86  void catched(float dt);
87  void posreset();
88  void takePoint(PacmanPointSphere* taken);
89  void setAfraid();
90  void setNormal();
91  void dead(float dt);
92 
94  Vector3 currentPosition;
95  Vector3 startposplayer = Vector3(0,10,150);
96  bool bcolli = false;
97 
99 
100  bool afraid = false;
101  bool death = false;
102  float deathtime = 0;
103  float timer = 0;
104 
105  int level;
106  int point;
107  int lives;
108 
109  };
110 }
111 
112 #endif /* _Pacman_H__ */
Definition: PacmanGelb.h:47
int totallevelpoint
Definition: Pacman.h:98
int point
Definition: Pacman.h:106
Vector3 currentPosition
Definition: Pacman.h:94
PacmanGelb * player
Definition: Pacman.h:93
int lives
Definition: Pacman.h:107
Declaration of the Timer class, used to call functions after a given time-interval.
Declaration of the orxonox::Executor class and the createExecutor() functions.
Die Wagnis Klasse hat die folgenden Aufgaben:
Definition: ApplicationPaths.cc:66
Declaration of the orxonox::ConsoleCommand class.
int level
Definition: Pacman.h:105
Definition: Context.h:45
Definition: Pacman.h:63
Definition: Deathmatch.h:37
#define _PacmanExport
Definition: PacmanPrereqs.h:60
Definition: PacmanPointSphere.h:40
Definition of the XMLPortEventState() macro, as well as some more useful macros.
Definition of macros and functions for config-values.