Flecs: Enabling & Disabling
Description: A fast entity component system (ECS) for C & C++

| Flecs v4.0 A fast entity component system (ECS) for C & C++

Loading...
Searching...
No Matches
Macros
Enabling & Disabling
C API » Macro API » Type Safe API » Entity API
Collaboration diagram for Enabling & Disabling:

## Macros
#define | ecs_enable_component(world, entity, T, enable)
#define | ecs_is_enabled(world, entity, T)
#define | ecs_enable_pair(world, entity, First, second, enable)
#define | ecs_is_enabled_pair(world, entity, First, second)

## Detailed Description

## Macro Definition Documentation

## ◆ ecs_enable_component

#define ecs_enable_component | ( |  | world,
|  |  | entity,
|  |  | T,
|  |  | enable )

Value:
ecs_enable_id(world, entity, ecs_id(T), enable)
ecs_id
FLECS_API const ecs_entity_t ecs_id(EcsDocDescription)
Component id for EcsDocDescription.
ecs_enable_id
void ecs_enable_id(ecs_world_t *world, ecs_entity_t entity, ecs_id_t id, bool enable)
Enable or disable component.

Definition at line 552 of file flecs_c.h.

## ◆ ecs_enable_pair

#define ecs_enable_pair | ( |  | world,
|  |  | entity,
|  |  | First,
|  |  | second,
|  |  | enable )

Value:
ecs_enable_id(world, entity, ecs_pair(ecs_id(First), second), enable)

Definition at line 558 of file flecs_c.h.

## ◆ ecs_is_enabled

#define ecs_is_enabled | ( |  | world,
|  |  | entity,
|  |  | T )

Value:
ecs_is_enabled_id(world, entity, ecs_id(T))
ecs_is_enabled_id
bool ecs_is_enabled_id(const ecs_world_t *world, ecs_entity_t entity, ecs_id_t id)
Test if component is enabled.

Definition at line 555 of file flecs_c.h.

## ◆ ecs_is_enabled_pair

#define ecs_is_enabled_pair | ( |  | world,
|  |  | entity,
|  |  | First,
|  |  | second )

Value:
ecs_is_enabled_id(world, entity, ecs_pair(ecs_id(First), second))

Definition at line 561 of file flecs_c.h.