[scene] Make nullentity's id nullent

While an entity with a null registry is null regardless of the id,
setting the id to nullent is useful for other purposes.

Fixes the disappearing brush models in the vulkan renderer (it uses
entity id + 1 for indexing), and prevents similar issues in the future.
This commit is contained in:
Bill Currie 2022-11-13 14:35:47 +09:00
parent 767b39b7bd
commit 88e59e72c4

View file

@ -50,7 +50,7 @@ typedef struct entity_s {
uint32_t id; uint32_t id;
} entity_t; } entity_t;
#define nullentity ((entity_t) {}) #define nullentity ((entity_t) { .id = nullent })
typedef struct animation_s { typedef struct animation_s {
int frame; int frame;