diff options
| author | Jonathan Bradley <jcb@pikum.xyz> | 2024-01-09 20:30:05 -0500 |
|---|---|---|
| committer | Jonathan Bradley <jcb@pikum.xyz> | 2024-01-10 11:30:41 -0500 |
| commit | 294c85f91ac5b2ff9e4ad3d99588ed0d1a72e6b7 (patch) | |
| tree | a92c28661e1ab4b15a9ac9e52816cc6a4c2d7b95 /src/components.hpp | |
| parent | 0a382e78b6cbc77156d78df4e7b0c2854cbb0cd1 (diff) | |
checkpoint - major ECS interface refactor
Diffstat (limited to 'src/components.hpp')
| -rw-r--r-- | src/components.hpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/components.hpp b/src/components.hpp index 86c5727..f014c9e 100644 --- a/src/components.hpp +++ b/src/components.hpp @@ -11,6 +11,7 @@ #include <vulkan/vulkan_core.h> const uint64_t ECS_UNSET_VAL = 0xFFFFFFFFFFFFFFFF; +const uint32_t ECS_UNSET_VAL_32 = 0xFFFFFFFF; struct EntityHandle : public PkeHandle { }; struct GrBindsHandle : public PkeHandle { }; @@ -20,12 +21,11 @@ constexpr EntityHandle EntityHandle_MAX = EntityHandle{}; constexpr GrBindsHandle GrBindsHandle_MAX = GrBindsHandle{}; constexpr InstanceHandle InstanceHandle_MAX = InstanceHandle{}; -struct Entity { +struct Entity_Base { EntityHandle handle = EntityHandle_MAX; EntityHandle parentHandle = EntityHandle_MAX; - GrBindsHandle grBindsHandle = GrBindsHandle_MAX; - InstanceHandle instanceHandle = InstanceHandle_MAX; bool isMarkedForRemoval = false; + bool isReadyForTeardown = false; }; struct BufferBindingDetails { @@ -82,7 +82,7 @@ struct CompInstance { EntityHandle entHandle = EntityHandle_MAX; GrBindsHandle grBindsHandle = GrBindsHandle_MAX; InstanceHandle instanceHandle = InstanceHandle_MAX; - uint64_t index = ECS_UNSET_VAL; + uint32_t index = ECS_UNSET_VAL_32; PhysicsCollision physicsLayer = PhysicsCollision{1}; PhysicsCollision physicsMask = PhysicsCollision{1}; InstBt bt; |
