diff options
author | mid-kid <esteve.varela@gmail.com> | 2018-11-21 12:12:22 +0100 |
---|---|---|
committer | mid-kid <esteve.varela@gmail.com> | 2018-11-21 12:12:22 +0100 |
commit | 725cee7371f1b1862225e940e5c7271dc9444a1c (patch) | |
tree | d66d7b32b08cfe474faca7b0f7a5b51b9d8515b8 /audio/engine.asm | |
parent | 4e3ed078f9c8c486015d5c00e8d158671d3f740d (diff) |
Define first_music_cmd
This replaces the uses of $d0 in the audio engine with proper constants.
Diffstat (limited to 'audio/engine.asm')
-rw-r--r-- | audio/engine.asm | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/audio/engine.asm b/audio/engine.asm index 62ba0e48c..551f1e0aa 100644 --- a/audio/engine.asm +++ b/audio/engine.asm @@ -1136,9 +1136,9 @@ ReadNoiseSample: ParseMusic: ; parses until a note is read or the song is ended call GetMusicByte ; store next byte in a - cp endchannel_cmd ; is the song over? + cp endchannel_cmd jr z, .endchannel - cp $d0 ; is it a note? + cp first_music_cmd jr c, .readnote ; then it's a command .readcommand @@ -1350,7 +1350,7 @@ ParseMusicCommand: ; reload command ld a, [wCurMusicByte] ; get command # - sub $d0 ; first command + sub first_music_cmd ld e, a ld d, 0 ; seek command pointer |