Skip to content

Example Racket games and demos using the 'How to Design Programs' framework with sprites, worlds, animation and game logic.

License

Notifications You must be signed in to change notification settings

ericclack/racket-examples

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

racket-examples

A set of example Racket games and demos that I created on my journey learning Racket. They use the How to Design Programs framework and demonstrate sprites, worlds, animation and game logic.

My starting place for learning Racket was the books: Realm of Racket http://www.realmofracket.com/, The Little Schemer and The Seasoned Schemer https://mitpress.mit.edu/books/little-schemer-fourth-edition

After that I created a set of games / demos (which you'll find in this repo), to help me prove I understood the principles and explore the language further. The games are pretty basic, but hopefully interesting to explore.

If you find these examples useful feel free to leave suggestions on the issues page, or email me comments.

Some thoughts on Racket:

  • I found each game pretty hard to write (my background is Python and other procedural languages) but once complete, surprising low in defects.
  • After getting over the lack of objects I found the functional approach produced a simpler design.
  • When making a game do objects and mutable state better model what's going on?

Contents:

  • asteroids -- a simple arcade game.

asteroids screen shot

  • boids -- bird like objects that flock together.

  • boulder -- a take on Boulder Dash.

boulder screen shot

stars screen shot

  • thrust -- a take on the game Thrust from 1986.

Many of the app filenames have numbers, these indicate major changes -- so it's easy to look back at previous, simpler versions.

About

Example Racket games and demos using the 'How to Design Programs' framework with sprites, worlds, animation and game logic.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages