home · contact · privacy
Player earns a score by killing enemies.
[plomrogue] / src / main.h
1 /* main.h
2  *
3  * Contains the World struct holding all game data together.
4  */
5
6 #ifndef MAIN_H
7 #define MAIN_H
8
9
10
11 #include <stdint.h> /* for uint32_t*/
12 struct WinMeta;
13 struct Win;
14 struct KeyBinding;
15 struct KeysWinData;
16 struct Map;
17 struct ItemDef;
18 struct MonsterDef;
19
20
21
22 struct World
23 {
24     char interactive;                 /* 1: playing; 0: record playback. */
25     struct KeyBinding * keybindings;  /* Pointer to the keybindings. */
26     struct KeysWinData * keyswindata; /* Pointer to key edit window metadata. */
27     uint32_t seed;                    /* Randomness seed. */
28     uint32_t turn;                    /* Current game turn. */
29     uint16_t score;                   /* Player's score. */
30     char * log;                       /* Pointer to the game log string. */
31     struct Map * map;                 /* Pointer to the game map cells. */
32     struct ItemDef * item_def;        /* Pointer to the item definitions. */
33     struct Item * item;               /* Pointer to the items' data. */
34     struct MonsterDef * monster_def;  /* Pointer to the monster definitions. */
35     struct Monster * monster;         /* Pointer to the monsters' data. */
36     struct Player * player;           /* Pointer to the player data. */
37 };
38
39
40
41 #endif