mirror of
https://github.com/Xevion/Pac-Man.git
synced 2026-01-31 08:25:06 -06:00
chore: remove unnecessary log, simplify match to if let
This commit is contained in:
@@ -30,8 +30,8 @@ pub fn player_system(
|
|||||||
|
|
||||||
// Handle events
|
// Handle events
|
||||||
for event in events.read() {
|
for event in events.read() {
|
||||||
match event {
|
if let GameEvent::Command(command) = event {
|
||||||
GameEvent::Command(command) => match command {
|
match command {
|
||||||
GameCommand::MovePlayer(direction) => {
|
GameCommand::MovePlayer(direction) => {
|
||||||
movable.requested_direction = Some(*direction);
|
movable.requested_direction = Some(*direction);
|
||||||
}
|
}
|
||||||
@@ -39,9 +39,6 @@ pub fn player_system(
|
|||||||
state.exit = true;
|
state.exit = true;
|
||||||
}
|
}
|
||||||
_ => {}
|
_ => {}
|
||||||
},
|
|
||||||
GameEvent::Collision(a, b) => {
|
|
||||||
tracing::info!("Collision between {:?} and {:?}", a, b);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user