Pre-release

Devlog:Fungibles and Stacks

July 28, 2026

Near the end of December 2025, my attention was caught by an announcement for Text Adventure Literacy Jam 2026.

I was intrigued by enough by TALJ to want to submit a game. Though AdventureJS wasn't in a state to release to the public, it was certainly workable enough that I could make a game within its known limitations. So I worked up an idea that I liked, did a little research, and started roughing in a small game. And then, I decided that my very first puzzle, a desert sandstorm faux-maze, needed an infinite sack of pistachios to use as faux-breadcrumbs. But I hadn't yet gotten around to supporting fungible assets, aka identical items like coins or nuts or grapes or breadcrumbs.

I immediately got started on a fungible system. Since fungibility needed to be class-wide but was not in and of itself a class, I came up with a way to dynamically add a static fungible flag to an already defined class. Then, because AdventureJS's word recognition system needs items placed in the world to work, I created a new abstract Platonic class, so that a platonic instance could act as a stand-in for fungible assets that hadn't been created yet. Then I had to revise all my asset management routines to handle multiple identical instances. And then I started working on another abstract class, a Bundle class that could stand in for multiple instances. And at that point, after going down that path for two or three months, I finally realized how stupidly over-complicated it all was.

I ripped it all out. And started over. This time I started with a new state class, Stack, which could be added to any asset (state classes are classes that get appended to assets, which contain specialized properties and functions). Stack adds quantity management to assets: one asset can represent many; with methods for adding, subtracting, merging, and spawning new stacked assets. And then I had to revise all my asset management routines – again – to handle stacks; present stack counts on inventory lists; update name and pronoun handling to reflect singular or plural status; and ensure that placeholders like {it's} and {they're} render accordingly.

Meanwhile, TALJ disappeared into my rear view mirror. But overall, the stack system seems much more rational than the fungible/platonic/bundle system, so it was worth the time to remake it.

← Seven Years In | All Posts |