Tech News
← Back to articles

Show HN: Micropolis/SimCity Clone in Emacs Lisp

read original related products more articles

ElCity (Emacs Lisp City)

Overview

ElCity is a small, turn-based city builder that runs entirely inside Emacs. The UI is ASCII-based and optimized for terminal Emacs sessions. The core simulation is deterministic and pure, while the UI handles rendering and input.

This is an excercise in implementing the “functional core / imperative shell” architecture in a moderately sized project that with a developed UI. Every tile type is defined through a DSL, with a strong separation between state and effects. Most functions in the core are either pure or pure-ish.

Benefits to this approach:

easy to debug

scalable in terms of code: reduced cognitive load on both people and LLMs

easy UX/UI as state is always localized

easy to extend (with some discipline)

easy to autotest

... continue reading