DungeonCrawl
Loading...
Searching...
No Matches
game.h
Go to the documentation of this file.
1
5#ifndef GAME_H
6#define GAME_H
7
8#include "database/database.h"
9
10// Define colors with notcurses
11#define COLOR_FG_RGB 255, 255, 255// White
12#define COLOR_BG_RGB 0, 0, 0 // Black
13
14// Global notcurses instance and plane
15extern struct notcurses* nc;
16extern struct ncplane* stdplane;
17
18typedef enum {
19 MAIN_MENU,
20 MAP_MODE,
21 COMBAT_MODE,
22 LOOT_MODE,
23 INVENTORY_MODE,
24 GENERATE_MAP,
25 STATS_MODE,
26 EXIT
27} game_state_t;
28
29extern db_connection_t db_connection;
30
37void run_game();
38
46void main_menu_state();
47
55void map_mode_state();
56
65
73void loot_mode_state();
74
75#endif// GAME_H
Exposes functions for working with the database.
void loot_mode_state()
Handles the loot mode state of the game.
Definition game.c:238
void run_game()
Starts the game loop.
Definition game.c:62
void inventory_mode_state()
Handles the inventory mode state of the game.
Definition game.c:249
void main_menu_state()
Handles the main menu state of the game.
Definition game.c:115
void map_mode_state()
Handles the map mode state of the game.
Definition game.c:186
This struct is used for the database connection in SQLite.
Definition database.h:22