Detective
Detective is a JavaScript (Deno) program for writing and running interactive fiction. The writer creates a JSON document with a specific structure that describes rooms, objects, events, etc. They can then run the program with Deno and play through the result.
Installation
Detective is written for Deno, which is required. See installation instructions here.
Once you have Deno and the repo, you can run deno task start
from inside the
project, and the little demo story should start.
Commands
Currently, the commands are very simple.
inventory
checks the players inventory.
go {direction}
moves the player in the given direction.
take {item}
picks up the given item.
use {item}
uses the given item.
quit
exits the program.
Writing your own story
The format for the JSON file is shown in more detail in the