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 | * Florian Zinggeler |
---|
24 | * Co-authors: |
---|
25 | * ... |
---|
26 | * |
---|
27 | */ |
---|
28 | |
---|
29 | /** |
---|
30 | @file DodgeRace.h |
---|
31 | @brief Gametype. |
---|
32 | @ingroup DodgeRace |
---|
33 | */ |
---|
34 | |
---|
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 | #include "Highscore.h" |
---|
43 | //#include "PlayerInfo.h" |
---|
44 | |
---|
45 | |
---|
46 | #include "core/EventIncludes.h" |
---|
47 | #include "core/command/Executor.h" |
---|
48 | #include "core/config/ConfigValueIncludes.h" |
---|
49 | |
---|
50 | #include "gamestates/GSLevel.h" |
---|
51 | #include "chat/ChatManager.h" |
---|
52 | #include <vector> |
---|
53 | |
---|
54 | // ! HACK |
---|
55 | #include "infos/PlayerInfo.h" |
---|
56 | |
---|
57 | #include "core/command/ConsoleCommand.h" |
---|
58 | |
---|
59 | #include "gametypes/Deathmatch.h" |
---|
60 | #include "tools/Timer.h" |
---|
61 | |
---|
62 | namespace orxonox |
---|
63 | { |
---|
64 | |
---|
65 | class _PacmanExport Pacman : public Deathmatch |
---|
66 | { |
---|
67 | public: |
---|
68 | Pacman(Context* context); |
---|
69 | |
---|
70 | virtual void start() override; |
---|
71 | virtual void end() override; |
---|
72 | |
---|
73 | virtual void tick(float dt) override; |
---|
74 | |
---|
75 | void levelUp(); |
---|
76 | bool collis(Vector3 one, Vector3 other); |
---|
77 | void catched(); |
---|
78 | void posreset(); |
---|
79 | void takePoint(PacmanPointSphere* taken); |
---|
80 | PacmanGelb* getPlayer(); |
---|
81 | int getPoints(); |
---|
82 | void setAfraid(); |
---|
83 | void setNormal(); |
---|
84 | |
---|
85 | |
---|
86 | bool bEndGame; |
---|
87 | bool bShowLevel; |
---|
88 | int lives; |
---|
89 | int multiplier; |
---|
90 | float counter; |
---|
91 | int pattern; |
---|
92 | float lastPosition; |
---|
93 | |
---|
94 | Vector3 currentPosition; |
---|
95 | PacmanGelb* player; |
---|
96 | bool bcolli = false; |
---|
97 | float timer = 0; |
---|
98 | Vector3 startposplayer = Vector3(0,10,245); |
---|
99 | int totallevelpoint = 3; |
---|
100 | //bool firstGame; |
---|
101 | bool afraid = false; |
---|
102 | |
---|
103 | private: |
---|
104 | |
---|
105 | |
---|
106 | Timer endGameTimer; |
---|
107 | int level; |
---|
108 | int point; |
---|
109 | bool b_combo; |
---|
110 | |
---|
111 | Timer enemySpawnTimer; |
---|
112 | Timer comboTimer; |
---|
113 | Timer showLevelTimer; |
---|
114 | |
---|
115 | /* |
---|
116 | std::string sDeathMessage; |
---|
117 | const std::vector<std::string> DeathMessage7 = { |
---|
118 | "You should really try that again", |
---|
119 | "You can do better, can you?", |
---|
120 | "Hey, maybe you get a participation award, that's good isn't it?", |
---|
121 | "Congratulations, you get a medal, a wooden one", |
---|
122 | "That was flappin bad!", |
---|
123 | "Well, that was a waste of time", |
---|
124 | "You suck!", |
---|
125 | "Maybe try SuperOrxoBros. That game is not as hard.", |
---|
126 | "Here's a tip: Try not to fly into these grey thingies.", |
---|
127 | "We won't comment on that."}; |
---|
128 | const std::vector<std::string> DeathMessage20 = { |
---|
129 | "Getting better!", |
---|
130 | "Training has paid off, huh?", |
---|
131 | "Good average!", |
---|
132 | "That was somehow enjoyable to watch", |
---|
133 | "Flappin average", |
---|
134 | "Getting closer to something", |
---|
135 | "That wasn't crap, not bad", |
---|
136 | "Surprisingly not bad."}; |
---|
137 | */ |
---|
138 | |
---|
139 | }; |
---|
140 | } |
---|
141 | |
---|
142 | #endif /* _Pacman_H__ */ |
---|