moved savelevel() code to level.h/c where it belongs to. :)
[supertux.git] / src / special.h
index 3ad4da8..dfd9b1d 100644 (file)
@@ -12,7 +12,6 @@
 
 #define BULLET_STARTING_YM 1
 #define BULLET_XM 5
-#define NUM_BULLETS 3
 
 #ifndef SUPERTUX_SPECIAL_H
 #define SUPERTUX_SPECIAL_H
 #include <SDL.h>
 #include "bitmask.h"
 #include "type.h"
+#include "texture.h"
 #include "collision.h"
+#include "player.h"
 
 typedef struct upgrade_type
   {
-    int alive;
     int kind;
-    float x;
-    float y;
-    float xm;
-    float ym;
-    float width;
-    float height;
-    unsigned int updated;
-    itop_type it; 
+    base_type base;
   }
 upgrade_type;
 
 typedef struct bullet_type
   {
-    int alive;
-    float x;
-    float y;
-    float xm;
-    float ym;
-    float width;
-    float height;
-    unsigned int updated;
-    itop_type it; 
+    base_type base;
   }
 bullet_type;
 
@@ -58,12 +43,12 @@ void create_special_bitmasks();
 
 texture_type img_golden_herring;
 
-void upgrade_init(upgrade_type *pupgrade);
+void upgrade_init(upgrade_type *pupgrade, float x, float y, int kind);
 void upgrade_action(upgrade_type *pupgrade);
 void upgrade_draw(upgrade_type *pupgrade);
 void upgrade_collision(upgrade_type *pupgrade, void* p_c_object, int c_object);
 
-void bullet_init(bullet_type *pbullet);
+void bullet_init(bullet_type* pbullet, float x, float y, float xm, int dir);
 void bullet_action(bullet_type *pbullet);
 void bullet_draw(bullet_type *pbullet);
 void bullet_collision(bullet_type *pbullet, int c_object);