Allocate path with object pool for pathfinding

This commit is contained in:
2023-11-16 07:23:56 +01:00
parent 9e6c836207
commit af99504370
9 changed files with 110 additions and 64 deletions

View File

@@ -16,8 +16,6 @@ typedef struct Game {
f32 frameDuration;
Vector2 targetPos;
ecs_entity_t entity;
Path path;
Position waypoints[128];
struct {
int building;
Vector2 mouseDown;
@@ -30,6 +28,9 @@ typedef struct Game {
i64 gold;
i64 pop;
} resources;
struct {
BzObjectPool *pathData;
} pools;
f32 elapsed;
} Game;