From 79262ce3b4b6fa5469283e671d623497a51575ef Mon Sep 17 00:00:00 2001 From: Quaternions Date: Mon, 2 Oct 2023 03:03:07 -0700 Subject: [PATCH] styling --- src/main.rs | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-) diff --git a/src/main.rs b/src/main.rs index be358a0..5508939 100644 --- a/src/main.rs +++ b/src/main.rs @@ -868,16 +868,16 @@ impl framework::Example for GraphicsData { winit::event::ElementState::Released => false, }; if let Some(input_instruction)=match keycode { - 17 => Some(InputInstruction::MoveForward(s)),//W - 30 => Some(InputInstruction::MoveLeft(s)),//A - 31 => Some(InputInstruction::MoveBack(s)),//S - 32 => Some(InputInstruction::MoveRight(s)),//D - 18 => Some(InputInstruction::MoveUp(s)),//E - 16 => Some(InputInstruction::MoveDown(s)),//Q - 57 => Some(InputInstruction::Jump(s)),//Space - 44 => Some(InputInstruction::Zoom(s)),//Z - 19 => if s{Some(InputInstruction::Reset)}else{None},//R - 1 => { + 17=>Some(InputInstruction::MoveForward(s)),//W + 30=>Some(InputInstruction::MoveLeft(s)),//A + 31=>Some(InputInstruction::MoveBack(s)),//S + 32=>Some(InputInstruction::MoveRight(s)),//D + 18=>Some(InputInstruction::MoveUp(s)),//E + 16=>Some(InputInstruction::MoveDown(s)),//Q + 57=>Some(InputInstruction::Jump(s)),//Space + 44=>Some(InputInstruction::Zoom(s)),//Z + 19=>if s{Some(InputInstruction::Reset)}else{None},//R + 01=>{//Esc if s{ self.manual_mouse_lock=false; match window.set_cursor_grab(winit::window::CursorGrabMode::None){ @@ -919,8 +919,7 @@ impl framework::Example for GraphicsData { None }, _ => {println!("scancode {}",keycode);None}, - } - { + }{ self.physics.run(time); self.physics.process_instruction(TimedInstruction{ time, @@ -948,7 +947,7 @@ impl framework::Example for GraphicsData { winit::event::DeviceEvent::MouseWheel { delta, } => { - println!("mousewheel{:?}",delta); + println!("mousewheel {:?}",delta); if false{//self.physics.style.use_scroll{ self.physics.run(time); self.physics.process_instruction(TimedInstruction{