Some more progress
This commit is contained in:
18
items/item.h
18
items/item.h
@@ -4,10 +4,20 @@
|
||||
|
||||
#include <SDL2/SDL.h>
|
||||
#include "../util/util.h"
|
||||
#include "../tiles/belt.h"
|
||||
|
||||
#ifndef FACTORYGAME_ITEM_H
|
||||
#define FACTORYGAME_ITEM_H
|
||||
|
||||
#define ITEMREGISTRY_SIZE 20
|
||||
|
||||
typedef struct {
|
||||
float offset;
|
||||
int tileX, tileY;
|
||||
bool active;
|
||||
uint16_t type;
|
||||
} ItemOnBelt;
|
||||
|
||||
typedef struct {
|
||||
uint16_t type;
|
||||
char name[20];
|
||||
@@ -15,17 +25,9 @@ typedef struct {
|
||||
SDL_Texture * textureOnBelt[ORIENT_DIRECTION_COUNT];
|
||||
} Item;
|
||||
|
||||
#define ITEMREGISTRY_SIZE 512
|
||||
|
||||
extern Item ItemRegistry[ITEMREGISTRY_SIZE];
|
||||
|
||||
typedef struct {
|
||||
float offset;
|
||||
int tileX, tileY;
|
||||
bool active;
|
||||
uint16_t type;
|
||||
} ItemOnBelt;
|
||||
|
||||
void updateItems();
|
||||
|
||||
void loadItems(SDL_Renderer *renderer);
|
||||
|
Reference in New Issue
Block a user