Files
mazegame/projects
jurjen.ladeniusandClaude Opus 4.8 9faff1cfba Fix music tempo, note-on-switch, and title scroll shift
Three follow-up fixes to the per-screen music:

- Decode music in the H_TIMI VBlank interrupt (MusicVBlank) instead of
  once per Halt() in the game loops. The heavy per-step VDP work in
  ScrollDraw could overrun a VBlank, dropping the decode rate so the
  music slowed only while moving; the ISR keeps tempo steady regardless.
  The playing track is mapped into the unused bank-3 window (0xA000) and
  left there for the screen, so the ISR reads it with no bank switching
  and never races the main code's bank-2 tile/sprite swaps. PlayTrack()
  switches tracks under DI/EI. The game loops revert to plain Halt()s.

- PlayTrack() mutes the OPLL (key-off all 9 channels) before starting the
  next track, silencing the note that lingered across screen changes.

- TitleScreen()/ShowHints() zero the hardware scroll offset before drawing
  their absolute-coord images. Gameplay rests at g_BaseX/g_BaseY in
  {0,64,128,192}; without the reset the returning title/hints screen
  appeared horizontally shifted (only after finishing on a non-zero base).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-03 21:15:55 +02:00
..