Huge code merge. This reflects the current status of my rewrite/restructuring. A...
[supertux.git] / src / special.h
1 //
2 // C Interface: special
3 //
4 // Description: 
5 //
6 //
7 // Author: Tobias Glaesser <tobi.web@gmx.de>, (C) 2004
8 //
9 // Copyright: See COPYING file that comes with this distribution
10 //
11 //
12
13 #define BULLET_STARTING_YM 1
14 #define BULLET_XM 5
15 #define NUM_BULLETS 3
16
17 #ifndef SUPERTUX_SPECIAL_H
18 #define SUPERTUX_SPECIAL_H
19
20 #include <SDL.h>
21 #include "bitmask.h"
22 #include "type.h"
23 #include "collision.h"
24
25 typedef struct upgrade_type
26   {
27     int alive;
28     int kind;
29     float x;
30     float y;
31     float xm;
32     float ym;
33     float width;
34     float height;
35     unsigned int updated;
36     itop_type it; 
37   }
38 upgrade_type;
39
40 typedef struct bullet_type
41   {
42     int alive;
43     float x;
44     float y;
45     float xm;
46     float ym;
47     float width;
48     float height;
49     unsigned int updated;
50     itop_type it; 
51   }
52 bullet_type;
53
54 texture_type img_bullet;
55 bitmask* bm_bullet;
56
57 void create_special_bitmasks();
58
59 texture_type img_golden_herring;
60
61 void upgrade_init(upgrade_type *pupgrade);
62 void upgrade_action(upgrade_type *pupgrade);
63 void upgrade_draw(upgrade_type *pupgrade);
64 void upgrade_collision(upgrade_type *pupgrade, void* p_c_object, int c_object);
65
66 void bullet_init(bullet_type *pbullet);
67 void bullet_action(bullet_type *pbullet);
68 void bullet_draw(bullet_type *pbullet);
69 void bullet_collision(bullet_type *pbullet, int c_object);
70
71 #endif /*SUPERTUX_SPECIAL_H*/