@@ -350,13 +350,21 @@ ecsact_restore_error ecsact_restore_entities(
350350 auto component_data =
351351 ecsact::deserialize (component_id, serialized_component_data);
352352
353- if (ecsact_has_component (registry_id, entity_id, component_id)) {
353+ if (ecsact_has_component (
354+ registry_id,
355+ entity_id,
356+ component_id,
357+ // TODO: indexed fields
358+ nullptr
359+ )) {
354360 if (component_size != 0 ) {
355361 ecsact_update_component (
356362 registry_id,
357363 entity_id,
358364 component_id,
359- component_data.data ()
365+ component_data.data (),
366+ // TODO: indexed fields
367+ nullptr
360368 );
361369 }
362370 updated_components.push_back ({entity_id, component_id});
@@ -396,7 +404,13 @@ ecsact_restore_error ecsact_restore_entities(
396404 ECSACT_EVENT_INIT_COMPONENT,
397405 entity,
398406 comp_id,
399- ecsact_get_component (registry_id, entity, comp_id),
407+ ecsact_get_component (
408+ registry_id,
409+ entity,
410+ comp_id,
411+ // TODO: indexed fields
412+ nullptr
413+ ),
400414 events_collector->init_callback_user_data
401415 );
402416 }
@@ -408,7 +422,13 @@ ecsact_restore_error ecsact_restore_entities(
408422 ECSACT_EVENT_UPDATE_COMPONENT,
409423 entity,
410424 comp_id,
411- ecsact_get_component (registry_id, entity, comp_id),
425+ ecsact_get_component (
426+ registry_id,
427+ entity,
428+ comp_id,
429+ // TODO: indexed fields
430+ nullptr
431+ ),
412432 events_collector->update_callback_user_data
413433 );
414434 }
@@ -420,11 +440,23 @@ ecsact_restore_error ecsact_restore_entities(
420440 ECSACT_EVENT_REMOVE_COMPONENT,
421441 entity,
422442 comp_id,
423- ecsact_get_component (registry_id, entity, comp_id),
443+ ecsact_get_component (
444+ registry_id,
445+ entity,
446+ comp_id,
447+ // TODO: indexed fields
448+ nullptr
449+ ),
424450 events_collector->remove_callback_user_data
425451 );
426452
427- ecsact_remove_component (registry_id, entity, comp_id);
453+ ecsact_remove_component (
454+ registry_id,
455+ entity,
456+ comp_id,
457+ // TODO: indexed fields
458+ nullptr
459+ );
428460 }
429461 }
430462
0 commit comments