#include <include/flecs.h> FLECS_API void ecs_override_id(ecs_world_t *world, ecs_entity_t entity, ecs_id_t id)
Add override for (component) id. Adding an override to an entity ensures that when the entity is instantiated (by adding an IsA relationship to it) the component with the override is copied to a component that is private to the instance. By default components reachable through an IsA relationship are shared.
Adding an override does not add the component. If an override is added to an entity that does not have the component, it will still be added to the instance, but with an uninitialized value (unless the component has a ctor). When the entity does have the entity, the component of the instance will be initialized with the value of the component on the entity.
world- The world.
entity- The entity.
id- The id to override.