diff options
author | Henrique Alves <henrique.alves@itsjungle.xyz> | 2024-04-25 23:51:58 +0300 |
---|---|---|
committer | Henrique Alves <henrique.alves@itsjungle.xyz> | 2024-04-25 23:51:58 +0300 |
commit | a7cc19f9e254d0ee391b2b65ef6da6e471da803c (patch) | |
tree | 5ef2d2c1974c4500942f78e38eccc06b38fafecb /scripts/main.scm | |
parent | 3f382e6e0a494baaf3d4d104c1af0630fb3817a9 (diff) | |
download | gamejam-slgj-2024-a7cc19f9e254d0ee391b2b65ef6da6e471da803c.tar.gz gamejam-slgj-2024-a7cc19f9e254d0ee391b2b65ef6da6e471da803c.tar.bz2 gamejam-slgj-2024-a7cc19f9e254d0ee391b2b65ef6da6e471da803c.zip |
Adding more API
Diffstat (limited to 'scripts/main.scm')
-rw-r--r-- | scripts/main.scm | 25 |
1 files changed, 11 insertions, 14 deletions
diff --git a/scripts/main.scm b/scripts/main.scm index 96053b1..095fa98 100644 --- a/scripts/main.scm +++ b/scripts/main.scm @@ -1,17 +1,14 @@ (define a 0) -(define b 0) +(define b (rl-load-texture)) -(define update - (lambda () - (set! a (+ a 1)) - (set! b (rl-load-texture)) - ;;(display b) - ;;(gc) - )) +(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 + ) + ) -(define draw - (lambda () - (rl-draw-text (number->string a)) - (display "ue") - (rl-draw-texture b) - )) +(define (draw) + (rl-draw-text (number->string a)) +; (rl-draw-texture b) + ) |