Newer
Older
#![windows_subsystem = "windows"]
use bevy::prelude::*;
use game_core::assets::AssetHandles;
use game_core::system::flow::AppState;
use iyes_loopless::prelude::AppLooplessStateExt;
fn main() {
let options = game_core::persistance::fs_utils::read_config_file();
.add_plugins(game_core::system::resources::InitAppPlugins)
.add_plugins(micro_musicbox::CombinedAudioPlugins::<AssetHandles>::new())
.add_plugin(game_core::splash_screen::SplashScreenPlugin)
.add_plugin(game_core::system::camera::CameraManagementPlugin)
.add_plugin(game_core::states::StatesPlugin)
.add_plugin(micro_asset_io::MicroAssetIOPlugin)
.add_plugin(bevy_tweening::TweeningPlugin)
.add_plugin(bevy_ecs_tilemap::TilemapPlugin)
.add_plugins(game_core::ui::AdventUIPlugins)
.add_plugin(game_core::persistance::PersistencePlugin)
.add_plugin(bevy_prototype_lyon::plugin::ShapePlugin)
.insert_resource(options.map(|opts| opts.audio.clone()).unwrap_or_default())