Uploaded January 2018 | Updated September 2026, 3 weeks ago
I thought this would be a simple minihack. I was wrong.
Getting the sound driver to time itself with the YM2612's Timer A was bad enough, but then I needed to figure out how to hook it into the player's movements. At first I tried to just use the player object's inertia value, but that only worked when they were on the ground: the tempo would never change while they're in the air. I tried calculating the difference in the player's x_pos instead, and using that, but that meant moving vertically wouldn't affect the tempo at all, so flying off a ramp and into the air would ironically make the music slower.
Eventually, I wound up implementing an entire distance formula, which was a mess... You ever try calculating a square root on a 68000 in raw assembly? Anyhow, eventually I managed to replace it all with a look-up table, so the old wacky maths is gone now.
Download link:
mediafire.com/?2v63npy7rudhf2e
sonicresearch.org
I thought this would be a simple minihack. I was wrong.
Getting the sound driver to time itself with the YM2612's Timer A was bad enough, but then I needed to figure out how to hook it into the player's movements. At first I tried to just use the player object's inertia value, but that only worked when they were on the ground: the tempo would never change while they're in the air. I tried calculating the difference in the player's x_pos instead, and using that, but that meant moving vertically wouldn't affect the tempo at all, so flying off a ramp and into the air would ironically make the music slower.
Eventually, I wound up implementing an entire distance formula, which was a mess... You ever try calculating a square root on a 68000 in raw assembly? Anyhow, eventually I managed to replace it all with a look-up table, so the old wacky maths is gone now.
Download link:
mediafire.com/?2v63npy7rudhf2e
sonicresearch.org










