summaryrefslogtreecommitdiff
path: root/README.org
diff options
context:
space:
mode:
authorDavid Thompson <dthompson@member.fsf.org>2013-08-25 09:00:17 -0400
committerDavid Thompson <dthompson@member.fsf.org>2013-08-25 09:00:17 -0400
commitcadab63998854244df9a55982369edc51e78babe (patch)
tree185f9ae736e4bf1ea11946053b659531df5c4496 /README.org
parent2c2cc052124b4709075132430e9b67ed49d0f76e (diff)
Clean up example code in README.
Diffstat (limited to 'README.org')
-rw-r--r--README.org20
1 files changed, 9 insertions, 11 deletions
diff --git a/README.org b/README.org
index 178bdc0..bea0dc4 100644
--- a/README.org
+++ b/README.org
@@ -21,8 +21,7 @@
Here is the simplest Guile-2d application (so far).
#+BEGIN_SRC scheme
- (use-modules (figl gl)
- (2d sprite)
+ (use-modules (2d sprite)
(2d game-loop)
(2d window))
@@ -76,12 +75,13 @@
support formats.
#+BEGIN_SRC scheme
- (define sprite (load-sprite "cirno.png"
- #:position #(0 0)
- #:scale (1 1)
- #:rotation (0)
- #:color #xffffff
- #:anchor 'center))
+ (define sprite
+ (load-sprite "cirno.png"
+ #:position #(0 0)
+ #:scale (1 1)
+ #:rotation (0)
+ #:color white
+ #:anchor 'center))
#+END_SRC
Alternatively, you can make a sprite from an existing texture. The
@@ -118,9 +118,7 @@
(define batch (make-sprite-batch))
(with-sprite-batch batch
- (for-each
- (lambda (sprite) (draw-sprite sprite))
- sprites))
+ (for-each draw-sprite sprites))
#+END_SRC
*** Coroutines and Agendas