The Tricks of Game Programming in a Pure Functional Language