Began creating the listbox widget. It's still just a structure.
[xuni.git] / game.h
blobe5dd2e133762482834b051eccc1602be75c15d4d
1 #ifndef GAME_H
2 #define GAME_H
4 #include "graphics.h"
5 #include "loop.h"
7 enum game_mode_t {
8 GMODE_NORMAL,
9 GMODE_MENU
12 struct game_data_t {
13 int loaded;
14 enum game_mode_t mode;
15 struct {
16 struct widget_t widget[1];
17 size_t lastid;
19 struct {
20 struct widget_t widget[2];
21 } menu;
22 } gui;
25 void init_game(struct game_data_t *data, struct smode_t *smode,
26 struct font_t *font);
27 void resize_game_images(struct game_data_t *data, struct smode_t *smode,
28 struct font_t *font);
29 void start_game(struct game_data_t *data);
30 void game_event(enum loop_mode_t *mode, SDL_Event *event,
31 struct game_data_t *data, struct smode_t *smode, struct font_t *font,
32 struct theme_t *theme);
33 void paint_game(SDL_Surface *screen, struct game_data_t *data,
34 struct smode_t *smode, struct font_t *font, struct theme_t *theme);
35 void free_game(struct game_data_t *data);
37 #endif