Functional Game Engine Design for the Web
summary
A functional, data‑driven web game engine is built with Clojure/ClojureScript using an entity‑component‑system where game state is a hashmap and systems compose into a single state -> state loop. Tooling includes REPL, Devcards and a React inspector that live‑edits specs. Performance notes: targets 60 FPS, runs 100+ objects, observes 7–10% GC time, gets 30–40% speedups from static functions and Google Closure Compiler advanced optimizations. Practical rules: prefer multiple arities over partials, avoid multimethods, reduce intermediate collections, use transients/arrays or loop/reduce for hot paths.
AI-written summary · about
chapters (9)
- 0:00Start
- 0:56What is a game?
- 2:00Why another game engine for the web?
- 2:44The appeal of functional programming to express complex games
- 6:15Modularity
- 22:37Tooling
- 26:05Performance tuning
- 26:23Use the profiler
- 32:42Demo
related talks
09mGame Development in Clojure
35mGame Development Development
34mModern Web Game Development
40mFunctional Client-Side ClojureScript UI Programming with Webfui
46mBuild Your Own Game Engine in the Browser No experience necessary, all experience
18mWell I Wouldn't Want To Make a *Dys*functional Game
12mLevel Up: Why TypeScript/JS for game development?
43mOptimizing Legacy Web UIs Inside a AAA Game Engine
