Partial tower implementation
This commit is contained in:
@@ -270,6 +270,19 @@ typedef struct Unit {
|
||||
EntityType unitType;
|
||||
} Unit;
|
||||
extern ECS_COMPONENT_DECLARE(Unit);
|
||||
|
||||
typedef struct Tower {
|
||||
f32 range;
|
||||
f32 minDamage;
|
||||
f32 maxDamage;
|
||||
f32 damageFalloff;
|
||||
f32 damageRadius;
|
||||
f32 projectileSpeed;
|
||||
f32 fireCooldown;
|
||||
f32 fireElapsed;
|
||||
} Tower;
|
||||
extern ECS_COMPONENT_DECLARE(Tower);
|
||||
|
||||
#define BUILDING_MAX_RECRUIT_SLOTS 4
|
||||
typedef struct BuildingRecruitSlot {
|
||||
EntityType entityType;
|
||||
@@ -301,8 +314,17 @@ extern ECS_TAG_DECLARE(Buildable);
|
||||
extern ECS_TAG_DECLARE(Attackable);
|
||||
|
||||
/**********************************************************
|
||||
* DelayDelete components
|
||||
* Misc components
|
||||
*********************************************************/
|
||||
|
||||
typedef u8 DrawLayer;
|
||||
extern ECS_COMPONENT_DECLARE(DrawLayer);
|
||||
|
||||
typedef struct AttachedEntity {
|
||||
ecs_entity_t entity;
|
||||
} AttachedEntity;
|
||||
extern ECS_COMPONENT_DECLARE(AttachedEntity);
|
||||
|
||||
typedef struct DelayDelete {
|
||||
f32 time;
|
||||
f32 elapsed;
|
||||
|
||||
Reference in New Issue
Block a user