The Paper Mario music file format, BGM (background music), uses a bytecode similar to, but more powerful than, MIDI. It includes support for subroutines and its delta time system works in a different way to MIDI. You can play about with BGM using my BGM editing tool, Mamar: mamar.nanain.town