]> git.lizzy.rs Git - nothing.git/blob - src/game.h
(#59) Introduce background entity
[nothing.git] / src / game.h
1 #ifndef GAME_H_
2 #define GAME_H_
3
4 #include <SDL2/SDL.h>
5
6 #include "game/sound_medium.h"
7
8 typedef struct game_t game_t;
9
10 game_t *create_game(const char *platforms_file_path,
11                     sound_medium_t *sound_medium);
12 void destroy_game(game_t *game);
13
14 int game_render(const game_t *game, SDL_Renderer *renderer);
15 int game_sound(game_t *game);
16 int game_update(game_t *game, float delta_time);
17
18 int game_event(game_t *game, const SDL_Event *event);
19 int game_input(game_t *game,
20                const Uint8 *const keyboard_state,
21                SDL_Joystick *the_stick_of_joy);
22
23 int game_over_check(const game_t *game);
24
25 #endif  // GAME_H_