Music and the First Act


As part of my next major update, I wanted to finally introduce some audio elements, so I decided to start by getting some thematic music. The OpenSourceGaming video on Hypnagonia introduced me to the work of Myuu which, as it happens, fits perfectly with the kind of theme I’m going for. It’s maybe a bit too dark at times, but overall, excellent! (Check out his work in Youtube, Spotify, or SoundCloud)

It took me a few hours of listening to some great tunes, but in the end I gathered close to 100 tracks to inject into Hypnagonia. But it was worth it every minute.

Now I had to integrate them into it and I had never done this before. So this time I decided to see if anyone had developed an add-on I could use, and as luck would have it, there was a great add-on for sound management, right here in itch.io: SoundManager!

However, while the addon had a perfectly good feature set, I wanted more! Specifically I wanted my music to be added into a queue and looped continuously. I didn’t want to have just a single song looping all the time per scene. So I needed a queue functionality and since I was going to develop it, I thought I should share it with everyone else as well, by adding it to the addon as a new feature.

Unfortunately, the more I dug into the code to make this happen,the more I realized I neeeded to change to handle it. In the end, I ended refactoring the whole thing and managed to make my music not only loop within the queue, but also crossfade between queue changes.

In the process I added a ton of new features, so if you’re interested in using these in your own game you can check this pull request to see when they’ll be live (or just download the plugin from my own repo)

So now I had the setup, but there was one small problem. The amount of music I added at that quality, means my game had bloated to almost 1Gb of size. While this might be tolerable for desktop versions, it would make the browser version prohibitive.

So first step: reduce the quality. Still ~300Mb. Still too much for browser.

So this time I turned into some bash scripting and github actions again. I made an extra step which marks all but a few music, chosen randomly, to not be exported in the HTML. This means that the HTML version still maintains some music, but that it repeats way more often. The desktop versions on the other hand, remain at ~300MB, but provide hours of music!

On the plus side, every time I push a new update, you’re going to get different music available in the html version, so I think this works out OK in the end. :)

So including the (mostly) completed first act, a complete card pool, new art, new Torments and non-combat encounters; it’s time to move to the next minor release and make it all available on Itch.io.

Try it out, and tell me what you think. And of course, do visit and start listening to Myuu asap :)

Cover Image by David Revoy - BY-CC-ND 4.0

Files

hypnagonia-html5.zip Play in browser
Version v0.19.0 Dec 06, 2021
Hypnagonia_Windows.exe 328 MB
Version v0.19.0 Dec 06, 2021
Hypnagonia_Linux.x86_64 330 MB
Version v0.19.0 Dec 06, 2021
hypnagonia-osx.zip 309 MB
Version v0.19.0 Dec 06, 2021

Get Hypnagonia

Download NowName your own price

Leave a comment

Log in with itch.io to leave a comment.