You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
is there anyway to get a view with different types of components, but that they match a certain compile time predicate?
No, there isn't.
Is there anyway I can get all the entities that have components A or B?
The simplest solution is to redesign your component and turn the template parameter into a member, so as to have a single type to filter later on.
Another option is that of using listeners for IsEnergy<T> pools that fill a storage<void> pool somewhere else with the entities of interest. Then you can use the latter to construct your view.
You can also refine the last approach with a mixin to make it transparent/automatic. All mixins receive the registry after all and they know when an element is emplaced or erased, so 🤷♂️ the sigh mixin is an example to take inspiration from eventually.
As the title suggest, is there anyway to get a view with different types of components, but that they match a certain compile time predicate?
For example, lets say I have a trait
IsEnergy
Is there anyway I can get all the entities that have components A or B?
The text was updated successfully, but these errors were encountered: