Flanny.app
Apps Blog Me

Yes, Chef!

A DnD inspired game

January 2025

This past year I got into DnD. I love the game mechanics and I think dice look pretty. I wanted to program something that captured the storytelling aspect of DnD. I also found a dice UI library that I was really excited to try out.

Reusing some code from an old game, I came up with a scrolling-text choose-your-own-adventure story.

The first one I wrote was about trying to get a job as a chef at a restaurant, but the reason there’s a job open is very suspicious. Players could get the job as a roast chef, pastry chef, become head chef, not get the job, or even die. It’s fun, and silly.

The Game

At the start a user is presented with some narration.

Intro

Eventually they meet characters and get to make dialog choices.

Choice

If they choose something with uncertainty, they’ll have to roll dice to see the outcome. When that happens, dice fly across the screen and roll until they settle on a result.

Roll

The Editor

While working on the game, trying to keep track of all the nodes pointing to each other was maddening (see Blackmirror’s Bandersnatch). I needed a tool to help me configure and visualize this multi-linear story.

Using react-flow, I was able to create a flowchart editing system that shows the whole branching timeline of the game. Dialog nodes point to choice nodes, point to roll nodes. Scores can be tallied, items added to inventory, story progress tracked. Then to check, the game can be started in playtest mode.

Using the editor can be very fun, and I think people would like it, and make some really interesting things with it. My goal for the future is to allow anyone to log in, write their own stories, and share them out with friends.

FaunaDB

When I first programmed this editor, the nodes were stored in FaunaDB, a simple object store perfect for this use case. While I was working on it, FaunaDB went out of business. They gave all their customers about a month’s warning that their data would be lost (a ridiculously short amount of time). To get around it I exported all the example games I had been working on and started to rebuild in MongoDB.

Thoughts on Generative AI

I want to keep working on this project. There is all sorts of talk about bringing Generative AI into video games, most of which I disagree with. I wrote more about my thoughts on Generative AI’s potential place in this project in another post.