vleue / bevy_embedded_assets

Bevy plugin to embed assets in your game

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Plugin implementation doesn't exists

Andrea-moth opened this issue · comments

1  error[E0277]: the trait bound `bevy_embedded_assets::EmbeddedAssetPlugin: bevy::prelude::Plugin` is not satisfied
    --> src/main.rs:11:60
     |
 11  |                 .add_before::<bevy::asset::AssetPlugin, _>(EmbeddedAssetPlugin),
     |                  ----------                                ^^^^^^^^^^^^^^^^^^^ the trait `bevy::prelude::Plugin` is not implemented for `bevy_embedded_assets::EmbeddedAssetPlugin`
     |                  |
     |                  required by a bound introduced by this call
     |
     = help: the following other types implement trait `bevy::prelude::Plugin`:
               bevy::a11y::AccessibilityPlugin
               bevy::app::ScheduleRunnerPlugin
               bevy::asset::diagnostic::AssetCountDiagnosticsPlugin<T>
               bevy::audio::AudioPlugin
               bevy::core_pipeline::CorePipelinePlugin
               bevy::core_pipeline::blit::BlitPlugin
               bevy::core_pipeline::bloom::BloomPlugin
               bevy::core_pipeline::core_2d::Core2dPlugin
             and 62 others
 note: required by a bound in `bevy::app::PluginGroupBuilder::add_before`
    --> /home/freyja-moth/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bevy_app-0.10.1/src/plugin_group.rs:124:42
     |
 124 |     pub fn add_before<Target: Plugin, T: Plugin>(mut self, plugin: T) -> Self {
     |                                          ^^^^^^ required by this bound in `PluginGroupBuilder::add_before`

 For more information about this error, try `rustc --explain E0277`.
 error: could not compile `game` (bin "game" test) due to previous error

You know I really have no idea how I got into this situation.

This is my current code, which is almost identical to the example given

pub mod prelude;
pub mod state;

use prelude::*;

fn main() {
    App::new()
        .add_plugins(
            DefaultPlugins
                .build()
                .add_before::<bevy::asset::AssetPlugin, _>(EmbeddedAssetPlugin),
        )
        .add_plugins(GamePlugins)
        .run()
}

I imagine this would be the relevant code, but I have no idea how its incorrect

Apologies, this isn't an actual issue. I forgot to update bevy, which messed with the implementation

yup the compilation error is definitely not helpful for that case... no worries!