#include <include/flecs.h> FLECS_API ecs_entity_t ecs_get_object_for_id(const ecs_world_t *world, ecs_entity_t entity, ecs_entity_t rel, ecs_id_t id)
Get the object of a relation for a given id. This operation returns the first entity that has the provided id by following the specified relationship. If the entity itself has the id then entity will be returned. If the id cannot be found on the entity or by following the relation, the operation will return 0.
world- The world.
entity- The entity.
rel- The relationship to follow.
id- The id to lookup.
- The entity for which the object has been found.