Skip to content

Conversation

cart
Copy link
Member

@cart cart commented Dec 3, 2020

Fixes #986

We were largely just missing a bunch of #[reflect(Component)] calls, but also some type registrations. We now automatically register Handle<T> when an asset is registered.

I did need to make Handle<T>::from_weak_u64 non-const to make the derive work (I moved that method to HandleUntyped). I'm considering a manual Handle reflect impl instead (which would probably allow us to keep const Handle<T>

@cart cart added C-Bug An unexpected or incorrect behavior A-Assets Load files from disk to use for things like images, models, and sounds labels Dec 3, 2020
@cart
Copy link
Member Author

cart commented Dec 3, 2020

I think I'm cool with using HandleUntyped for const handles instead of Handle<T>. We can always re-add const Handle<T> when #![feature(const_fn)] stabilizes.

@cart cart merged commit 704a116 into bevyengine:master Dec 3, 2020
@fopsdev fopsdev mentioned this pull request Jan 24, 2021
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-Bug An unexpected or incorrect behavior

Projects

None yet

Development

Successfully merging this pull request may close these issues.

load_gltf example not rendering

1 participant