In my theoretical computer science class i learned about state machines and fell for the idea. After implementing an universal turing machine, i asked myself what other use cases a deterministic automaton could have. I thought I could write an engine for text adventure games using this idea.
Text adventures have traditionally been built in a imperative manner, following a flow chart like pattern. I thought this could have some improvement. So i wrote a deterministic finite state machine in NodeJS, where i can feed my adventure as a YAML file. Said file is basically a set of states, in which each state represents a prompt on the commandline and interactions who are transitions to other states. I found it works pretty well. Unfortunately im a terrible story writer, so i hope one day someone send me a cool adventure that i can play ðŸ™‚