Skip to content

Commit

Permalink
Add a ecs_singleton_set_ptr, to mirror ecs_set_ptr
Browse files Browse the repository at this point in the history
  • Loading branch information
darkuranium committed Jul 19, 2023
1 parent 1e35ea1 commit 32142b9
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions include/flecs/addons/flecs_c.h
Original file line number Diff line number Diff line change
Expand Up @@ -408,6 +408,9 @@
#define ecs_singleton_get(world, comp)\
ecs_get(world, ecs_id(comp), comp)

#define ecs_singleton_set_ptr(world, comp, ptr)\
ecs_set_ptr(world, ecs_id(comp), comp, ptr)

#define ecs_singleton_set(world, comp, ...)\
ecs_set(world, ecs_id(comp), comp, __VA_ARGS__)

Expand Down

0 comments on commit 32142b9

Please sign in to comment.