Replies: 1 comment 1 reply
-
Nope. Bevy sorts data into tables called "archetypes" which each column is a component and each row is an entity. All entities with the same exact set of components live in the same archetype table. Accessing a single entity is basically Iteration is slightly more complex, because query can match multiple archetype tables. Iterating through a single table is very efficient, but there is a cost to jumping from one table to the next. So in practice, the main thing that will slow down iteration is fragmentation. Having lots of different entities with a different set of components on each will force you to jump through a ton of archetype tables. I wouldn't worry about this unless you start actually hitting performance problems, but in general it's the number of different combinations of components you have to watch out for, rather than the number of entities or the number of components on those entities. |
Beta Was this translation helpful? Give feedback.
-
The efficiency of a Query depends on the amount of Component that i establish?
So for example, the retrieving of entities with one component is more efficiently than retrieving entities with three or four components?
Beta Was this translation helpful? Give feedback.
All reactions