Add another set of keys for navigating diagonals
This commit is contained in:
parent
d5c48247f3
commit
09de57f67f
@ -339,21 +339,25 @@ pub fn player_input(gs: &mut State, ctx: &mut Rltk) -> RunState {
|
||||
|
||||
// Diagonals
|
||||
VirtualKeyCode::Numpad7
|
||||
| VirtualKeyCode::Home
|
||||
| VirtualKeyCode::Key7
|
||||
| VirtualKeyCode::U
|
||||
| VirtualKeyCode::Q => return try_move_player(-1, -1, &mut gs.ecs),
|
||||
|
||||
VirtualKeyCode::Numpad9
|
||||
| VirtualKeyCode::PageUp
|
||||
| VirtualKeyCode::Key9
|
||||
| VirtualKeyCode::Y
|
||||
| VirtualKeyCode::W => return try_move_player(1, -1, &mut gs.ecs),
|
||||
|
||||
VirtualKeyCode::Numpad1
|
||||
| VirtualKeyCode::End
|
||||
| VirtualKeyCode::Key1
|
||||
| VirtualKeyCode::B
|
||||
| VirtualKeyCode::A => return try_move_player(-1, 1, &mut gs.ecs),
|
||||
|
||||
VirtualKeyCode::Numpad3
|
||||
| VirtualKeyCode::PageDown
|
||||
| VirtualKeyCode::Key3
|
||||
| VirtualKeyCode::N
|
||||
| VirtualKeyCode::S => return try_move_player(1, 1, &mut gs.ecs),
|
||||
|
Loading…
Reference in New Issue
Block a user