Dec. 11, 2015

Zero Asset Game Mockup

A "zero asset game" is a game that does not use any external art assets.

Game art is instead generated procedurally or by using artifacts of the rendering environment.

The following is a screenshot of a tiny game engine I built a little while ago in ClojureScript.

Tiny CLJS Game Engine Screenshot

The renderer runs on Facebook's React library so it is just a couple of lines of code.

I've spread it over several lines here for readability:

; DOM "scene grapher"
[:div {:id "game-board"}
  (doall
    (map
      (fn [[id e]]
        [:div {:class (str "sprite c" (:color e))
           :key id
           :style (compute-position-style e)
           :on-click (fn [ev] (sfx/play :blip))}
        (:symbol e)])
      (:entities @game-state)))]

The sprites are utf8 characters which are instantiated like this:

(make-entity {:symbol "◍"
              :color 0
              :pos [-20 300]
              :angle 0
              :behaviour behaviour-rock})

The function behaviour-rock here gets called once per frame and returns the new immutable entity-state for the next frame.

When you click on something the blip sound is generated procedurally in the browser using jsfxr.

Nov. 8, 2015

Fubbles title screen

This is a video game I made for Scout to help her practice using a gamepad.

Play it! You'll need at least one gamepad and Firefox or Chrome.

  • It's hard to find nice games that fit the search "two player gamepad-enabled couch-co-op suitable for four year olds".

  • Game design for a four year old is quite nuanced. To make a fun game without all of the normal risk reward mechanics basically comes down to "make rude noises".

  • It's 360 lines of ClojureScript, rendered in the browser DOM with React. It took me a handful of evenings over a period of one month to develop.

  • I don't play many games, but the gamepad is probably my favourite human-computer interface.

Fubbles title screen

Source code: https://github.com/chr15m/fubbles/

Update

infinitelives Logo

Fubbles is the first game I have made using the new infinitelives ClojureScript library for game development that my friend Crispin and I have been building.

Oct. 25, 2015

screenshot.png

miniCast is a self-hosted web app for listening to podcasts.

I wrote it while learning ClojureScript. The back-end API is written in PHP. My friend George came up with the name and design.

June 17, 2015

Hy is a Clojure-like LISP that compiles to Python bytecode. Blender is a popular Free and Open Source 3d modelling program. This is a little livecoding experiment I put together with the two of them.

Source code is on GitHub.

Jan. 29, 2015

Last weekend was Global GameJam. My buddy Crispin suggested we use Clojure, a non-traditional member of the LISP family running on the Java virtual machine, and its browser-friendly cousin ClojureScript.

Here is the game we built together, using graphics from Kenney.nl:


(click to play)

You can find the source code on GitHub.

A couple of weeks ago I installed Leiningen, the Clojure package/dependency manager, and the VIM plugins, and started practicing.

Literally every night for two weeks now I have been dreaming in parentheses. Writing code has never felt so comfortable. I think I may officially be a LISP convert.