Skip to content

Latest commit

 

History

History
189 lines (131 loc) · 6.98 KB

README.md

File metadata and controls

189 lines (131 loc) · 6.98 KB

json2pdf for Blood on The Clocktower

version GitHub issues GitHub last commit GitHub pull requests

Yet Another Custom Script Generator for Blood on the Clocktower

With apologies to those in Weird Paper Size Land™, this project currently creates A4 size PDFs. I haven't tried viewing, printing or scaling to Letter. If there's huge demand I may look into this later.

Requirements

  • python 3.11, or newer
  • poetry
  • make is strongly recommended, but you can skip it if you know what your doing

Usage

No Scripts Are Stored In This Project Overnight

To get some scripts to test/work with:

make grab-some-scripts

If you're feeling bold, you can grab and render in one:

make grab-some-scripts all-scripts

Sanity Check

The easiest way to get started is to generate a copy of the Trouble Brewing script:

make tb

Generated files are saved in the pdfs/ directory.

Single Script

To generate a PDF for a custom script, download the JSON, and use make process. For example:

make process INPUT_FILE="scripts/No Roles Barred.json"

All Scripts

To generate PDF files for all files in the scripts directory you can use:

make all-scripts

Sample Output

These have been rendered with this project, and then the PDF was exported to the image files here. These are just meant to be samples for easy viewing. For best results generate a PDF.

Trouble Brewing

This script shows how the official "starter" script looks.

Trouble Brewing - Player Sheet
Trouble Brewing - First Night
Trouble Brewing - Other Nights

No Roles Barred

This script was the script that made me aspire to better custom generated scripts.

No Roles Barred - Player Sheet
No Roles Barred - First Night
No Roles Barred - Other Nights

Let's Test Some Jinxes

[This script](scripts/Let's Test Some Jinxes.json) script was generated purely to have something to test our output with jinxes in a script. There are probably more than you'd really want, or have, in a legit custom script so don't panic if it's slightly weird in places...

Let's Test Some Jinxes - Player Sheet
Let's Test Some Jinxes - First Night
Let's Test Some Jinxes - Other Nights

Reptiles!

This script is a custom script that I've played, and it turns out this is a good test of "cramming things into one page" and using Top Sekrit data from the generated script.

Reptiles! - Player Sheet
Reptiles! - First Night
Reptiles! - Other Nights

Acknowledgements

Clearly I wouldn't be doing any of this without the existence of Blood on the Clocktower, or the existence of custom scripts.

I always aspire to take something and make it better (for some value of better) so after seeing the functional PDFs generated from the script tool and later the beauty of the No Roles Barred I went on a personal quest to try to generate "beautiful" PDFs from the tool's JSON.

I stumbled across LectronPusher's generator and thought, "I could tweak this, and be done". I soon realised that life is too short to learn LaTeX and after a pause to ruminate I decided to pull the best parts together and sprinkle some Chisel-magic into the mix.

For better or worse, this project is the result of that desire.

Desires

  • be able to generate something closely resembling the No Roles Barred style
  • be reasonably simple to edit/restyle
  • use existing resources for information (*.json from other tools)

Attribution