From 107ac54f43dc24f1067e17a57a6599b089d17d04 Mon Sep 17 00:00:00 2001 From: David Thompson Date: Sat, 6 Jul 2013 18:58:10 -0400 Subject: Change sprite-batch-draw parameter list to use optional keyword arguments. --- examples/tilemap.scm | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'examples/tilemap.scm') diff --git a/examples/tilemap.scm b/examples/tilemap.scm index 259bfed..070793e 100644 --- a/examples/tilemap.scm +++ b/examples/tilemap.scm @@ -69,13 +69,13 @@ (define map #f) (define (tiles->texture-regions width height tileset tiles) - (list->array - 2 - (list-ec - (: y height) - (list-ec - (: x width) - (vector-ref tileset (array-ref tiles y x)))))) + (define (texture-region-at x y) + (vector-ref tileset (array-ref tiles y x))) + + (let ((regions (list-ec (: y height) + (list-ec (: x width) + (texture-region-at x y))))) + (list->array 2 regions))) (define (key-down key mod unicode) (cond ((any-equal? key (keycode escape) (keycode q)) -- cgit v1.2.3