Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for get_many and get_many_mut functions for Assets<T> #16334

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Rajveer100
Copy link

Part of #16244

Objective

Add functions for Assets<T> to retrieve multiple references similar to Query<...>

Solution

The Query type has the get_many and get_many_mut methods to get around this limitation, allowing multiple Entities to be looked up at once, with a dynamic check to prevent the same entity from being accessed multiple times. A similar pattern can be followed here.

@Rajveer100
Copy link
Author

For retrieving mutable references, what do you think is an appropriate way?

@BenjaminBrienen BenjaminBrienen added C-Feature A new feature, making something new possible A-Assets Load files from disk to use for things like images, models, and sounds D-Straightforward Simple bug fixes and API improvements, docs, test and examples S-Needs-Help The author needs help finishing this PR. labels Nov 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Assets Load files from disk to use for things like images, models, and sounds C-Feature A new feature, making something new possible D-Straightforward Simple bug fixes and API improvements, docs, test and examples S-Needs-Help The author needs help finishing this PR.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants