From 5afda5e8180c1956cc53bfa8ab91a72c8b1098dc Mon Sep 17 00:00:00 2001 From: Sergei Surovtsev Date: Tue, 4 Jul 2023 16:26:54 +0300 Subject: [PATCH] clippy fixes --- src/components.rs | 4 ++-- src/systems.rs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components.rs b/src/components.rs index 97a9097..3639784 100644 --- a/src/components.rs +++ b/src/components.rs @@ -108,13 +108,13 @@ impl LdtkEntity for PlayerBundle { ..Default::default() }; - return PlayerBundle { + PlayerBundle { animation_indices, animation_timer: AnimationTimer(Timer::from_seconds(0.1, TimerMode::Repeating)), sprite_bundle, collider_bundle, ..default() - }; + } } } diff --git a/src/systems.rs b/src/systems.rs index aa55ee7..cb5eacb 100644 --- a/src/systems.rs +++ b/src/systems.rs @@ -94,7 +94,7 @@ pub fn animate_sprite( } } -pub fn movement(input: Res>, mut query: Query<(&mut Velocity), With>) { +pub fn movement(input: Res>, mut query: Query<&mut Velocity, With>) { for mut velocity in &mut query { let right = if input.pressed(KeyCode::D) { 1. } else { 0. }; let left = if input.pressed(KeyCode::A) { 1. } else { 0. };