projects
/
supertux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
updated French translation
[supertux.git]
/
src
/
door.h
diff --git
a/src/door.h
b/src/door.h
index
c66b8cd
..
50d0138
100644
(file)
--- a/
src/door.h
+++ b/
src/door.h
@@
-22,17
+22,27
@@
#include <string>
#include <string>
+#include "video/surface.h"
#include "interactive_object.h"
#include "serializable.h"
#include "interactive_object.h"
#include "serializable.h"
+#include "special/timer.h"
+namespace SuperTux {
class Sprite;
class Sprite;
-
class LispReader;
class LispReader;
+}
+
+/** data images */
+#define DOOR_OPENING_TIME 1500
+#define DOOR_OPENING_FRAMES 8
+extern Sprite* door;
+extern Surface* door_opening[DOOR_OPENING_FRAMES];
class Door : public InteractiveObject, public Serializable
{
public:
Door(LispReader& reader);
class Door : public InteractiveObject, public Serializable
{
public:
Door(LispReader& reader);
+ Door(int x, int y);
virtual ~Door();
virtual void write(LispWriter& writer);
virtual ~Door();
virtual void write(LispWriter& writer);
@@
-42,9
+52,10
@@
public:
virtual void interaction(InteractionType type);
private:
virtual void interaction(InteractionType type);
private:
- Sprite* sprite;
std::string target_sector;
std::string target_spawnpoint;
std::string target_sector;
std::string target_spawnpoint;
+ Timer animation_timer; //Used for door animation
+ bool door_activated;
};
#endif /*SUPERTUX_DOOR_H*/
};
#endif /*SUPERTUX_DOOR_H*/