1 #ifndef INCLUDED_BADGE2013_JUMPNRUN_H
2 #define INCLUDED_BADGE2013_JUMPNRUN_H
9 #include <badge/util/fixed_point.h>
10 #include <badge/util/rectangle.h>
11 #include <badge/ui/sprite.h>
24 JUMPNRUN_MAX_SPAWN_MARGIN
= BADGE_SPRITE_MAX_WIDTH
+ 1,
25 JUMPNRUN_MAX_SPAWNED_ENEMIES
= 10
28 typedef struct jumpnrun_game_state
{
35 uint8_t anim_direction
;
40 uint8_t jumpable_frames
;
42 size_t spawned_enemies_counter
;
43 size_t spawned_enemies
[JUMPNRUN_MAX_SPAWNED_ENEMIES
];
44 } jumpnrun_game_state
;
46 rectangle
hacker_rect_current(jumpnrun_game_state
const *state
);
49 void jumpnrun_passive_movement(vec2d
*inertia
);
51 uint8_t jumpnrun_play(char const *lvname
);