Adding a “Stars without Number” Dataset for gm-notepad

The book title “Revised Stars without Number: A Science Fiction Role Playing Game by Kevin Crawford” overlaying a star field
Using Stars without Number: Revised Edition’s EPUB file to extract content. Curious about Stars without Number, learn more in .

Too Long; Didn't Read (TL;DR 📖) Grab my gm-notepad-swn-free dataset for some tables to add to your gm-notepad.


A blog reader reached out to me asking about parsing the Stars without Number: Revised Edition (SWN 📖) ePub (ePub 📖). I pointed them to the code I wrote to generate the data set. They need to secure their own ePub; Which is available as part of the paid version of Stars without Number.

I have continued refining my gm-notepad tool. See about gm-notepad I have developed gm-notepad into a satisfactory funtional state.

I wanted tables to feed into gm-notepad. And I immediately thought of Stars without Number: Revised Edition. Or frankly anything by Kevin Crawford, as he apparently dreams in random tables

First, I looked at munging data from swnt, a command line tool for “Stars without Number”. It was doable but I did a bit more digging.

Looking at my folder full of Sine Nomine products, I saw StarsWithoutNumberRevised-DeluxeEdition-011418.epub. On a lark I typed vim StarsWithoutNumberRevised-DeluxeEdition-011418.epub, and got the following:

1 " zip.vim version v28
2 " Browsing zipfile StarsWithoutNumberRevised-DeluxeEdition-011418.epub
3 " Select a file with cursor and press <enter>
5 mimetype
6 OEBPS/cover.xhtml
7 OEBPS/SWNRevised-DeluxePDF-011418-EPUB.xhtml
… more lines of no importance to me

And a part my brain remembered: “Of course and EPUB is built from an Hypertext Markup Language (HTML 📖) document.” I had forgotten (or didn’t know) that an EPUB is a fancy ZIP file.

Jackpot! I could use nokogiri to parse the OEBPS/SWNRevised-DeluxePDF-011418-EPUB.xhtml document and extract the tables.

With some Ruby coding, I got the basic process down, and generated the tables for gm-notepad-swn-free. I have a separate code repository that I’m working on for data extraction first from Stars without Number, then for other Sine Nomine products that have an EPUB. I will only release the datasets for tables that are freely available. At present I have:

  • One Roll Non-Player Character (NPC 📖)
  • One Roll Patron
  • One Roll Urban Encounter
  • One Roll Wilderness Encounter
  • Planetary Tag

Thank you Kevin Crawford for taking the time to release your content as an EPUB. I look forward to writing a library that others can use to extract tables from Sine Nomine’s publications.