Skip to content

Iterate ALL entities (getting EntityRef/EntityMut) #5496

Answered by alice-i-cecile
Moulberry asked this question in Q&A
Discussion options

You must be logged in to vote

This is the best solution currently. World.entity will be O(1) at least, but I expect the overhead to be relatively high compared to an optimized archetype-based solution.

Could you open a feature request issue for this? Ideally we could have a &EntityRef or &mut EntityMut in queries, which would automatically imply exclusive world access 🤔

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@Moulberry
Comment options

Answer selected by Moulberry
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants