summaryrefslogtreecommitdiff
path: root/scripts/main.scm
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/main.scm')
-rw-r--r--scripts/main.scm10
1 files changed, 6 insertions, 4 deletions
diff --git a/scripts/main.scm b/scripts/main.scm
index 095fa98..2507424 100644
--- a/scripts/main.scm
+++ b/scripts/main.scm
@@ -1,14 +1,16 @@
+(load "./scripts/keys.scm")
+
(define a 0)
(define b (rl-load-texture))
(define (update)
- (cond ((rl-is-key-down 262) (set! b (rl-load-texture))) ;; right
- ((rl-is-key-down 263) (set! a (+ a 1))) ;; left
- ((rl-is-key-down 264) (gc)) ;; down
+ (cond ((rl-is-key-down KEY_RIGHT) (set! b (rl-load-texture))) ;; right
+ ((rl-is-key-down KEY_LEFT) (set! a (+ a 1))) ;; left
+ ((rl-is-key-down KEY_DOWN) (gc)) ;; down
)
)
(define (draw)
(rl-draw-text (number->string a))
-; (rl-draw-texture b)
+ (rl-draw-texture b)
)