2014-06-16 20:03:05 +00:00
|
|
|
HallOfFamePC: ; 7405c (1d:405c)
|
2014-05-22 22:13:20 +00:00
|
|
|
callba AnimateHallOfFame
|
|
|
|
call ClearScreen
|
2015-07-03 19:37:53 +00:00
|
|
|
ld c, 100
|
2014-05-22 22:13:20 +00:00
|
|
|
call DelayFrames
|
|
|
|
call DisableLCD
|
2014-05-29 08:31:46 +00:00
|
|
|
ld hl, vFont
|
|
|
|
ld bc, $800 / 2
|
2015-07-15 02:46:52 +00:00
|
|
|
call ZeroMemory
|
2014-05-29 08:31:46 +00:00
|
|
|
ld hl, vChars2 + $600
|
|
|
|
ld bc, $200 / 2
|
2015-07-15 02:46:52 +00:00
|
|
|
call ZeroMemory
|
2014-05-29 08:31:46 +00:00
|
|
|
ld hl, vChars2 + $7e0
|
2014-05-22 22:13:20 +00:00
|
|
|
ld bc, $10
|
|
|
|
ld a, $ff
|
|
|
|
call FillMemory
|
2015-07-18 20:52:03 +00:00
|
|
|
coord hl, 0, 0
|
2015-07-14 05:21:03 +00:00
|
|
|
call FillFourRowsWithBlack
|
2015-07-18 20:52:03 +00:00
|
|
|
coord hl, 0, 14
|
2015-07-14 05:21:03 +00:00
|
|
|
call FillFourRowsWithBlack
|
2014-05-22 22:13:20 +00:00
|
|
|
ld a, $c0
|
2015-07-03 19:37:53 +00:00
|
|
|
ld [rBGP], a
|
2014-05-22 22:13:20 +00:00
|
|
|
call EnableLCD
|
|
|
|
ld a, $ff
|
|
|
|
call PlaySoundWaitForCurrent
|
|
|
|
ld c, BANK(Music_Credits)
|
|
|
|
ld a, MUSIC_CREDITS
|
|
|
|
call PlayMusic
|
2015-07-03 19:37:53 +00:00
|
|
|
ld c, 128
|
2014-05-22 22:13:20 +00:00
|
|
|
call DelayFrames
|
|
|
|
xor a
|
2015-07-19 21:01:08 +00:00
|
|
|
ld [wUnusedCD3D], a ; not read
|
2015-07-15 02:46:52 +00:00
|
|
|
ld [wNumCreditsMonsDisplayed], a
|
2014-05-22 22:13:20 +00:00
|
|
|
jp Credits
|
|
|
|
|
2015-07-15 02:46:52 +00:00
|
|
|
FadeInCreditsText: ; 740ba (1d:40ba)
|
2015-07-14 05:21:03 +00:00
|
|
|
ld hl, HoFGBPalettes
|
2015-07-15 02:46:52 +00:00
|
|
|
ld b, 4
|
2014-05-22 22:13:20 +00:00
|
|
|
.asm_740bf
|
|
|
|
ld a, [hli]
|
2015-07-03 19:37:53 +00:00
|
|
|
ld [rBGP], a
|
|
|
|
ld c, 5
|
2014-05-22 22:13:20 +00:00
|
|
|
call DelayFrames
|
|
|
|
dec b
|
|
|
|
jr nz, .asm_740bf
|
|
|
|
ret
|
|
|
|
|
|
|
|
DisplayCreditsMon: ; 740cb (1d:40cb)
|
|
|
|
xor a
|
|
|
|
ld [H_AUTOBGTRANSFERENABLED],a
|
|
|
|
call SaveScreenTilesToBuffer1
|
|
|
|
call FillMiddleOfScreenWithWhite
|
|
|
|
|
|
|
|
; display the next monster from CreditsMons
|
2015-07-15 02:46:52 +00:00
|
|
|
ld hl,wNumCreditsMonsDisplayed
|
2014-05-22 22:13:20 +00:00
|
|
|
ld c,[hl] ; how many monsters have we displayed so far?
|
|
|
|
inc [hl]
|
|
|
|
ld b,0
|
|
|
|
ld hl,CreditsMons
|
|
|
|
add hl,bc ; go that far in the list of monsters and get the next one
|
|
|
|
ld a,[hl]
|
2014-05-26 21:04:56 +00:00
|
|
|
ld [wcf91],a
|
|
|
|
ld [wd0b5],a
|
2015-07-18 20:52:03 +00:00
|
|
|
coord hl, 8, 6
|
2014-05-22 22:13:20 +00:00
|
|
|
call GetMonHeader
|
|
|
|
call LoadFrontSpriteByMonIndex
|
2014-05-29 08:31:46 +00:00
|
|
|
ld hl,vBGMap0 + $c
|
2015-07-24 21:39:45 +00:00
|
|
|
call CreditsCopyTileMapToVRAM
|
2014-05-22 22:13:20 +00:00
|
|
|
xor a
|
|
|
|
ld [H_AUTOBGTRANSFERENABLED],a
|
|
|
|
call LoadScreenTilesFromBuffer1
|
2014-05-29 08:31:46 +00:00
|
|
|
ld hl,vBGMap0
|
2015-07-24 21:39:45 +00:00
|
|
|
call CreditsCopyTileMapToVRAM
|
2014-05-22 22:13:20 +00:00
|
|
|
ld a,$A7
|
2015-07-15 02:46:52 +00:00
|
|
|
ld [rWX],a
|
2014-05-29 08:31:46 +00:00
|
|
|
ld hl,vBGMap1
|
2015-07-24 21:39:45 +00:00
|
|
|
call CreditsCopyTileMapToVRAM
|
2014-05-22 22:13:20 +00:00
|
|
|
call FillMiddleOfScreenWithWhite
|
2015-07-22 01:58:19 +00:00
|
|
|
ld a,%11111100 ; make the mon a black silhouette
|
2015-07-13 20:35:35 +00:00
|
|
|
ld [rBGP],a
|
2015-07-15 02:46:52 +00:00
|
|
|
|
|
|
|
; scroll the mon left by one tile 7 times
|
2014-05-22 22:13:20 +00:00
|
|
|
ld bc,7
|
2015-07-15 02:46:52 +00:00
|
|
|
.scrollLoop1
|
|
|
|
call ScrollCreditsMonLeft
|
2014-05-22 22:13:20 +00:00
|
|
|
dec c
|
2015-07-15 02:46:52 +00:00
|
|
|
jr nz,.scrollLoop1
|
|
|
|
|
|
|
|
; scroll the mon left by one tile 20 times
|
|
|
|
; This time, we have to move the window left too in order to hide the text that
|
2015-07-22 01:58:19 +00:00
|
|
|
; is wrapping around to the right side of the screen.
|
2015-07-15 02:46:52 +00:00
|
|
|
ld c,20
|
|
|
|
.scrollLoop2
|
|
|
|
call ScrollCreditsMonLeft
|
|
|
|
ld a,[rWX]
|
2014-05-22 22:13:20 +00:00
|
|
|
sub 8
|
2015-07-15 02:46:52 +00:00
|
|
|
ld [rWX],a
|
2014-05-22 22:13:20 +00:00
|
|
|
dec c
|
2015-07-15 02:46:52 +00:00
|
|
|
jr nz,.scrollLoop2
|
|
|
|
|
2014-05-22 22:13:20 +00:00
|
|
|
xor a
|
2014-09-23 22:02:03 +00:00
|
|
|
ld [hWY],a
|
2015-07-15 02:46:52 +00:00
|
|
|
ld a,%11000000
|
2015-07-13 20:35:35 +00:00
|
|
|
ld [rBGP],a
|
2014-05-22 22:13:20 +00:00
|
|
|
ret
|
|
|
|
|
|
|
|
INCLUDE "data/credit_mons.asm"
|
|
|
|
|
2015-07-15 02:46:52 +00:00
|
|
|
ScrollCreditsMonLeft: ; 74140 (1d:4140)
|
2014-05-22 22:13:20 +00:00
|
|
|
ld h, b
|
|
|
|
ld l, $20
|
2015-07-15 02:46:52 +00:00
|
|
|
call ScrollCreditsMonLeft_SetSCX
|
2014-05-22 22:13:20 +00:00
|
|
|
ld h, $0
|
|
|
|
ld l, $70
|
2015-07-15 02:46:52 +00:00
|
|
|
call ScrollCreditsMonLeft_SetSCX
|
2014-05-22 22:13:20 +00:00
|
|
|
ld a, b
|
|
|
|
add $8
|
|
|
|
ld b, a
|
|
|
|
ret
|
|
|
|
|
2015-07-15 02:46:52 +00:00
|
|
|
ScrollCreditsMonLeft_SetSCX: ; 74152 (1d:4152)
|
|
|
|
ld a, [rLY]
|
2014-05-22 22:13:20 +00:00
|
|
|
cp l
|
2015-07-15 02:46:52 +00:00
|
|
|
jr nz, ScrollCreditsMonLeft_SetSCX
|
2014-05-22 22:13:20 +00:00
|
|
|
ld a, h
|
2015-07-03 19:37:53 +00:00
|
|
|
ld [rSCX], a
|
2015-07-15 02:46:52 +00:00
|
|
|
.loop
|
|
|
|
ld a, [rLY]
|
2014-05-22 22:13:20 +00:00
|
|
|
cp h
|
2015-07-15 02:46:52 +00:00
|
|
|
jr z, .loop
|
2014-05-22 22:13:20 +00:00
|
|
|
ret
|
|
|
|
|
2015-07-14 05:21:03 +00:00
|
|
|
HoFGBPalettes: ; 74160 (1d:4160)
|
|
|
|
db %11000000
|
|
|
|
db %11010000
|
|
|
|
db %11100000
|
|
|
|
db %11110000
|
2014-05-22 22:13:20 +00:00
|
|
|
|
2015-07-24 21:39:45 +00:00
|
|
|
CreditsCopyTileMapToVRAM: ; 74164 (1d:4164)
|
2014-05-22 22:13:20 +00:00
|
|
|
ld a, l
|
2015-07-03 19:37:53 +00:00
|
|
|
ld [H_AUTOBGTRANSFERDEST], a
|
2014-05-22 22:13:20 +00:00
|
|
|
ld a, h
|
2015-07-12 23:37:06 +00:00
|
|
|
ld [H_AUTOBGTRANSFERDEST + 1], a
|
2015-07-24 21:39:45 +00:00
|
|
|
ld a, 1
|
2015-07-03 19:37:53 +00:00
|
|
|
ld [H_AUTOBGTRANSFERENABLED], a
|
2014-05-22 22:13:20 +00:00
|
|
|
jp Delay3
|
|
|
|
|
2015-07-15 02:46:52 +00:00
|
|
|
ZeroMemory: ; 74171 (1d:4171)
|
|
|
|
; zero bc bytes at hl
|
|
|
|
ld [hl], 0
|
2014-05-22 22:13:20 +00:00
|
|
|
inc hl
|
|
|
|
inc hl
|
|
|
|
dec bc
|
|
|
|
ld a, b
|
|
|
|
or c
|
2015-07-15 02:46:52 +00:00
|
|
|
jr nz, ZeroMemory
|
2014-05-22 22:13:20 +00:00
|
|
|
ret
|
|
|
|
|
2015-07-14 05:21:03 +00:00
|
|
|
FillFourRowsWithBlack: ; 7417b (1d:417b)
|
|
|
|
ld bc, SCREEN_WIDTH * 4
|
2014-05-22 22:13:20 +00:00
|
|
|
ld a, $7e
|
|
|
|
jp FillMemory
|
|
|
|
|
|
|
|
FillMiddleOfScreenWithWhite: ; 74183 (1d:4183)
|
2015-07-18 20:52:03 +00:00
|
|
|
coord hl, 0, 4
|
2015-07-14 05:21:03 +00:00
|
|
|
ld bc, SCREEN_WIDTH * 10
|
2015-08-05 21:20:29 +00:00
|
|
|
ld a, " "
|
2014-05-22 22:13:20 +00:00
|
|
|
jp FillMemory
|
|
|
|
|
|
|
|
Credits: ; 7418e (1d:418e)
|
2015-07-03 19:37:53 +00:00
|
|
|
ld de, CreditsOrder
|
2014-05-22 22:13:20 +00:00
|
|
|
push de
|
2015-07-15 02:46:52 +00:00
|
|
|
.nextCreditsScreen
|
2014-05-22 22:13:20 +00:00
|
|
|
pop de
|
2015-07-18 20:52:03 +00:00
|
|
|
coord hl, 9, 6
|
2014-05-22 22:13:20 +00:00
|
|
|
push hl
|
|
|
|
call FillMiddleOfScreenWithWhite
|
|
|
|
pop hl
|
2015-07-15 02:46:52 +00:00
|
|
|
.nextCreditsCommand
|
2014-05-22 22:13:20 +00:00
|
|
|
ld a, [de]
|
|
|
|
inc de
|
|
|
|
push de
|
|
|
|
cp $ff
|
2015-07-15 02:46:52 +00:00
|
|
|
jr z, .fadeInTextAndShowMon
|
2014-05-22 22:13:20 +00:00
|
|
|
cp $fe
|
2015-07-15 02:46:52 +00:00
|
|
|
jr z, .showTextAndShowMon
|
2014-05-22 22:13:20 +00:00
|
|
|
cp $fd
|
2015-07-15 02:46:52 +00:00
|
|
|
jr z, .fadeInText
|
2014-05-22 22:13:20 +00:00
|
|
|
cp $fc
|
2015-07-15 02:46:52 +00:00
|
|
|
jr z, .showText
|
2014-05-22 22:13:20 +00:00
|
|
|
cp $fb
|
2015-07-15 02:46:52 +00:00
|
|
|
jr z, .showCopyrightText
|
2014-05-22 22:13:20 +00:00
|
|
|
cp $fa
|
|
|
|
jr z, .showTheEnd
|
|
|
|
push hl
|
|
|
|
push hl
|
2015-07-03 19:37:53 +00:00
|
|
|
ld hl, CreditsTextPointers
|
2014-05-22 22:13:20 +00:00
|
|
|
add a
|
|
|
|
ld c, a
|
2015-07-15 02:46:52 +00:00
|
|
|
ld b, 0
|
2014-05-22 22:13:20 +00:00
|
|
|
add hl, bc
|
|
|
|
ld e, [hl]
|
|
|
|
inc hl
|
|
|
|
ld d, [hl]
|
|
|
|
ld a, [de]
|
|
|
|
inc de
|
|
|
|
ld c, a
|
|
|
|
ld b, $ff
|
|
|
|
pop hl
|
|
|
|
add hl, bc
|
|
|
|
call PlaceString
|
|
|
|
pop hl
|
2015-07-14 07:16:19 +00:00
|
|
|
ld bc, SCREEN_WIDTH * 2
|
2014-05-22 22:13:20 +00:00
|
|
|
add hl, bc
|
|
|
|
pop de
|
2015-07-15 02:46:52 +00:00
|
|
|
jr .nextCreditsCommand
|
|
|
|
.fadeInTextAndShowMon
|
|
|
|
call FadeInCreditsText
|
2015-07-03 19:37:53 +00:00
|
|
|
ld c, 90
|
2015-07-15 02:46:52 +00:00
|
|
|
jr .next1
|
|
|
|
.showTextAndShowMon
|
2015-07-03 19:37:53 +00:00
|
|
|
ld c, 110
|
2015-07-15 02:46:52 +00:00
|
|
|
.next1
|
2014-05-22 22:13:20 +00:00
|
|
|
call DelayFrames
|
|
|
|
call DisplayCreditsMon
|
2015-07-15 02:46:52 +00:00
|
|
|
jr .nextCreditsScreen
|
|
|
|
.fadeInText
|
|
|
|
call FadeInCreditsText
|
2015-07-03 19:37:53 +00:00
|
|
|
ld c, 120
|
2015-07-15 02:46:52 +00:00
|
|
|
jr .next2
|
|
|
|
.showText
|
2015-07-03 19:37:53 +00:00
|
|
|
ld c, 140
|
2015-07-15 02:46:52 +00:00
|
|
|
.next2
|
2014-05-22 22:13:20 +00:00
|
|
|
call DelayFrames
|
2015-07-15 02:46:52 +00:00
|
|
|
jr .nextCreditsScreen
|
|
|
|
.showCopyrightText
|
2014-05-22 22:13:20 +00:00
|
|
|
push de
|
|
|
|
callba LoadCopyrightTiles
|
|
|
|
pop de
|
|
|
|
pop de
|
2015-07-15 02:46:52 +00:00
|
|
|
jr .nextCreditsCommand
|
2014-05-22 22:13:20 +00:00
|
|
|
.showTheEnd
|
2015-07-03 19:37:53 +00:00
|
|
|
ld c, 16
|
2014-05-22 22:13:20 +00:00
|
|
|
call DelayFrames
|
|
|
|
call FillMiddleOfScreenWithWhite
|
|
|
|
pop de
|
|
|
|
ld de, TheEndGfx
|
2014-05-29 08:31:46 +00:00
|
|
|
ld hl, vChars2 + $600
|
2015-08-10 04:56:20 +00:00
|
|
|
lb bc, BANK(TheEndGfx), (TheEndGfxEnd - TheEndGfx) / $10
|
2014-05-22 22:13:20 +00:00
|
|
|
call CopyVideoData
|
2015-07-18 20:52:03 +00:00
|
|
|
coord hl, 4, 8
|
2014-05-31 14:35:46 +00:00
|
|
|
ld de, TheEndTextString
|
2014-05-22 22:13:20 +00:00
|
|
|
call PlaceString
|
2015-07-18 20:52:03 +00:00
|
|
|
coord hl, 4, 9
|
2014-05-22 22:13:20 +00:00
|
|
|
inc de
|
|
|
|
call PlaceString
|
2015-07-15 02:46:52 +00:00
|
|
|
jp FadeInCreditsText
|
2014-05-22 22:13:20 +00:00
|
|
|
|
2014-05-31 14:35:46 +00:00
|
|
|
TheEndTextString: ; 74229 (1d:4229)
|
|
|
|
; "T H E E N D"
|
2014-05-22 22:13:20 +00:00
|
|
|
db $60," ",$62," ",$64," ",$64," ",$66," ",$68,"@"
|
|
|
|
db $61," ",$63," ",$65," ",$65," ",$67," ",$69,"@"
|
|
|
|
|
|
|
|
INCLUDE "data/credits_order.asm"
|
|
|
|
|
|
|
|
INCLUDE "text/credits_text.asm"
|
|
|
|
|
2015-07-14 05:21:03 +00:00
|
|
|
TheEndGfx: ; 7473e (1d:473e) (7473f on blue)
|
2014-05-30 08:30:10 +00:00
|
|
|
INCBIN "gfx/theend.interleave.2bpp"
|
2015-08-10 04:56:20 +00:00
|
|
|
TheEndGfxEnd:
|