Sirens Post Mortem

My Entry

This Ludum Dare was definitely the craziest yet for me. Before the competition began, I was hoping the theme would be “You are the Monster,” because I remembered the Serial Killer Roguelike hoax and thought that would be awesome

However, a few hours before the competition began I realized that that was a terrible idea because there was no way that I would be able to make something like that in 48 hours.

I took some time to google monsters before the theme was announced to stay prepared if that theme was picked. Skimming through the Wikipedia page on monsters, sirens caught my eye. Sirens felt like a good pick because there is an obvious game idea there –
you sing to make sailors crash their ships into rocks. As luck would have it, “You are the Monster” was picked as the theme, and I began brainstorming the design of my siren game.

I didn’t need to think too long about the design. One notable design I decided on was to have prerecorded siren songs instead of having the player sing into a microphone. This is because I don’t know how many players would have a microphone, and didn’t know what options are out there for libraries to work with mics. As I was exploring the design space I also realized that I wanted it to be similiar to a tower defense.

With this in mind, I began coding. The entire development was streamed on twitch.tv/miotatsu, but my mic is very quiet and I am soft spoken, so it is practically an audioless stream.

My initial plan for development tools was:

* The D programming language
* SFML2 for the media library
* Vim as my text editor
* Gimp for making graphics
* Audacity for music, vocals, sound effects, etc.
* Bfxr for sound effects

Development in the beginning went well – until I ran into a problem. When I pressed the left mouse button, SFML registered it as a mouse wheel moved event.

I believe it was because I have 2.0.4 but the derelict-sfml2 bindings are for 2.0.3. To deal with this, I ported my codebase to SDL2 which set me back a good 3 hours or so.

I truly felt like a monster writing some of the code.

That is the only comment in the entire 1.2K lines of code btw.

On Day 2 I decided to start recording audio, but this was a bit of a struggle to deal with as obs and pulseaudio kind of interfered. One reboot later and a bit of twiddling settings around and I was able to get my audio recorded.

Smooth sailing from here, right?

lol.gif

I wasn’t able to get any sound working with SDL2_Mixer. None. I don’t know if it has to do with pulse (I needed it for obs, normally I just use ALSA) or what.

Lo and behold, I found myself searching for another library to play audio. I ended up going with fmod, which I have never used before. Luckily it didn’t take me long to learn enough of the API to do what I wanted, and I was able to complete my entry on time.

Despite all the insanity coding this thing, I think it is the best Ludum Dare entry I’ve done to date.

Finally, I had to port the thing to Windows, but I was getting access violation errors.

Commenting out the line that does the fmod update in my game loop fixed the first crash. Why that fixed the crash, and why audio even works without that I have no idea. Then a single one of my sound effects was causing a crash. I moved where the sound effect is called and GUESS WHAT THAT WORKS BECAUSE REASONS.
I don’t even know, man.

Source: ludumdare.com archive

Found a bug?
Tell us on Discord