diff options
author | Henrique Alves <henrique.alves@itsjungle.xyz> | 2024-05-02 00:37:10 +0300 |
---|---|---|
committer | Henrique Alves <henrique.alves@itsjungle.xyz> | 2024-05-02 00:37:10 +0300 |
commit | 510a5d76180f30f1dd75a05927bbcb10bfae8da8 (patch) | |
tree | 4395294fd3fe9076169b467b22f34e2fff22a8b9 /scripts/main.scm | |
parent | aeddacb8d88f41ba7bdf37d39de17d8cf3b6a258 (diff) | |
download | gamejam-slgj-2024-510a5d76180f30f1dd75a05927bbcb10bfae8da8.tar.gz gamejam-slgj-2024-510a5d76180f30f1dd75a05927bbcb10bfae8da8.tar.bz2 gamejam-slgj-2024-510a5d76180f30f1dd75a05927bbcb10bfae8da8.zip |
basic GoL
Diffstat (limited to 'scripts/main.scm')
-rw-r--r-- | scripts/main.scm | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/scripts/main.scm b/scripts/main.scm index 1a5ebb1..f480053 100644 --- a/scripts/main.scm +++ b/scripts/main.scm @@ -2,17 +2,31 @@ (load "./scripts/structs.scm") (load "./scripts/utils.scm") (load "./scripts/prompt.scm") +(load "./scripts/gol.scm") -;; (define a 0) -;; (define b (rl-load-texture)) - +(define camera-offset (make-point)) (define (update) (prompt-update) + + (if (rl-is-key-down KEY_DOWN) + (run-step) + ) ) (define (draw) (prompt-draw) + + (for-each (lambda (cell) + (rl-draw-rectangle + (* (car cell) 30) + (* (cdr cell) 30) + 30 + 30 + (make-color 190 100 255)) + + ) (hash-table-keys current-cells)) + ) |