
I decided to poke around this old project I'd originally written in DirectX when I was a lot younger. It's sort of like Mad Bomber with Mario-style mechanics, where the hero has to dash around the stage collecting falling orbs tossed by the enemy. It's actually pretty tough and can get frustrating fast.
Porting it over wasn't too bad because I used my old game library, MasterX. I just redefined the missing constants and macros, stripped out all the DirectX bits, and replaced them with SDL2 API calls. Then I included that header file in the existing code, tidied things up a bit, and after a couple tries and warning fixes, it finally compiled.
Once that was done, I tweaked the code to build a fresh WebAssembly version for my website's online arcade. It all came together pretty smoothly in the end. I just had to change the file paths in the program to match the preload file for WebAssembly.