~kubuntu-members/kapman/4.11

68 by Thomas Gallinari
- Improving about dialog
1
/*
102 by Thomas Gallinari
A piece of refactoring and a bug fixing due to a bad pause management
2
 * Copyright 2007-2008 Thomas Gallinari <tg8187@yahoo.fr>
46 by Thomas Gallinari
Modifying copyright headers
3
 * Copyright 2007-2008 Gaƫl Courcelle <gael.courcelle@gmail.com>
4
 * Copyright 2007-2008 Alexia Allanic <alexia_allanic@yahoo.fr>
5
 * 
6
 * This program is free software; you can redistribute it and/or
7
 * modify it under the terms of the GNU General Public License as
8
 * published by the Free Software Foundation; either version 2 of 
9
 * the License, or (at your option) any later version.
10
 * 
11
 * This program is distributed in the hope that it will be useful,
12
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14
 * GNU General Public License for more details.
15
 * 
16
 * You should have received a copy of the GNU General Public License
17
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
18
 */
41 by Johann Hingue
Display Pills & Energizers
19
172 by Thomas Gallinari
- Added context to a few i18n calls
20
#ifndef PILL_H
21
#define PILL_H
57 by Thomas Gallinari
Collisions improved :
22
41 by Johann Hingue
Display Pills & Energizers
23
#include "element.h"
24
25
/**
102 by Thomas Gallinari
A piece of refactoring and a bug fixing due to a bad pause management
26
 * @brief This class represents a Pill enabling to earn points.
41 by Johann Hingue
Display Pills & Energizers
27
 */
28
class Pill : public Element {
29
30
	public:
31
102 by Thomas Gallinari
A piece of refactoring and a bug fixing due to a bad pause management
32
		/** The Pill value */
54 by Thomas Gallinari
- For each 10,000 points we get one more life
33
		static const int POINTS;
41 by Johann Hingue
Display Pills & Energizers
34
35
	public:
36
37
		/**
102 by Thomas Gallinari
A piece of refactoring and a bug fixing due to a bad pause management
38
		 * Creates a new Pill instance.
41 by Johann Hingue
Display Pills & Energizers
39
		 */
125 by Pierre-Benoit Besse
- All images are now in a single SVG file
40
		Pill(qreal p_x, qreal p_y, Maze* p_maze, const QString& p_imageId);
41 by Johann Hingue
Display Pills & Energizers
41
42
		/**
102 by Thomas Gallinari
A piece of refactoring and a bug fixing due to a bad pause management
43
		 * Deletes the Pill instance.
41 by Johann Hingue
Display Pills & Energizers
44
		 */
45
		~Pill();
46
47
		/**
102 by Thomas Gallinari
A piece of refactoring and a bug fixing due to a bad pause management
48
		 * Computes an action on a collision with the Kapman.
49
		 * @param p_kapman the instance of Kapman which collides with the Pill
41 by Johann Hingue
Display Pills & Energizers
50
		 */
51
		void doActionOnCollision(Kapman* p_kapman);
52
};
53
54
#endif
102 by Thomas Gallinari
A piece of refactoring and a bug fixing due to a bad pause management
55