Change Storage to tag (since we have global storage)
This commit is contained in:
@@ -163,10 +163,6 @@ extern ECS_COMPONENT_DECLARE(UnitAI);
|
||||
extern ECS_TAG_DECLARE(Selectable);
|
||||
extern ECS_TAG_DECLARE(Selected);
|
||||
|
||||
// Unit can:
|
||||
// - Attack
|
||||
extern ECS_TAG_DECLARE(Unit);
|
||||
|
||||
// Worker can:
|
||||
// - Harvest
|
||||
// - Build
|
||||
@@ -183,19 +179,15 @@ typedef struct Worker {
|
||||
} Worker;
|
||||
extern ECS_COMPONENT_DECLARE(Worker);
|
||||
|
||||
// Unit can:
|
||||
// - Attack
|
||||
extern ECS_TAG_DECLARE(Unit);
|
||||
extern ECS_TAG_DECLARE(Storage);
|
||||
extern ECS_TAG_DECLARE(Harvestable);
|
||||
extern ECS_TAG_DECLARE(Buildable);
|
||||
extern ECS_TAG_DECLARE(Workable);
|
||||
extern ECS_TAG_DECLARE(Attackable);
|
||||
|
||||
typedef struct Storage {
|
||||
int capacity[RES_COUNT];
|
||||
int amount[RES_COUNT];
|
||||
int reserved[RES_COUNT];
|
||||
int pending[RES_COUNT];
|
||||
} Storage;
|
||||
extern ECS_COMPONENT_DECLARE(Storage);
|
||||
|
||||
void initComponentIDs(ecs_world_t *ecs);
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user