Skip to content

Commit

Permalink
Fix arrow keys
Browse files Browse the repository at this point in the history
  • Loading branch information
alexpetros committed Sep 17, 2024
1 parent f2cedde commit 608a3c5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions www/ice-puzzles.html
Original file line number Diff line number Diff line change
Expand Up @@ -115,9 +115,9 @@
// Handle keypresses
function handleKeydown(e) {
if (e.key === 'Right' || e.key === 'ArrowRight') right()
if (e.key === 'Left' || e.key === 'ArrowLeft') down()
if (e.key === 'Left' || e.key === 'ArrowLeft') left()
if (e.key === 'Up' || e.key === 'ArrowUp') up()
if (e.key === 'Down' || e.key === 'ArrowDown') left()
if (e.key === 'Down' || e.key === 'ArrowDown') down()
}
document.addEventListener('keydown', handleKeydown)

Expand Down

0 comments on commit 608a3c5

Please sign in to comment.