-
v0.4.0 Stable
released this
2026-07-16 04:51:02 +00:00 | 17 commits to main since this releasev0.4.0 - BREAKING CHANGE deltatime
- Bugfix: Typo in typehinting removed
- Bugfix: The bulk runner was called even when no system entities matched.
- Enhancement: EntityComponentBundle type is now public
- API change: Got rid of mandatory
dt
This release gets rid of the design flaw of mandatory deltatime.
Having made deltatime a requirement for all systems and the runner calls was a
mistake from the beginning, since a lot of systems just don't need it.To adapt to the new call signature you have to
-
Remove the first parameter for
dtof all system functions and the various
ecs.run_* functions. -
systems that actually do make use of deltatime, can receive it as a kwarg inkstead:
# From def momentum_system(dt, eid, position, momentum):... # To def momentum_system(eid, position, momentum, *, dt):... # From ecs.run_system(dt, 'position', 'momentum') # To ecs.run_system('position', 'momentum', dt=deltatime)
The drawback is, that if you use
run_all_systemsandrun_domain, all
systems that don't need deltatime need an additional**kwargsat the end of
their argument list, since those run-functions pass given kwargs to all
registered systems.Downloads
-
Source code (ZIP)
0 downloads
-
Source code (TAR.GZ)
0 downloads