From b0aecc3fd1982f08567db1ace6428548120e3899 Mon Sep 17 00:00:00 2001 From: 9382 Date: Mon, 14 Oct 2024 20:18:51 +0100 Subject: [PATCH] Fix movement inputs when holding shift --- src/window.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/window.rs b/src/window.rs index 4320c67..0d62e4c 100644 --- a/src/window.rs +++ b/src/window.rs @@ -99,7 +99,7 @@ impl WindowContext<'_>{ keycode=>{ if let Some(input_instruction)=match keycode{ winit::keyboard::Key::Named(winit::keyboard::NamedKey::Space)=>Some(InputInstruction::Jump(s)), - winit::keyboard::Key::Character(key)=>match key.as_str(){ + winit::keyboard::Key::Character(key)=>match key.to_lowercase().as_str(){ "w"=>Some(InputInstruction::MoveForward(s)), "a"=>Some(InputInstruction::MoveLeft(s)), "s"=>Some(InputInstruction::MoveBack(s)),