sprites on screen yay

This commit is contained in:
2023-08-14 03:58:13 -04:00
parent 6325c4e4a7
commit b9395446a0
147 changed files with 28994 additions and 154 deletions

18
src/game/ecs/ecs_entity.c Normal file
View File

@ -0,0 +1,18 @@
#include "ecs_entity.h"
/* Returns a new entity ID. */
u32
ecs_entity_add(ECS* self)
{
self->nextID++;
return self->nextID;
}
/* Removes all components associated with an entity. */
void
ecs_entity_delete(ECS* self, u32 id)
{
for (s32 i = 0; i < ECS_COMPONENT_COUNT; i++)
ecs_component_delete(self, (ECSComponentType)i, id);
}