I thought I'd been killed because right at that moment my boss walked in and I had to minimize the game
That's hilarious

I'm interested in how you store the levels and spawn information.
Normally the levels in side-scrollers are represented with grid maps. I used such maps in my Pitfall entry. But, for Squarius I took a much simplier approach. There are 8 pieces that can be put together in different sequences to form a level. Pieces include a wave attack, a triplet attack, a wall with a hole in it, the explosive barrier, the shrinkers, the cave, a boss, etc. Each piece is affected by the level number (e.g. bosses become more difficult) and a random number generator (e.g. the hole in the wall will appear at different positions).
Essentially, when the stage begins, a clock is started. The sequence for each stage looks something like: at time T1, manifest wave attack, at time T2, manifest triplet attack, etc. Originally, this was encoded with 2 arrays of integers. But, to save bytes, it was ultimately encoded more compactly.