implemented a new object factory mechanism which is now really independent of the...
[supertux.git] / src / object / coin.h
1 #ifndef __COIN_H__
2 #define __COIN_H__
3
4 #include "special/moving_object.h"
5 #include "lisp/lisp.h"
6
7 namespace SuperTux {
8   class Sprite;
9 }
10
11 using namespace SuperTux;
12
13 class Coin : public MovingObject
14 {
15 public:
16   Coin(const Vector& pos);
17   Coin(const lisp::Lisp& reader);
18   ~Coin();
19
20   HitResponse collision(GameObject& other, const CollisionHit& hit);
21   void action(float elapsed_time);
22   void draw(DrawingContext& context);
23
24   void collect();
25
26 private:
27   Sprite* sprite;
28 };
29
30 #endif
31