01147c0d35
* Implement a simple state machine to simulate different game stats * Create a generic menu to display different menus * Update the Makefile for TTF support * Draw a simple diagram to show the stats
24 lines
429 B
C
24 lines
429 B
C
|
|
#ifndef MENU_H
|
|
#define MENU_H
|
|
|
|
#include "states.h"
|
|
#include "config.h"
|
|
|
|
struct menuItem {
|
|
char buttonDescription[30];
|
|
enum states targetState;
|
|
};
|
|
|
|
struct menuItem mainMenu[3];
|
|
struct menuItem numplayersMenu[4];
|
|
struct menuItem creditsMenu[1];
|
|
struct menuItem rlyquitMenu[2];
|
|
|
|
|
|
void handleMenuEvent(struct menuItem items[], int numItems, enum states prevState);
|
|
void drawMenu(struct menuItem items[], int numItems);
|
|
|
|
#endif
|
|
|