summaryrefslogtreecommitdiffstats
path: root/pacman-c++/actor.h
diff options
context:
space:
mode:
Diffstat (limited to 'pacman-c++/actor.h')
-rw-r--r--pacman-c++/actor.h15
1 files changed, 8 insertions, 7 deletions
diff --git a/pacman-c++/actor.h b/pacman-c++/actor.h
index 78b7c01..19d672b 100644
--- a/pacman-c++/actor.h
+++ b/pacman-c++/actor.h
@@ -23,7 +23,8 @@ public:
23 }; 23 };
24 24
25 Actor(Color::Color color, bool local = false, QGraphicsItem *parent = 0); 25 Actor(Color::Color color, bool local = false, QGraphicsItem *parent = 0);
26 virtual ~Actor() {}; 26 virtual ~Actor()
27 {};
27 28
28 QSequentialAnimationGroup *setupEatingAnimation(Actor::Movement direction); 29 QSequentialAnimationGroup *setupEatingAnimation(Actor::Movement direction);
29 Color::Color getColor(); 30 Color::Color getColor();
@@ -34,11 +35,10 @@ public:
34 void die(); 35 void die();
35 void eatingCherry(); 36 void eatingCherry();
36 37
37 unsigned int getRoundPoints() { return m_roundPoints; } 38 unsigned int getRoundPoints();
38 unsigned int getGamePoints() { return m_gamePoints; } 39 unsigned int getGamePoints();
39 40 void addRoundPoints(unsigned int amount);
40 void addRoundPoints(unsigned int amount) { m_roundPoints += amount; } 41 void finishRound();
41 void finishRound() { m_gamePoints += m_roundPoints; m_roundPoints = 0; }
42 42
43private: 43private:
44 QPixmap m_pix; 44 QPixmap m_pix;
@@ -48,7 +48,8 @@ private:
48 bool m_local; 48 bool m_local;
49 AudioPlayer *m_player; 49 AudioPlayer *m_player;
50 50
51 unsigned int m_roundPoints, m_gamePoints; 51 unsigned int m_roundPoints;
52 unsigned int m_gamePoints;
52 53
53 QList<PixmapItem *> m_images; 54 QList<PixmapItem *> m_images;
54 QList<QSequentialAnimationGroup *> m_eating; 55 QList<QSequentialAnimationGroup *> m_eating;