diff options
Diffstat (limited to 'macros/audio_macros.asm')
-rwxr-xr-x | macros/audio_macros.asm | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/macros/audio_macros.asm b/macros/audio_macros.asm index 8195a04d..6d7b45c8 100755 --- a/macros/audio_macros.asm +++ b/macros/audio_macros.asm @@ -40,17 +40,26 @@ pitchenvelope: MACRO ENDC ENDM +;format: duty, volume, volume change, pitch squarenote: MACRO db $20 | \1 - db \2 - db \3 - db \4 + IF \3 < 0 + db (\2 << 4) | (%1000 | (\3 * -1)) + ELSE + db (\2 << 4) | \3 + ENDC + dw \4 ENDM +;format: duty, volume, volume change, pitch noisenote: MACRO db $20 | \1 - db \2 - db \3 + IF \3 < 0 + db (\2 << 4) | (%1000 | (\3 * -1)) + ELSE + db (\2 << 4) | \3 + ENDC + db \4 ENDM ;format: pitch length (in 16ths) |