Flecs v4.0
A fast entity component system (ECS) for C & C++
Loading...
Searching...
No Matches
ecs_observer_t Struct Reference

An observer reacts to events matching a query. More...

#include <flecs.h>

Public Attributes

ecs_header_t hdr
 Object header.
 
ecs_query_tquery
 Observer query.
 
ecs_entity_t events [(8)]
 Observer events.
 
int32_t event_count
 Number of events.
 
ecs_iter_action_t callback
 See ecs_observer_desc_t::callback.
 
ecs_run_action_t run
 See ecs_observer_desc_t::run.
 
void * ctx
 Observer context.
 
void * callback_ctx
 Callback language binding context.
 
void * run_ctx
 Run language binding context.
 
ecs_ctx_free_t ctx_free
 Callback to free ctx.
 
ecs_ctx_free_t callback_ctx_free
 Callback to free callback_ctx.
 
ecs_ctx_free_t run_ctx_free
 Callback to free run_ctx.
 
ecs_observable_tobservable
 Observable for observer.
 
ecs_world_tworld
 The world.
 
ecs_entity_t entity
 Entity associated with observer.
 

Detailed Description

An observer reacts to events matching a query.

Created with ecs_observer_init().

Definition at line 832 of file flecs.h.

Member Data Documentation

◆ callback

ecs_iter_action_t ecs_observer_t::callback

See ecs_observer_desc_t::callback.

Definition at line 841 of file flecs.h.

◆ callback_ctx

void* ecs_observer_t::callback_ctx

Callback language binding context.

Definition at line 845 of file flecs.h.

◆ callback_ctx_free

ecs_ctx_free_t ecs_observer_t::callback_ctx_free

Callback to free callback_ctx.

Definition at line 849 of file flecs.h.

◆ ctx

void* ecs_observer_t::ctx

Observer context.

Definition at line 844 of file flecs.h.

◆ ctx_free

ecs_ctx_free_t ecs_observer_t::ctx_free

Callback to free ctx.

Definition at line 848 of file flecs.h.

◆ entity

ecs_entity_t ecs_observer_t::entity

Entity associated with observer.

Definition at line 855 of file flecs.h.

◆ event_count

int32_t ecs_observer_t::event_count

Number of events.

Definition at line 839 of file flecs.h.

◆ events

ecs_entity_t ecs_observer_t::events[(8)]

Observer events.

Definition at line 838 of file flecs.h.

◆ hdr

ecs_header_t ecs_observer_t::hdr

Object header.

Definition at line 833 of file flecs.h.

◆ observable

ecs_observable_t* ecs_observer_t::observable

Observable for observer.

Definition at line 852 of file flecs.h.

◆ query

ecs_query_t* ecs_observer_t::query

Observer query.

Definition at line 835 of file flecs.h.

◆ run

ecs_run_action_t ecs_observer_t::run

See ecs_observer_desc_t::run.

Definition at line 842 of file flecs.h.

◆ run_ctx

void* ecs_observer_t::run_ctx

Run language binding context.

Definition at line 846 of file flecs.h.

◆ run_ctx_free

ecs_ctx_free_t ecs_observer_t::run_ctx_free

Callback to free run_ctx.

Definition at line 850 of file flecs.h.

◆ world

ecs_world_t* ecs_observer_t::world

The world.

Definition at line 854 of file flecs.h.


The documentation for this struct was generated from the following file: