diff --git a/.gitignore b/.gitignore index 44dc315..4a937d8 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,5 @@ # Assets and songs -assets +assets/textures songs # ---> Rust diff --git a/assets/fonts/LinLibertine_Rah.ttf b/assets/fonts/LinLibertine_Rah.ttf new file mode 100644 index 0000000..e1dc224 Binary files /dev/null and b/assets/fonts/LinLibertine_Rah.ttf differ diff --git a/src/main.rs b/src/main.rs index d8877d6..0e08c42 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,6 +1,7 @@ use bevy::{ prelude::*, window::PresentMode, + winit::WinitSettings, }; #[derive(Component)] @@ -30,13 +31,14 @@ fn main() { resolution:(640., 480.).into(), present_mode: PresentMode::AutoVsync, // Tells wasm to resize the window according to the available canvas - fit_canvas_to_parent: true, + fit_canvas_to_parent: false, // Tells wasm not to override default event handling, like F5, Ctrl+R etc. prevent_default_event_handling: false, ..default() }), ..default()})) .add_plugin(HelloPlugin) + .insert_resource(WinitSettings::desktop_app()) .add_startup_system(setup) .add_system(button_system) .run(); @@ -126,7 +128,7 @@ fn setup(mut commands: Commands, asset_server: Res) { parent.spawn(TextBundle::from_section( "Button", TextStyle { - font: asset_server.load("fonts/FiraSans-Bold.ttf"), + font: asset_server.load("fonts/LinLibertine_Rah.ttf"), font_size: 40.0, color: Color::rgb(0.9, 0.9, 0.9), },