Skip to content
Discussion options

You must be logged in to vote

There's not much you can really do here with Bevy's asset system - we do indeed assume that there aren't any cycles, which provides a significant performance improvement. We don't need to get the transitive closure of asset dependencies, we can just wait for all direct dependencies to be loaded-with-dependencies. I wouldn't be keen on us trying to fix this.

However you can solve this yourself. You can use the VisitAssetDependencies trait to get the dependencies of a particular asset and then compute the transitive closure yourself, ignoring any assets that you've already visited. You'll need to add the #[dependency] attribute to your assets' handles, but it's quite reasonable. Unfortunate…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@logic-geek
Comment options

Answer selected by ChristopherBiscardi
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