Hypnospace Page · @robinpie · README.hsp

t text view · m music · p motion · + zoom · 0 fit · ? this bar

Hypnospace Page

by @robinpie · README.hsp


Robin's .HSP to Web Page Converter

cogs

View / download on GitHub (opens in a new tab)

View / download on GitHub (opens in a new tab)

How to Use

You need to have Hypnospace Outlaw, Python >=3.8, ffmpeg, and numpy installed on your machine. If your page has no music or you pass --no-music, you don't need ffmpeg or numpy.

Then, use the Page Builder that ships with the game to create a page, and save the page wherever you like. .hsp files are also plain json, and the repository contains my analysis of the format, so you can also handwrite pages if you like. Links can point off Hypnospace too: give one an http:// or https:// address and it opens in a new tab, which is something the game cannot do.

Then, simply run the following:

python3 tools\hsppack.py --data "\path\to\your\install\of\Hypnospace Outlaw\data" yourpage.hsp --out mypage

You will get a directory mypage/, which contains ./pages/mypage.html (which you should open), as well as alot of other data to get it running.

Optional flags include --no-music, as well as --flags NAME ... which resolves conditional element states as if those story flags were set. You can also pass a directory instead of a file to convert every `.hsp` under it in one go. Links between the converted pages resolve.

Accessibility

Every page now keeps its text as real text, so screen readers can read it, find in page can find it, and your browser can translate it. Links are real links you can tab through, and images carry alt text wherever the page gives me enough to write one.

Press t, or the Text view button at the top, for the same page as plain HTML. It reflows, it takes your own font size, and it stays readable whatever the page's own colours are doing. It is what you get with JavaScript off, too.

Music and motion each have a button, and both start off if your system asks for reduced motion. The other keys are m for music, p for motion, + and - to zoom, 0 to fit, and ? for the list. Run tools/hspaudit.py to see what is left on a converted site.

Embeds

Pages carry OpenGraph tags, so a link to one previews with its title and description. Pass --base-url https://example.com/mypage and og:url and og:image get filled in as absolute URLs too.

413

chitchatpalscoolpunk aliverainbowbg smallrainbowbg small