aboutsummaryrefslogtreecommitdiffstats
path: root/src/ui.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui.h')
-rw-r--r--src/ui.h11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/ui.h b/src/ui.h
index b5089a3..eee1d4f 100644
--- a/src/ui.h
+++ b/src/ui.h
@@ -8,6 +8,7 @@
#define INTERACTION_COLUMN_MAX 80
#define INVENTORY_MAX 10
+#define INVENTORY_SPRITE_SIZE 42
typedef char InteractionItems[INTERACTION_MENU_MAX][INTERACTION_LABEL_MAX];
@@ -31,15 +32,9 @@ typedef struct {
} InteractionMenu;
typedef struct {
- EntityId id;
- AssetId texture;
- int count;
-} InventoryItem;
-
-typedef struct {
Rectangle rect;
bool visable;
- InventoryItem items[INVENTORY_MAX];
+ EntityItem items[INVENTORY_MAX];
int itemCount;
} Inventory;
@@ -68,7 +63,7 @@ void updateInteractionMenu(InteractionMenu* menu, Game* game);
void initInventory(Inventory* inventory);
void showInventory(Inventory* inventory);
void hideInventory(Inventory* inventory);
-void addItemToInventory(Inventory* inventory, InventoryItem item);
+void addItemToInventory(Inventory* inventory, EntityItem item);
void updateInventory(Inventory* inventory);
#endif