2018-02-08 17:01:38 +01:00
|
|
|
#ifndef MENU_H_
|
|
|
|
#define MENU_H_
|
|
|
|
|
|
|
|
#include <SDL2/SDL.h>
|
|
|
|
#include "camera.h"
|
|
|
|
#include "linkedlist.h"
|
|
|
|
#include "texture.h"
|
|
|
|
#include "sprite.h"
|
|
|
|
|
|
|
|
typedef struct Menu_t {
|
|
|
|
LinkedList *items;
|
|
|
|
unsigned int selected;
|
|
|
|
} Menu;
|
|
|
|
|
|
|
|
Menu *
|
|
|
|
menu_create(void);
|
|
|
|
|
|
|
|
void
|
|
|
|
menu_handle_event(Menu*, SDL_Event*);
|
|
|
|
|
|
|
|
void
|
2018-02-09 07:26:44 +01:00
|
|
|
menu_item_add(Menu*, Sprite*, Sprite*, void (*)(void*));
|
2018-02-08 17:01:38 +01:00
|
|
|
|
|
|
|
void
|
|
|
|
menu_render(Menu*, Camera*);
|
|
|
|
|
|
|
|
void
|
|
|
|
menu_destroy(Menu*);
|
|
|
|
|
|
|
|
#endif // MENU_H_
|