mirror of
https://github.com/thornAvery/kep-hack.git
synced 2026-02-06 15:45:24 +13:00
Fix pokeflute in battle sfx
and other small improvements
This commit is contained in:
parent
5f87413b23
commit
c1278c478e
28 changed files with 108 additions and 131 deletions
|
|
@ -61,14 +61,16 @@ PlayDefaultMusicCommon::
|
|||
.next4
|
||||
ld a, c
|
||||
ld [wAudioFadeOutControl], a
|
||||
and a
|
||||
jr nz, .next5
|
||||
inc a
|
||||
.next5
|
||||
ld [wMusicFade], a
|
||||
|
||||
ld a, b
|
||||
ld [wLastMusicSoundID], a
|
||||
ld [wNewSoundID], a
|
||||
|
||||
ld [wMusicFadeID], a
|
||||
ld a, 8
|
||||
ld [wMusicFade], a
|
||||
;call FadeMusic ; called in updatemusic
|
||||
ret
|
||||
|
||||
;UpdateMusic6Times::
|
||||
|
|
|
|||
|
|
@ -760,6 +760,7 @@ HandleBlackOut::
|
|||
call GBFadeOutToBlack
|
||||
ld a, $08
|
||||
call StopMusic
|
||||
call WaitForSongToFinish
|
||||
ld hl, wd72e
|
||||
res 5, [hl]
|
||||
ld a, BANK(ResetStatusAndHalveMoneyOnBlackout) ; also BANK(SpecialWarpIn) and BANK(SpecialEnterMap)
|
||||
|
|
@ -1256,17 +1257,16 @@ CollisionCheckOnLand::
|
|||
call CheckTilePassable
|
||||
jr nc, .noCollision
|
||||
.collision
|
||||
;ld a, [wChannelSoundIDs + Ch5]
|
||||
;cp SFX_COLLISION ; check if collision sound is already playing
|
||||
;jr z, .setCarry
|
||||
|
||||
; curSFX is not cleared for some reason.
|
||||
; ld a, [wChannelSoundIDs + Ch5]
|
||||
; cp SFX_COLLISION ; check if collision sound is already playing
|
||||
; jr z, .setCarry
|
||||
|
||||
; ch5 on?
|
||||
ld hl, wChannel5 + wChannel1Flags1 - wChannel1 ; + CHANNEL_FLAGS1
|
||||
bit 0, [hl]
|
||||
|
||||
jr nz, .setCarry
|
||||
|
||||
ld a, SFX_COLLISION
|
||||
call PlaySound ; play collision sound (if it's not already playing)
|
||||
.setCarry
|
||||
|
|
@ -1945,17 +1945,16 @@ CollisionCheckOnWater::
|
|||
jr z, .stopSurfing ; stop surfing if the tile is passable
|
||||
jr .loop
|
||||
.collision
|
||||
;ld a, [wChannelSoundIDs + Ch5]
|
||||
;cp SFX_COLLISION ; check if collision sound is already playing
|
||||
;jr z, .setCarry
|
||||
|
||||
; curSFX is not cleared for some reason.
|
||||
; ld a, [wChannelSoundIDs + Ch5]
|
||||
; cp SFX_COLLISION ; check if collision sound is already playing
|
||||
; jr z, .setCarry
|
||||
|
||||
; ch5 on?
|
||||
ld hl, wChannel5 + wChannel1Flags1 - wChannel1 ; + CHANNEL_FLAGS1
|
||||
bit 0, [hl]
|
||||
|
||||
jr nz, .setCarry
|
||||
|
||||
ld a, SFX_COLLISION
|
||||
call PlaySound ; play collision sound (if it's not already playing)
|
||||
.setCarry
|
||||
|
|
@ -2307,6 +2306,10 @@ LoadMapHeader::
|
|||
ld a, [hli]
|
||||
ld [wMapMusicSoundID], a ; music 1
|
||||
ld a, [hl]
|
||||
|
||||
; give vanilla red a fair shot at running our savs
|
||||
ld a, BANK("Audio Engine 1")
|
||||
|
||||
ld [wMapMusicROMBank], a ; music 2
|
||||
pop af
|
||||
ldh [hLoadedROMBank], a
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue