NiklasEi / bevy_asset_loader

Bevy plugin helping with asset loading and organization
Apache License 2.0
485 stars 54 forks source link

Stageless #47

Closed freiksenet closed 2 years ago

freiksenet commented 2 years ago

Did a stab at implementing stageless. There is some cursed hairiness with ExclusiveSystem traits in bevy/iyes_loopless, so sorry for hairy code at places.

Note that this requires your state to be pre-initialized before AssetLoader, I think it's limitation of how iyes_loopless does State.

freiksenet commented 2 years ago

Fixed tests, whew that was fun.

freiksenet commented 2 years ago

Thanks, will fix the comments.

NiklasEi commented 2 years ago

I understood now why the tests are red. Could you split the CI job into one test job for bevy_asset_loader_derive and one for bevy_asset_loader, please? You can add --package bevy_asset_loader{_derive} to the cargo hack command to only run in that package. The command for bevy_asset_loader_derive does not need any feature grouping.

freiksenet commented 2 years ago

Should be good now :)

NiklasEi commented 2 years ago

It looks like a cargo fmt --all run is missing.

If you've had enough of fighting with the CI, I could also merge the PR. The CI issues can still be fixed on the stageless branch. Just say the word :slightly_smiling_face: Thank you for all the work!

freiksenet commented 2 years ago

Haha, this is fine, super smooth comparing to CI at my day job.

freiksenet commented 2 years ago

I don't understand, it passes on my machine on windows O_O

NiklasEi commented 2 years ago

Could you try adding --clean-per-run to the cargo hack command?

NiklasEi commented 2 years ago

I also don't understand what's happening here. The test is green, but the process fails. Locally everything seems fine, too. I will merge and take a look at the CI setup separately.

Thanks again for the implementation 👍