1 #ifndef INCLUDED_BADGE_JUMPNRUN_SHOTS_H
2 #define INCLUDED_BADGE_JUMPNRUN_SHOTS_H
4 #include "../ui/display.h"
5 #include "../util/util.h"
9 typedef struct jumpnrun_shot
{
11 rectangle current_box
;
17 JUMPNRUN_SHOT_EXTENT
= 3,
18 JUMPNRUN_SHOT_TICKS_PER_FRAME
= 36,
19 JUMPNRUN_SHOT_FRAMES
= 2
22 static inline bool jumpnrun_shot_spawned(jumpnrun_shot
const *shot
) { return fixed_point_ne(shot
->inertia
.x
, FIXED_INT(0)); }
23 static inline void jumpnrun_shot_despawn(jumpnrun_shot
*shot
) { shot
->inertia
.x
= FIXED_INT(0); }
25 void jumpnrun_shot_process(jumpnrun_shot
*shot
);