17template<
typename Base,
typename ... Components>
24 : BaseClass(&
desc->query)
49 template <typename E, if_t<is_enum<E>::value> = 0>
52 const auto& et = enum_type<E>(this->world_v());
54 return this->
kind(target);
61 template <
typename Phase>
71 desc_->multi_threaded = value;
80 desc_->immediate = value;
160 return *
static_cast<Base*
>(
this);
void ecs_remove_id(ecs_world_t *world, ecs_entity_t entity, ecs_id_t component)
Remove a component from an entity.
void ecs_add_id(ecs_world_t *world, ecs_entity_t entity, ecs_id_t component)
Add a (component) ID to an entity.
ecs_entity_t entity_t
Entity type.
ecs_world_t world_t
World type.
ecs_entity_t ecs_get_target(const ecs_world_t *world, ecs_entity_t entity, ecs_entity_t rel, int32_t index)
Get the target of a relationship.
#define ecs_dependson(e)
Construct a DependsOn pair.
void(* ecs_iter_action_t)(ecs_iter_t *it)
Function prototype for iterables.
#define ecs_ftime_t
Customizable precision for scalar time values.
Use with ecs_system_init() to create or update a system.
query_builder_i(ecs_query_desc_t *desc, int32_t term_index=0)
Base & kind(entity_t phase)
Specify in which phase the system should run.
Base & kind(E phase)
Specify in which phase the system should run, using an enum constant.
Base & tick_source(flecs::entity_t tick_source)
Set the tick source.
Base & rate(int32_t rate)
Set the system rate.
Base & immediate(bool value=true)
Specify whether the system should be run in an immediate (non-staged) context.
Base & ctx(void *ptr)
Set the system context.
Base & rate(const entity_t tick_source, int32_t rate)
Set the system rate.
Base & run(ecs_iter_action_t action)
Set the system run callback.
Base & kind()
Specify in which phase the system should run.
Base & interval(ecs_ftime_t interval)
Set the system interval.
Base & tick_source()
Set the tick source.
Base & multi_threaded(bool value=true)
Specify whether the system can run on multiple threads.
Base & desc()
Use with cascade() to iterate results in descending (bottom-to-top) order.