summaryrefslogtreecommitdiff
path: root/audio/engine.asm
diff options
context:
space:
mode:
authorRangi <remy.oukaour+rangi42@gmail.com>2021-03-22 16:41:17 -0400
committerRangi <remy.oukaour+rangi42@gmail.com>2021-03-22 16:41:17 -0400
commitdbe2360ecd3eb11fd144168427e1323f5e1b2ec2 (patch)
treed571d2f064c176a36951d3470d19053692f9e8eb /audio/engine.asm
parent8daf8fe19c9e356df34ca8da3423618999d4405a (diff)
Miscellaneous cleanup
Diffstat (limited to 'audio/engine.asm')
-rw-r--r--audio/engine.asm12
1 files changed, 10 insertions, 2 deletions
diff --git a/audio/engine.asm b/audio/engine.asm
index 9149223eb..fa3a08297 100644
--- a/audio/engine.asm
+++ b/audio/engine.asm
@@ -223,16 +223,21 @@ UpdateChannels:
jp hl
.ChannelFunctions:
+ table_width 2, UpdateChannels.ChannelFunctions
+; music channels
dw .Channel1
dw .Channel2
dw .Channel3
dw .Channel4
-; sfx ch ptrs are identical to music chs
-; ..except 5
+ assert_table_length NUM_MUSIC_CHANS
+; sfx channels
+; identical to music channels, except .Channel5 is not disabled by the low-HP danger sound
+; (instead, PlayDanger does not play the danger sound if sfx is playing)
dw .Channel5
dw .Channel6
dw .Channel7
dw .Channel8
+ assert_table_length NUM_CHANNELS
.Channel1:
ld a, [wLowHealthAlarm]
@@ -2777,16 +2782,19 @@ StereoTracks:
db $11, $22, $44, $88
ChannelPointers:
+ table_width 2, ChannelPointers
; music channels
dw wChannel1
dw wChannel2
dw wChannel3
dw wChannel4
+ assert_table_length NUM_MUSIC_CHANS
; sfx channels
dw wChannel5
dw wChannel6
dw wChannel7
dw wChannel8
+ assert_table_length NUM_CHANNELS
ClearChannels::
; runs ClearChannel for all 4 channels