Releases: SanderMertens/flecs
Flecs v4.0.3
Highlights
- None, just a lot of small improvements and bugfixes 🐛
Release notes
This version includes the following bugfixes:
[cpp]
Fix issue withmodified<R, T>
where first type is a tag[cpp]
Fix conflicting identifier between flecs and magic_enum library[cpp]
Fix issue with reparenting module that is in root namespace[cpp]
Disable incorrect msvc warning on enum reflection code[core]
RemoveFLECS_API
in block_allocator.c which was causing linker errors (thanks @Indra-db!)[core]
Fix crash if component and entity w/component are deleted in same cleanup operation[core]
Fix linked list corruption in supporting data structure for Union relationships[core]
Fix issue where union relationships weren't copied from prefab to prefab instance[core]
Fix bug with component overriding for prefabs with union pairs[core]
Avoid size integer overflow of command buffer vector during world cleanup (thanks @jpeletier!)[queries]
Fix issue with queries that match empty tables and iterate individual entities[queries]
Fix issue with evaluating queries withany
wildcards that match multiple tables[queries]
Fix issue where offset could be applied toNULL
address[observers]
Fix issue with yield_existing observers andnot
terms[observers]
Fix issue with getting field inOnSet
observer after removing override[observers]
Fix issue where(OnInstantiate, Override)
would not trigger OnSet observers[expr]
Fix memory leak after failed multiline string assignment[json]
Fix JSON serialization for auto_override/toggle components[json]
Fix issue with serializing type info to JSON for sparse components[log]
Fix issue whereecs_log_set_level
returns wrong value[stats]
Fix issue inflecs::stats
module when globalMatchEmptyTables
flag is set[alerts]
Fix brokenFLECS_NO_ALERTS
macro (thanks @pfeodrippe!)
This version includes the following improvements:
[cpp]
Implementiter::targets
for easy iteration of relationship targets for a field[cpp]
Remove redundant call tostrcpy
inecs_cpp_get_symbol_name
[cpp]
Enforce correct type when using*_second
operations in entity, entity_view and entity_builder[queries]
Return wildcard table records inecs_iter_t::trs
forany
wildcard terms[queries]
Report errors for invalid usage ofcascade
anddesc
modifiers[observers]
Add yield_existing flags for customizing observer create/delete behavior[observers]
Trigger events for optional observer terms[core]
Addecs_world_get_flags
function[core]
Escape separator characters in entity name when usingecs_get_path
[core]
Add option to escape characters for serialization in entity path[core]
Implementecs_table_clear_entities
(thanks @gsnook!)[meta]
EmitOnSet
after modifyingEcsEnum
component (thanks @jpeletier!)[json]
Fix issue with serializing queries that have large numbers of fields[json]
Don't serialize baseDontInherit
components to JSON[rest]
Include query plan used to populate cache in REST reply[http]
Automatically test port range when creating HTTP server for multi-application support[doc]
Add UUID to doc addon[docs]
Add link to flecs raylib starter kit to documents[docs]
Add Hyperion to README[docs]
Add Age of Respair to README[docs]
Fix incomplete sentence in query manual[docs]
Fix find/replace errors in query manual[docs]
Show how to use lookup functions in hierarchy examples[docs]
Fix disabling typo in entity manual[docs]
FixTermAt
indexing in C# docs (thanks @deathbeam!)[docs]
Rename Routine to System in C# docs (thanks @deathbeam)[docs]
Fix comment typo in prefab example (thanks @Indra-db)[docs]
Fix broken link in relationship manual[docs]
Add note to prefab manual on how prefabs are only ignored for entities matched on$this
[docs]
Add missing , in migration guide[docs]
Fix typo in scopes section of query manual[tests]
Fix duplicate test case[build]
Remove unnecessary version attribute from flecs bazel model definition (thanks @reutermj!)[ci]
macOS CI improvements (thanks @waywardmonkeys!)
Breaking changes
ecs_get_path_w_sep_buf
now has an additionalescape
argument (#466 (comment))
New Contributors
- @deathbeam made their first contribution in #1395
Full Changelog: v4.0.2...v4.0.3
Flecs v4.0.2
Highlights
- New blog: Building an ECS #3: Storage in pictures
- Runtime types now automatically generate hooks that cleanup resources (thanks @jpeletier!)
- New OS API hooks that enable integration with tracy-style profilers!
Release notes
This version includes the following bugfixes:
[cpp]
Fix spurious entities that are created when renaming C++ module[cpp]
Fix issue with non-$this fields in query iteration (thanks @Gaspard--!)[cpp]
Fix issue with computing component name from multiple threads/worlds[cpp]
Fix issue where C++ world object would sometimes not get freed (thanks @jpeletier!)[cpp]
Fix issue with observers and up traversal[cpp]
Fix clang 20 compiler error in enum reflection code[core]
Fix issue with using sparse components andecs_new_w_table
[core]
Fix issue withecs_new_w_table
and overriding components[core]
Fix issue with creating queries inside of hooks[core]
Fix issue with testing tables for wildcard pair ids[core]
Fix potential leak inecs_clone
due to double constructor call (thanks @jpeletier!)[core]
Fix issues with simple observers/queries for sparse components[core]
Fix issues with hooks for sparse components[core]
Fix issue with batchedOnAdd
+OnRemove
observers[queries]
Fix issue with matchingIsA -> IsA -> ChildOf
up traversal[queries]
Fix issue with matching prefab/disabled entities for queries that start with not term[systems]
Fix issue with setting rate filter on system without tick source[systems]
Fix issue with cleaning up iterator resources for systems that match nothing[json]
Fix crash when serializing query plan for trivial query[json]
Fix issue where conflictingalerts
member could serialize to invalid JSON[script]
Fix issue where script visitor function wasn't restored after parsing template[stats]
Fix issue where units module was not always imported by stats (thanks @domdom!)[stats]
Fix crash when fetchingWorldSummary
by REST API before it's initialized[explorer]
Fix issue with entity names that have contain/
characters
This version includes the following improvements:
[cpp]
Addflecs::ref::has
[cpp]
Add missing overload forquery_builder::with(const char*, id_t)
[cpp]
Addflecs::iter::other_table()
[c]
Removeconst
fromecs_ref_get
[core]
Implement fine-grained feature tracking for add/remove operations[core]
Add performance tracing hooks to OS API[core]
Add perf trace when sleeping due to target_fps (thanks @waywardmonkeys!)[core]
Add support forAUTO_OVERRIDE
to prefab children[core]
Implement deterministic ids for prefab children[core]
Use__alignof__
on clang[core]
Allow for restoring ranges withecs_set_entity_range
[core]
Add compile time flag to disable statistics counters[core]
Fix thread sanitizer warnings[core]
Prevent callingecs_run_post_frame
outside of frame[core]
Addecs_id_from_str
[core]
Allow for suspending readonly mode outside of multithreaded systems[queries]
Remove redundant query instruction constants[queries]
Allow(IsA, tgt|self)
queries to be cached[queries]
Don't automatically cache queries with only not/optional terms[observers]
Addyield_existing
support toOnRemove
observers[meta]
Support callingecs_meta_get_string
on opaque string types[meta]
Make flaky alert tests not flaky (thanks @jpeletier!)[meta]
Add aconst_string
opaque type (thanks @jpeletier!)[meta]
Auto-generate lifecycle hooks for reflection-only types[stats]
Add counter for tracking component monitor evaluations[units]
Remove unused symbols from units addons[docs]
Fix typos in documentation on how to run tests (thanks @jpeletier!)[docs]
Add Meta copyright notice to LICENSE (has no impact on license which is still MIT!)[docs]
Fix typos (thanks @waywardmonkeys!)[docs]
Fixemit
/event
typo in observer manual (thanks @awest03!)[docs]
Add missing access modifier section to query language manual[docs]
Add link to storage in pictures to docs[docs]
Fix broken links in design guide[build]
Move flecs.c and flecs.h files todistr
folder[build]
Migrate bazel build to bzlmod (thanks @reutermj!)[build]
Add bazel build definitions for examples and add bazel build/test to CI[ci]
Add spell check to CI (thanks @Georgiy-Tugai!)
Breaking changes
New Contributors
- @domdom made their first contribution in #1312
- @reutermj made their first contribution in #1301
- @Gaspard-- made their first contribution in #1327
- @awest03 made their first contribution in #1344
- @Georgiy-Tugai made their first contribution in #1353
Full Changelog: v4.0.1...v4.0.2
Flecs v4.0.1
Highlights
Lots of performance improvements! 🚀
- Queries for sparse components are up to 20x faster
get
,get_mut
,has
andowns
are 1.5-3x faster- Cached queries are 5x faster to create, and match 1.5x faster with new tables
- Simple uncached queries are up to 2x faster than v4.0.0 (5x faster than v3.2.12)
Release notes
This version includes the following bugfixes:
[cpp]
Fix crash when copying world object during shutdown (thanks @jpeletier!)[cpp]
Callpopulate_self
recursively for simple query results (thanks @Indra-db!)[core]
Fix assert when toggling component from stage[core]
Fix command batching issue that could prevent query rematching[core]
Fix issues with commands for sparse components[core]
Fix issue with cloning named entities[core]
Fix assert when callingemplace
afterremove
while deferred[queries]
Fix issue with not operator, traversal and wildcards[queries]
Fix issue with toggleable components and terms with#0
source[queries]
Fix issue withup
traversal and (re)matching empty tables[observers]
Fix issue with updating observers to different callback kind[observers]
Fix issue with observer for sparse component (thanks @Megafunk!)[systems]
Fix issue with updating system to different callback kind[script]
Fix issue where anonymous entities wouldn't clear after script update[script]
Fix syntax error for scripts with only ausing
statement[script]
Fix issue where unresolved component in template didn't throw an error[script]
Fix issue with anonymous template instance creation[script]
Fix issues with partial component assignments[script]
Fix issues with assigning non-trivial components[json]
Fix issues in new deserializer, serialize full paths by default[json]
Fix issue with serializing entity to JSON from stage[json]
Fix issues with serializing sparse components[json]
Fix issue with serializing inherited components without reflection data[rest]
Ensure REST HTTP server always has valid delta_time value[rest]
Only enable time measurements when OS time API is initialized
This version includes the following improvements:
[cpp]
Addflecs::ref<T>
constructor that just takes an entity (thanks @RoyAwesome!)[cpp]
Add support for iterating sparse component queries with run callback[core]
Removeid
andsize
fields fromecs_column_t
[core]
Use one size/count member for all table columns[core]
Addcomponent_map
to tables to improveget
/get_mut
/has
/owns
performance[core]
Improve performance ofecs_table_get_*_index
functions[queries]
Add dedicated iterator mode for queries that are fully cached[queries]
Add dedicated iterator mode for queries that are fully trivial[queries]
Don't evaluate first term of uncached queries twice[queries]
Reduce branching in trivial iterator code[queries]
Remove iterator mode that returned entities one by one[queries]
Replaceecs_iter_t::columns
with table records array[queries]
Removeecs_iter_t::ptrs
[queries]
Reduce number of observers created per query[queries]
Reuse staticsources
/ids
arrays for cached results where possible[queries]
Don't generate query plan for trivial queries[queries]
Implement fast query validation for simple queries[meta]
Add option to provide 0 offset without triggering automatic offset computation (thanks @Indra-db!)[script]
Suppress variable shadowing warning for parser on msvc[json]
Remove legacy (v3) deserializer[log]
Fix incorrect log color comparison (thanks @kagetu!)[docs]
Replaceno_readonly
withimmediate
in system manual[docs]
Fix link to migration guide[docs]
Fix grammar in Rust query examples (thanks @waywardmonkeys!)[docs]
Fix find/replace typos (thanks @waywardmonkeys!)[docs]
Remove references toEcsIteratble
(thanks @waywardmonkeys!)[misc]
Create.gitattributes
to preserve line endings on Windows (thanks @epreston!)[ci]
Prevent running workflows concurrently for same branch
Benchmark results
https://github.com/SanderMertens/ecs_benchmark/tree/bda57ec04f1cb9ebeacab8a17cf9a0c3353d267b
Breaking changes
- Query results with inherited components now must be explicitly handled in C API (#466 (comment))
- Sparse components must now be obtained with
ecs_field_at
(#466 (comment)) - The
columns
/ptrs
members got removed from iterators (#466 (comment)) - Member target query results have changed (#466 (comment))
New Contributors
Full Changelog: v4.0.0...v4.0.1
Flecs v4.0.0
Flecs 4.0 is out! 🎉
This is a major release with many new features, improvements, bugfixes and breaking changes. Enjoy!
Release Notes
See the release announcement:
https://ajmmertens.medium.com/flecs-v4-0-is-out-58e99e331888
Upgrading to v4
To upgrade from v3 to v4, see the migration guide:
https://www.flecs.dev/flecs/md_docs_2MigrationGuide.html
Known issues
Flecs v3.2.12
Highlights
- This release marks the last commit before the v4 release, which is happening in the next few days!
- This is by far the most stable v3 release, and recommended for anyone staying on v3
- All of the changes below are already part of the v4 branch!
Release notes
This version includes the following bugfixes:
- Fix issue where anonymous entity would be deserialized into named entity with same id
- Fix query DSL issue where incorrect entity could get resolved for OneOf terms
- Fix issue where module symbol lookup could interfere with name lookups
- Fix typo in named query REST endpoint
- Don't serialize entity ids as floats in JSON
- Fix issues with assigning path names with deleted parent in deferred mode
- Fix compiler error when application defines
free
macro - Fix integer conversion assert in JSON serializer
- Fix issue where compiling JSON addon without REST didn't work
- Fix issue with any pair terms in observers
- Fix world deserialization issue with entities that have relationship cycles
- Fix issue with sorting shared components
- Fix potential divide by zero in JSON profiler code
- Fix enum reflection issue on VS2019
- Fix assert for invalid query with uninitialized dependent variable
- Fix infinite loop in
progress
when using integer time type - Fix issues with
yield_existing
and observers with entity source - Fix offset on
nullptr
in JSON serializer code - Fix out of bounds write when bulk overriding components (thanks @Indra-db!)
- Fix assert when moving component without ctor to existing table (thanks @Thinkofname!)
- Remove declaration to non-existent
ecs_meta_set_component
(thanks @pfeodrippe!) - Fix potential buffer overflow with large compilers strings (thanks @apache-hb!)
- Fix duplicate definition errors when using unity builds (thanks @apache-hb!)
- Fix issue with sorting non-trivial components
- Fix issue with OR/wildcard queries
- Fix issue with overcounting nodata terms in query with OR terms
This version includes the following improvements:
[cpp]
Don't rely on automatic registration of builtin components[cpp]
Improve robustness and flexibility of enum reflection (thanks @garrett-is-a-swann!)[cpp]
Add additional overloads that make use of enum reflection (thanks @RoyAwesome!)[cpp]
Additer::field_at
method, disallow usage ofiter::field
ineach
[cpp]
Change entity constructor to takeentity_t
instead ofid_t
[cpp]
Add pair overload toget_ref
(thanks @TBlauwe!)[cpp]
Add missingget_mut
singleton methods (thanks @Indra-db!)[cpp]
Improve performance ofentity::children
[cpp]
Removestatic
for improved compatibility with C++20 modules (thanks @alexv-ds!)[cpp]
Alow for creating ownedflecs::world
from custom C world[cpp]
Addterm_index
toflecs::iter
(thanks @jpeletier!)[cpp]
Mark overridden methods withoverride
(thanks @jpeletier!)[queries]
Add support for parsing special characters in entity names[queries]
Add support for matching empty tables for cached queries[queries]
Fix issue with query traversal that could cause duplicate results[rules]
Fix incorrectly initialized context in query engine[observers]
Add support for disabling observers[observers]
Add missing event propagation code paths[pipelines]
Addmulti_threaded
argument toreadonly_begin
[core]
Improve error messages for constraint violations[core]
Allow for setting component name throughtype_info_t::name
[core]
Automatically addModule
tag to parents of components (thanks @garrett-is-a-swann!)[core]
Rename ofget_mut
,ensure
toensure
,make_alive
[core]
Add newget_mut
that doesn't add component[core]
Add ability to include user-defined header with compile-time settings[core]
Don't create intermediate tables when instantiating prefab children[core]
Fix uninitialized value in cleanup logic[core]
Add table type order check in sanitized mode[core]
Addecs_get_build_info
[core]
ImplementRelationship
,Target
,Trait
constraint traits[core]
Use destructive move semantics when move & move_ctor is not set (thanks @Indra-db!)[core]
Improve performance ofecs_children
[core]
Add world-global parameter for specifying default query flags[json]
serialize prefabs when serializing world[json]
improve robustness when deserializing into world with missing reflection data[json]
Don't asert on invalid entity identifier in JSON deserializer[json]
Add query info JSON serializer[json]
Add query profiler[json]
Always serialize full path forparent
fields[rest]
Add support for inspecting observers with REST API[rest]
Implement endpoint for capturing commands of a single frame[doc]
MergeCOREDOC
addon with doc addon[monitor]
Addframe_count
toWorldSummary
[monitor]
Add build info toWorldSummary
[doc]
Fix incorrect comments insimple_module
examples[doc]
Add code tabs and C# snippets to relationship manual (thanks @BeanCheeseBurrito!)[doc]
Fix inconsistent order_by docs[doc]
Fix headers and language example tabs in relationship manual[doc]
Fix issue with observer example in quickstart (thanks @lenis0012!)[ci]
Add deprecated CI platforms (thanks @waywardmonkeys!)[ci]
Fix warnings when usingFLECS_USE_OS_ALLOC
(thanks @waywardmonkeys!)[ci]
Fix issues with windows/clang64[ci]
Add test to make sure amalgamated files are updated[ci]
Fix asan issue with casting function pointers (thanks @darkuranium!)[windows]
Ensure windows version macro is set correctly forinet_pton
(thanks @benjitrosch!)[misc]
Makectx
argument ofworld::atfini
optional[misc]
Usefseek
instead ofrewind
(thanks @waywardmonkeys!)[misc]
Add missing#ifndef
which could cause macro redefinitions (thanks @Indra-db!)
Benchmark results
https://github.com/SanderMertens/ecs_benchmark/tree/4681e8606aa9204b97f6316d3611e9f0d2572852
Breaking changes
- Renaming of
get_mut
,ensure
(#466 (comment)) - The
COREDOC
addon was removed (#466 (comment)) ecs_readonly_begin
has a newmulti_threaded
argument (#466 (comment))- Changes to
flecs::iter::field
(#466 (comment))
Known issues:
#844
#765
#714
#620
#478
#314
New Contributors
- @RoyAwesome made their first contribution in #1160
- @TBlauwe made their first contribution in #1190
- @jpeletier made their first contribution in #1219
- @lenis0012 made their first contribution in #1228
Full Changelog: v3.2.11...v3.2.12
Flecs v4.0.0-beta
What is this?
This is the Flecs v4 beta release! 🎉
You can use this release to familiarize and play around with the new APIs and features before v4 comes out. The biggest difference between v3 and v4 is a new query engine that unifies filters, queries and rules in a single API.
What is a beta release?
Beta means that the v4 branch now has all the features that the final release will have! The next few weeks will be spent finding bugs, updating documentation, updating the Flecs demo's and on creating a migration guide.
What's new since v4.0.2-alpha
- A new sparse component storage
- Union relationships have been reimplemented for the v4 code base
- On prefab instantiation, components are now copied to the instance instead of inherited.
- New traits have been introduced to customize instantiation behavior
- The
iter
andrun
query iteration callbacks have been replaced with a singlerun
callback OVERRIDE
is renamed toAUTO_OVERRIDE
- Flecs script assemblies have been renamed to templates
- The existing query manual has been updated to v4
- A new Flecs Query Language manual has been added that describes query DSL syntax
- A new component traits manual has been added
- Lots of C functions have been documented with doxygen
- Bugfixes
This version does not work with the explorer because of a breaking change in the query DSL. To use the explorer with this release, use this URL: https://www.flecs.dev/explorer/v4?remote=true.
The release should be stable enough for experimentation.
What is missing?
- There are a handful of known bugs that still need to be fixed
- Performance testing hasn't finished yet
- Documentation has not been updated yet
When will v4 come out?
The updated goal is to release in June.
Where can I share feedback?
Post v4 feedback in this discussion post: #1181 or on the Flecs discord server, whichever you prefer!
⚠️ Do not use this release in an actual project! ⚠️
Flecs v4.0.2-alpha
What is this?
This is another early preview of the upcoming v4 release! 🎉
You can use this release to familiarize and play around with the new APIs and features before v4 comes out. The biggest difference between v3 and v4 is a new query engine that unifies filters, queries and rules in a single API.
What's new since v4.0.1-alpha
- A new Flecs Script parser with an improved syntax, new features and a new script manual!
- A few tweaks to the query DSL that reduce complexity and make it (slightly) less verbose
- Query fields are now indexed from zero! (so
it.field(0)
instead ofit.field(1)
) - Lots of improvements to API ergonomics & removal of tech debt
- Lots of bug fixes since the last alpha release
This version does not work with the explorer because of a breaking change in the query DSL. To use the explorer with the alpha, use this URL: https://www.flecs.dev/explorer/v4?remote=true.
The release should be stable enough for experimentation.
Flecs script example
// New: a cleaner syntax allows for more natural type descriptions
struct Position {
x = f32
y = f32
}
assembly CheckBox {
prop checked = bool: false
// New: conditional logic!
if $checked {
Image("checked.png") // New: improved anonymous entity notation
} else {
Image("unchecked.png")
}
}
// New: new syntax that improves ergonomics of working with assemblies
CheckBox my_checkbox(checked: true) {
Position: {x: 400, y: 300} // New: a more consistent way to specify components
// Streamlined syntax for creating child entities
Label my_lbl("Hello world") {
Position: {x: 100, y: 0}
}
}
Query DSL example
// Old
Item, Player($this:self|up(ContainedBy))
// New
Item, Player($this|self|up ContainedBy)
What is missing?
- A big usability update to prefabs is still underway
- There are a handful of known bugs that still need to be fixed
- Performance testing hasn't finished yet
- Documentation has not been updated yet
When will v4 come out?
The updated goal is to release around the end of May, with a beta release coming out in around two weeks.
Where can I share feedback?
Post v4 feedback in this discussion post: #1181 or on the Flecs discord server, whichever you prefer!
⚠️ Do not use this release in an actual project! ⚠️
Flecs v4.0.1-alpha
What is this?
This is an early preview of the upcoming v4 release! 🎉
You can use this release to familiarize and play around with the new APIs and features before v4 comes out. The biggest difference between v3 and v4 is a new query engine that unifies filters, queries and rules in a single API.
Overview
- All tests are passing on all platforms and compilers
- The query API is mostly stable
- Examples have been updated to the new APIs
- Many parts of the API have been simplified
- The release mostly works with the explorer and query editor
Code examples
// A system with query variables
world.system<Position>("SpaceshipsDockedToPlanet")
.with<SpaceShip>()
.with<DockedTo>("$obj")
.with<Planet>().src("$obj")
.each([](flecs::entity spaceship, Position& p) {
// ...
});
// By default queries are uncached. This is similar to a v3 filter/rule
world.query_builder<Position>()
.with(flecs::ChildOf, "$parent")
.each([](Position& p) {
// ...
});
// Adding .cached() enables caching, which is similar to a v3 query.
// Only the terms that are cacheable will be cached. This allows
// for queries that are partially cached, which is not possible in v3.
auto q = world.query_builder<Position>()
.with(flecs::ChildOf, "$parent")
.cached()
.build();
q.each([](Position& p) {
// ...
});
// Queries can be named. This associates the query with an entity
// with the same name. Queries that are associated with an entity
// are cached. This means that by default all system queries enable
// caching, just like in v3.
auto q = world.query_builder<Position>("Children")
.with(flecs::ChildOf, "$parent")
.build();
q.each([](Position& p) {
// ...
});
// Queries that are associated with an entity need to be explicitly
// destructed. This is the same behavior as `flecs::entity`.
// Queries that are not associated with an entity are cleaned up
// when they go out of scope. This is the same behavior as
// `flecs::world` (RAII).
q.destruct();
flecs::world world_a;
{
// World objects can now be copied. This just creates a handle to
// the existing world, it doesn't create/copy a new world.
flecs::world world_b = world_a;
}
void Move(ecs_iter_t *it) {
Position *p = ecs_field(it, Position, 0); // Field indices now start from 0!
Velocity *v = ecs_field(it, Velocity, 1);
for (int i = 0; i < it->count; i ++) {
p[i].x += v[i].x;
p[i].y += v[i].y;
}
}
The release should be stable enough for experimentation.
What is missing?
- The APIs are not yet finalized. Big changes are still underway, especially in the C API
- A few new features are still in development
- There are a handful of known bugs that still need to be fixed
- Performance testing hasn't finished yet
- Documentation has not been updated yet
When will v4 come out?
There is still a lot that needs to happen before the release. The goal is to release around the end of April, with a higher probability of it being later than earlier.
Where can I share feedback?
Post v4 feedback in this discussion post: #1181 or on the Flecs discord server, whichever you prefer!
⚠️ Do not use this release in an actual project! ⚠️
Flecs v3.2.11
Highlights
- Hytale is using Flecs as the backbone for their upcoming engine!
- More than half of the contributions in this release are from the community ❤️
- Work on Flecs 4.0 is well underway, with simpler query APIs and better performance! Follow progress here
Release notes
This version includes the following bugfixes:
- Fix issue with parsing newlines in query strings
- Fix issue with registration of nested types in module
- Fix issue in rule engine with lookup variables and equality operators
- Fix issue with rules that are partially trivial
- Fix issue where a member with a missing MetaType wasn't correctly handled (thanks @ZeroErrors!)
- Fix issue where query term with equality operator was incorrectly marked as trivial
- Fix potential out of bounds read in rule engine
- Fix JSON serialization error for labels with double quotes
- Fix issue with evaluating
R(_, _)
and_(_, T)
queries - Fix issues with not/optional operators and terms with any (
_
) source - Fix issue where rule compiler would not detect uninitialized lh of equality operator
- Fix issue where
ecs_ref_t
could point to invalid component after table recycling - Fix issue in code that dedups events for multi-component observers
- Fix issue where observer could access deleted id record during world cleanup
This version includes the following improvements:
[cpp]
Add missing overloads fordelete_with
andremove_all
(thanks @Charlie-83!)[cpp]
AddFLECS_CPP_NO_AUTO_REGISTRATION
flag to disable automatic component registration[cpp]
Addflecs::string::contains
[cpp]
Add support for associating a timer/tick source with a type (thanks @ZeroErrors!)[cpp]
Add missingconst
toentity_view
methods (thanks @waywardmonkeys!)[cpp]
Add missingflecs::doc::get/set_color()
functions (thanks @waywardmonkeys!)[cpp]
Mark explicit move ctors/operator= asnoexcept
(thanks @waywardmonkeys!)[cpp]
Remove redundant void arg of log function (thanks @waywardmonkeys!)[query-dsl]
Add support forR(A, B || C)
syntax to DSL[query]
Fill outecs_iter_t.system
when using filters, queries and rules (thanks @BeanCheeseBurrito!)[query]
Improve string conversion of queries with equality operators[rule]
Skip empty ids forR(_, *)
and*(_, T)
queries[json]
Implement serializer for user-friendly JSON format[json]
Add option for serializing query field metadata[rest]
Fix issue where cached REST request would always return code 200[rest]
Addtry
parameter that prevents throwing HTTP error when trying out queries[snapshot]
Reduce copies when duplicating tables with non-POD components for snapshots (thanks @ZeroErrors!)[strbuf]
Simplify implementation ofecs_strbuf_t
, improve performance[http]
Improve performance ofecs_http_server_request
[http]
Enable caching of HTTP requests made from C API[log]
Don't mix writing to stderr/stdout in logging output[log]
Make output file used by logging functions configurable[doc]
Fix copy-paste issues with type names (thanks @waywardmonkeys!)[doc]
Fix relationship example by specifying inout (thanks @garrett-is-a-swann!)[doc]
Update Doxygen to v1.10.0 (thanks @ZeroErrors!)[doc]
Enable graphviz dot files in Doxygen (thanks @ZeroErrors!)[doc]
Change defgroup documents to use autobrief (thanks @ZeroErrors!)[doc]
Fix typos (thanks @waywardmonkeys!)[doc]
Fix typos and spelling errors (thanks @ZeroErrors!)[doc]
Fixed documentation link in quickstart addons section (thanks @DJLink!)[doc]
Remove spurious asterisk (thanks @waywardmonkeys!)[doc]
Use @code/@encode (thanks @waywardmonkeys!)[doc]
Fix grouping errors in C docs (thanks @waywardmonkeys!)[doc]
Link function names in doc comments (thanks @waywardmonkeys!)[doc]
Fixecs_doc_get_name
code samples (thanks @waywardmonkeys!)[doc]
Add tab widget for code snippets (thanks @ZeroErrors!)[doc]
Add Extermination Shock to readme[doc]
Add Hytale to readme[doc]
Improve doc addon docs (thanks @waywardmonkeys!)[doc]
Fix doxygen warnings (thanks @waywardmonkeys!)[doc]
Add missing doc.brief descriptions to flecs entities[doc]
Add C# example snippets to Quickstart, RestApi, System manuals (thanks @BeanCheeseBurrito!)[ci]
Update pages workflow actions (thanks @waywardmonkeys!)[ci]
Add macOS-14 Apple Silicon jobs (thanks @waywardmonkeys!)
Benchmark results
https://github.com/SanderMertens/ecs_benchmark/tree/4681e8606aa9204b97f6316d3611e9f0d2572852
Known issues:
#844
#765
#714
#620
#478
#314
New Contributors
- @Charlie-83 made their first contribution in #1104
- @garrett-is-a-swann made their first contribution in #1107
- @DJLink made their first contribution in #1117
Full Changelog: v3.2.10...v3.2.11
Flecs v3.2.10
Highlights
- Significant performance improvements of the rule query engine:
- Up to 4x faster when compared with v3.2.9 for simple component queries
- Up to 6x faster when compared with filters for simple component queries
- Many other improvements, like automatic reordering of terms & simplified control flow
- Rules now support
up
traversal!
Release notes
This version includes the following bugfixes:
- Fix memory leak with batched
set
commands for new components - Fix issue in detection of whether a query has no data fields
- Fix missing argument in error trace in meta addon
- Fix issue that would occur when units module is not imported before monitor module
- Fix issue with invalidating observer reachable cache
- Fix issue where
on_set
hook was invoked without deferred mode & could be called twice - Fix issue where structural changes from
on_set
hook could get lost - Fix issue where anonymous rule variables would be stored before regular variables in variable array
- Fix issue where content type wasn't set on reply for cached HTTP request
- Fix segfault when enqueueing custom event
- Fix duplicate matches in rules with or (
||
) expressions - Fix issue where ids of terms without source weren't correctly set in rule iterator
- Fix duplicate matches in rules with
Any
wildcards - Fix issue with any terms with not (
!
) operators in rules - Fix crash in query DSL parser when using
Rel(X, Y, Z)
syntax - Fix assignment within conditional expression error
- Fix issue where cloning an entity with a name would throw an error
This version includes the following improvements:
[rules]
Implementup
traversal for rules[rules]
Simplify control flow instructions of rule engine[rules]
Add new rule instructions for trivial queries which batches evaluation of multiple terms[rules]
Implement automatic filtering of prefab/disabled entities[rules]
Implement rule instruction reordering to limit evaluation of instructions with only unknown variables[rules]
Improve performance of evaluating queries with exclusive wildcard pairs[rules]
Improve performance of setting data fields for trivial and mixed source queries[meta]
Add newid
primitive type for component ids/pairs[meta]
Use%f
in log statements for doubles instead of%d
[json]
Remove overzealous check on whetherit.ptrs
is NULL in iterator serializer[stats]
Remove redundant REST statistics[stats]
Remove less than useful table statistics[stats]
Remove less than useful id statistics[rest]
Reduce log spam from invalid queries from REST API in release mode[meson]
Make compiling hello world example optional (thanks @apache-hb!)[docs]
Fix broken link in REST manual[docs]
Fix C++ module example in manual[docs]
Fix typos in source & documentation (thanks @waywardmonkeys!)[docs]
Doc improvements and formatting (thanks @waywardmonkeys!)[docs]
Remove redundant comment terminators (thanks @waywardmonkeys!)[ci]
Update GitHub actions toactions/checkount@v4
(thanks @waywardmonkeys!)[ci]
Fix new gcc warnings
Benchmark results
https://github.com/SanderMertens/ecs_benchmark/tree/ab33138f58c7a24cf05f662ac790d7cfbcfbe8e0
Known issues:
#844
#765
#714
#620
#478
#314
New Contributors
- @apache-hb made their first contribution in #1074
- @waywardmonkeys made their first contribution in #1089
Full Changelog: v3.2.9...v3.2.10