From 4848f16eec48b1597a882147aaafbfe937d5e321 Mon Sep 17 00:00:00 2001 From: David Thompson Date: Sun, 3 Nov 2013 18:01:19 -0500 Subject: Fix default key-down event. --- 2d/game-loop.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to '2d/game-loop.scm') diff --git a/2d/game-loop.scm b/2d/game-loop.scm index 79e09b7..78a5655 100644 --- a/2d/game-loop.scm +++ b/2d/game-loop.scm @@ -126,7 +126,8 @@ time in milliseconds that has passed since the last game update." ;; By default, pressing the escape key will pop the current scene, and ;; closing the window will quit the game. (default-events `((key-down . ,(lambda (key mod unicode) - (pop-scene))) + (when (eq? key 'escape) + (pop-scene)))) (quit . ,quit-game))) (define handle-events -- cgit v1.2.3