diff options
Diffstat (limited to 'pacman-c++/actor.h')
| -rw-r--r-- | pacman-c++/actor.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/pacman-c++/actor.h b/pacman-c++/actor.h index 389d7c6..eb04c71 100644 --- a/pacman-c++/actor.h +++ b/pacman-c++/actor.h | |||
| @@ -16,7 +16,7 @@ Q_OBJECT | |||
| 16 | public: | 16 | public: |
| 17 | enum Movement | 17 | enum Movement |
| 18 | { | 18 | { |
| 19 | None = 0, | 19 | None = 0, |
| 20 | Left, | 20 | Left, |
| 21 | Right, | 21 | Right, |
| 22 | Up, | 22 | Up, |
| @@ -34,7 +34,7 @@ public: | |||
| 34 | 34 | ||
| 35 | PixmapItem &icon(); | 35 | PixmapItem &icon(); |
| 36 | Movement direction(); | 36 | Movement direction(); |
| 37 | void resetDirection(); | 37 | void resetAnimation(); |
| 38 | bool isLocal(); | 38 | bool isLocal(); |
| 39 | void move(Movement direction); | 39 | void move(Movement direction); |
| 40 | bool isMoving(); | 40 | bool isMoving(); |
| @@ -48,7 +48,7 @@ public: | |||
| 48 | unsigned int getRoundPoints(); | 48 | unsigned int getRoundPoints(); |
| 49 | unsigned int getGamePoints(); | 49 | unsigned int getGamePoints(); |
| 50 | void addRoundPoints(unsigned int amount); | 50 | void addRoundPoints(unsigned int amount); |
| 51 | void finishRound(); | 51 | void finishRound(bool died = false); |
| 52 | 52 | ||
| 53 | static QPoint movementToPoint(const Actor::Movement direction); | 53 | static QPoint movementToPoint(const Actor::Movement direction); |
| 54 | 54 | ||
| @@ -69,6 +69,7 @@ private: | |||
| 69 | QList<PixmapItem *> m_images; | 69 | QList<PixmapItem *> m_images; |
| 70 | QList<QSequentialAnimationGroup *> m_eating; | 70 | QList<QSequentialAnimationGroup *> m_eating; |
| 71 | QParallelAnimationGroup *m_moving; | 71 | QParallelAnimationGroup *m_moving; |
| 72 | QSequentialAnimationGroup *m_dieing; | ||
| 72 | }; | 73 | }; |
| 73 | 74 | ||
| 74 | #endif // ACTOR_H | 75 | #endif // ACTOR_H |
