Newer
Older
use bevy::prelude::*;
use iyes_loopless::prelude::{AppLooplessStateExt, ConditionSet};
use crate::system::flow::AppState;
mod components;
mod systems;
pub struct SplashScreenPlugin;
impl Plugin for SplashScreenPlugin {
fn build(&self, app: &mut App) {
app.add_enter_system(AppState::Splash, systems::setup_splash_screen)
.add_system_set(
ConditionSet::new()
.run_in_state(AppState::Splash)
.with_system(systems::tick_splash_system)
.into(),
)
.add_exit_system(AppState::Splash, systems::remove_splash_entities);
}
}