From 5daa12fed0449a7811fc25ec62236bc060a56fa7 Mon Sep 17 00:00:00 2001 From: Jonathan Bradley Date: Tue, 9 Sep 2025 16:05:14 -0400 Subject: pke: first-pass promote pke_level over pke_scene Major runtime ownership overhaul (scene -> level). Major ecs 'marked for removal' overhaul, ensuring that entities and their components are actually being removed when levels are unloaded. --- src/serialization-component.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/serialization-component.cpp') diff --git a/src/serialization-component.cpp b/src/serialization-component.cpp index 266eb2d..a401d50 100644 --- a/src/serialization-component.cpp +++ b/src/serialization-component.cpp @@ -320,10 +320,11 @@ void pke_deserialize_instance(srlztn_deserialize_helper *h, pke_kve_container *k // entity = reinterpret_cast(et_ptr->createInstanceCallback.func)(); fprintf(stderr, "[%s] Attempted to call EntityType::createInstanceCallback and we have not yet defined a valid function signature\n", __FILE__); } else { - map.created_entity = EntityType_CreateGenericInstance(et_ptr, h->scene, &comp, &inst_pos); + map.created_entity = EntityType_CreateGenericInstance(et_ptr, h->level, &comp, &inst_pos); } } else { map.created_entity = ECS_CreateGenericEntity(); + ECS_CreateEntity(map.created_entity); map.created_instance = ECS_CreateInstance(map.created_entity, comp.uuid, nullptr, &inst_pos); } ECS_GetInstances(map.created_entity, instances); -- cgit v1.2.3