A collection of open-source text based adventures
This is a demo how to use the quaire-library to create text based adventures.
Fell free to create pull-requests with your very own Game story!
- Node.js >= 22.12
- npm 11
npm installnpm run devnpm run build
npm run previewnpm testnpm run typecheck
npm run lint
npm run prettiernpm run test:release runs all checks. The pre-commit hook runs it, too.
Commit messages follow Conventional Commits.
A game is a list of quaire question definitions in src/games/<game-id>/index.ts.
Besides the built-in types (e.g. SINGLE_SELECT and INPUT), games can use the DIALOG type from src/quaire.ts.
A dialog prints its lines, and <%= key %> inserts a former answer.
Add a test with validateDefinition() to find mistakes in your data, see tests/unit/games.