summaryrefslogtreecommitdiff
path: root/examples/tilemap.scm
diff options
context:
space:
mode:
authorDavid Thompson <dthompson2@worcester.edu>2013-11-03 20:03:07 -0500
committerDavid Thompson <dthompson2@worcester.edu>2013-11-03 20:03:07 -0500
commit777e31518c8ae52e9e15867fb60c958fa7a15610 (patch)
tree873b2cec6608ef62bbc4e9ecae85d31fe4bf6cc4 /examples/tilemap.scm
parent49f93e5fe7261dd520a0013508fd02086af6ae17 (diff)
Update examples to use new scene/stage system.
Diffstat (limited to 'examples/tilemap.scm')
-rw-r--r--examples/tilemap.scm20
1 files changed, 12 insertions, 8 deletions
diff --git a/examples/tilemap.scm b/examples/tilemap.scm
index a60ee18..141184e 100644
--- a/examples/tilemap.scm
+++ b/examples/tilemap.scm
@@ -2,9 +2,11 @@
(srfi srfi-9)
(srfi srfi-42)
(2d game)
+ (2d game-loop)
+ (2d scene)
+ (2d sprite)
(2d texture)
(2d tileset)
- (2d sprite)
(2d vector2))
;;;
@@ -81,13 +83,15 @@
tileset
map-tiles))))
-(define-scene demo
- #:title "Demo"
- #:draw (lambda (map) (draw-map-layer map))
- #:state (build-map))
+(define tilemap-scene
+ (make-scene
+ "Tilemap"
+ #:init build-map
+ #:draw draw-map-layer))
-(define-game tilemap
- #:title "Tilemap"
- #:first-scene demo)
+(define tilemap
+ (make-game
+ #:title "Tilemap"
+ #:first-scene tilemap-scene))
(run-game tilemap)