#ifndef COMMON_H #define COMMON_H #include "settings.h" // Tile types typedef enum { TILE_WALL, TILE_FLOOR, TILE_STAIRS } TileType; // Room typedef struct { int x, y, w, h; } Room; // Map typedef struct { TileType tiles[MAP_HEIGHT][MAP_WIDTH]; Room rooms[MAX_ROOMS]; int room_count; } Map; // Dungeon typedef struct { int current_floor; Room rooms[MAX_ROOMS]; int room_count; } Dungeon; // Item types typedef enum { ITEM_POTION, ITEM_WEAPON, ITEM_ARMOR } ItemType; // Item typedef struct { int x, y; ItemType type; int power; int floor; int picked_up; } Item; // Player typedef struct { int x, y; int hp, max_hp; int attack; int defense; int floor; int step_count; Item inventory[MAX_INVENTORY]; int inventory_count; } Player; // Enemy types typedef enum { ENEMY_GOBLIN, ENEMY_SKELETON, ENEMY_ORC } EnemyType; // Enemy typedef struct { int x, y; int hp; int attack; int alive; EnemyType type; } Enemy; #endif // COMMON_H