1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
|
; Brief custom boot splash shown on the fastboot path. Loads a real 2bpp
; graphic (gfx/slop/intro.png -> tiles+tilemap via rgbgfx) into VRAM and holds
; it, then MainMenu's autoload continues into the game.
DEF SLOP_INTRO_NUM_TILES EQU 164
SECTION "Slop Intro", ROMX
SlopSplash::
call ClearScreen
; load the custom tiles into the 0x8000 block (unsigned addressing)
ld hl, vChars0
ld de, SlopIntroTiles
ld b, BANK(SlopIntroTiles)
ld c, SLOP_INTRO_NUM_TILES
call CopyVideoData
ldh a, [rLCDC]
or LCDC_BLOCK01 ; BG/window tile data at 0x8000
ldh [rLCDC], a
; blit the 20x18 tilemap through wTileMap so the 20->32 row stride is handled.
; Use the BG map (vBGMap0): the map load on continue overwrites it, so nothing
; is left corrupting the overworld (unlike the window map vBGMap1).
ld hl, SlopIntroTilemap
ld de, wTileMap
ld bc, SlopIntroTilemapEnd - SlopIntroTilemap
call CopyData
ld b, HIGH(vBGMap0)
call CopyScreenTileBufferToVRAM
xor a
ldh [hSCX], a
ldh [hSCY], a
ld a, LCDC_ON | LCDC_BLOCK01 | LCDC_BG_9800 | LCDC_BG_ON ; BG only, tiles @0x8000
ldh [rLCDC], a
call GBPalNormal
ld c, 120 ; ~2 seconds
call DelayFrames
call GBFadeOutToWhite
; restore the default LCDC so the overworld renders correctly: signed tile data
; (BLOCK21) for the BG *and* OBJ back on so entity sprites reappear
ld a, LCDC_DEFAULT
ldh [rLCDC], a
ret
SlopIntroTiles:
INCBIN "gfx/slop/intro.2bpp"
SlopIntroTilesEnd:
SlopIntroTilemap:
INCBIN "gfx/slop/intro.tilemap"
SlopIntroTilemapEnd:
|