Fix oob bug and improve UI

This commit is contained in:
Randy Thiemann 2023-11-01 20:04:54 +01:00
parent 5121d1a4c5
commit d38903247e
18 changed files with 3888 additions and 3691 deletions

View File

@ -138,6 +138,7 @@ Thanks for playtesting and debugging go to:
- CreeperCraftYT™ - CreeperCraftYT™
- AntonErgo - AntonErgo
- Lindtobias - Lindtobias
- \_Zaphod77\_
## License ## License

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

View File

@ -32,9 +32,10 @@ DEF DELAY_STATE_PRE_ARE EQU 4
SECTION "Field Variables", WRAM0 SECTION "Field Variables", WRAM0
wField:: ds (10*24) wField:: ds (10*24)
wBackupField:: ds (10*24) wBackupField:: ds (10*24)
wPreShadowField:: ds (14*2)
wShadowField:: ds (14*26) wShadowField:: ds (14*26)
wWideField:: ds (5*10) wWideField:: ds (5*11)
wWideBlittedField:: ds (20*10) wWideBlittedField:: ds (22*10)
wDelayState: ds 1 wDelayState: ds 1
@ -73,7 +74,7 @@ BlitField::
jp z, GBCBlitField jp z, GBCBlitField
; What to copy ; What to copy
ld de, wField + 40 ld de, wField + 30
; Where to put it ; Where to put it
ld hl, FIELD_TOP_LEFT ld hl, FIELD_TOP_LEFT
; How much to increment hl after each row ; How much to increment hl after each row
@ -95,13 +96,13 @@ BlitField::
jr nz, .waitendvbloop jr nz, .waitendvbloop
; The last 6 rows need some care. ; The last 6 rows need some care.
REPT 6 REPT 7
; Wait until start of drawing, then insert 35 nops. ; Wait until start of drawing, then insert 35 nops.
: ldh a, [rSTAT] : ldh a, [rSTAT]
and a, 3 and a, 3
cp a, 3 cp a, 3
jr nz, :- jr nz, :-
REPT 35 REPT 38
nop nop
ENDR ENDR
@ -130,7 +131,7 @@ BigBlitField::
jp z, GBCBlitField jp z, GBCBlitField
; What to copy ; What to copy
ld de, wWideBlittedField ld de, wWideBlittedField+10
; Where to put it ; Where to put it
ld hl, FIELD_TOP_LEFT ld hl, FIELD_TOP_LEFT
; How much to increment hl after each row ; How much to increment hl after each row
@ -152,13 +153,13 @@ BigBlitField::
jr nz, .waitendvbloop jr nz, .waitendvbloop
; The last 6 rows need some care. ; The last 6 rows need some care.
REPT 6 REPT 7
; Wait until start of drawing, then insert 35 nops. ; Wait until start of drawing, then insert 35 nops.
: ldh a, [rSTAT] : ldh a, [rSTAT]
and a, 3 and a, 3
cp a, 3 cp a, 3
jr nz, :- jr nz, :-
REPT 35 REPT 38
nop nop
ENDR ENDR
@ -197,6 +198,10 @@ FieldInit::
ld bc, 14*26 ld bc, 14*26
ld d, $FF ld d, $FF
jp UnsafeMemSet jp UnsafeMemSet
ld hl, wPreShadowField
ld bc, 14*2
ld d, $FF
jp UnsafeMemSet
; Fills the field with the empty tile. ; Fills the field with the empty tile.
@ -892,8 +897,6 @@ FieldProcess::
call FromShadowField call FromShadowField
; Cleanup from last frame. ; Cleanup from last frame.
ldh a, [hCurrentPieceX]
ldh [hWantX], a
ldh a, [hCurrentPieceRotationState] ldh a, [hCurrentPieceRotationState]
ldh [hWantRotation], a ldh [hWantRotation], a
@ -1028,7 +1031,7 @@ FieldProcess::
cp a, 1 cp a, 1
jp z, .maybetgm3rot jp z, .maybetgm3rot
cp a, 5 cp a, 5
jr z, .maybetgm3rot jp z, .maybetgm3rot
cp a, 9 cp a, 9
jr z, .maybetgm3rot jr z, .maybetgm3rot
@ -1075,6 +1078,8 @@ FieldProcess::
ldh a, [hCurrentPieceY] ldh a, [hCurrentPieceY]
ld b, a ld b, a
ldh a, [hCurrentPieceX] ldh a, [hCurrentPieceX]
cp a, 0
jr z, .maybetgm3rot
dec a dec a
call XYToSFieldPtr call XYToSFieldPtr
ld d, h ld d, h
@ -1315,22 +1320,19 @@ FieldProcess::
; HANDLE MOVEMENT ; HANDLE MOVEMENT
; Do we want to move left? ; Do we want to move left?
.norot .norot
ldh a, [hCurrentPieceX]
ldh [hWantX], a
.wantleft .wantleft
ldh a, [hCurrentPieceX]
cp a, 0
jr z, .wantright
ldh a, [hLeftState] ; Check if held for 1 frame. If so we move. ldh a, [hLeftState] ; Check if held for 1 frame. If so we move.
cp a, 1 cp a, 1
jr z, .doleft jr z, .doleft
cp a, 0 ; We never want to move if the button wasn't held. cp a, 0 ; We never want to move if the button wasn't held.
jr z, .wantright jr z, .wantright
ld b, a ld b, a
ldh a, [hCurrentIntegerGravity]
cp a, 20 ; No increased DAS at 20G.
jr z, .checkdasleft
ldh a, [hGrounded] ; If we're grounded, assume some urgency in getting DAS charged, charge at twice the rate.
cp a, $FF
jr nz, .checkdasleft
inc b
ld a, b
ldh [hLeftState], a
.checkdasleft .checkdasleft
ldh a, [hCurrentDAS] ldh a, [hCurrentDAS]
ld c, a ld c, a
@ -1351,15 +1353,6 @@ FieldProcess::
cp a, 0 ; We never want to move if the button wasn't held. cp a, 0 ; We never want to move if the button wasn't held.
jr z, .donemanipulating jr z, .donemanipulating
ld b, a ld b, a
ldh a, [hCurrentIntegerGravity]
cp a, 20 ; No increased DAS at 20G.
jr z, .checkdasright
ldh a, [hGrounded] ; If we're grounded, assume some urgency in getting DAS charged, charge at twice the rate.
cp a, $FF
jr nz, .checkdasright
inc b
ld a, b
ldh [hRightState], a
.checkdasright .checkdasright
ldh a, [hCurrentDAS] ldh a, [hCurrentDAS]
ld c, a ld c, a
@ -1851,7 +1844,23 @@ GetTileShade:
; This is called every frame after a piece has been locked until the delay state ends. ; This is called every frame after a piece has been locked until the delay state ends.
; Lines are cleared, levels and score are awarded, and ARE time is waited out. ; Lines are cleared, levels and score are awarded, and ARE time is waited out.
FieldDelay:: FieldDelay::
; In delay state, DAS increments double speed.
.incl
ldh a, [hLeftState]
cp a, 0
jr z, .incr
inc a
ldh [hLeftState], a
.incr
ldh a, [hRightState]
cp a, 0
jr z, .noinc
inc a
ldh [hRightState], a
; Switch on the delay state. ; Switch on the delay state.
.noinc
ld a, [wDelayState] ld a, [wDelayState]
cp DELAY_STATE_DETERMINE_DELAY cp DELAY_STATE_DETERMINE_DELAY
jr z, .determine jr z, .determine
@ -2211,7 +2220,7 @@ ClearLines:
ld de, 0 ld de, 0
DEF row = 23 DEF row = 23
REPT 23 REPT 24
; Check if the row begins with a clearing tile. ; Check if the row begins with a clearing tile.
ld hl, wField+(row*10) ld hl, wField+(row*10)
ld a, [hl] ld a, [hl]
@ -2304,7 +2313,7 @@ BigFieldInit::
ld d, TILE_BLANK ld d, TILE_BLANK
call UnsafeMemSet call UnsafeMemSet
ld hl, wWideBlittedField ld hl, wWideBlittedField
ld bc, 10*20 ld bc, 10*22
ld d, TILE_BLANK ld d, TILE_BLANK
call UnsafeMemSet call UnsafeMemSet
ld hl, wShadowField ld hl, wShadowField
@ -3013,8 +3022,6 @@ BigFieldProcess::
call BigFromShadowField call BigFromShadowField
; Cleanup from last frame. ; Cleanup from last frame.
ldh a, [hCurrentPieceX]
ldh [hWantX], a
ldh a, [hCurrentPieceRotationState] ldh a, [hCurrentPieceRotationState]
ldh [hWantRotation], a ldh [hWantRotation], a
@ -3149,7 +3156,7 @@ BigFieldProcess::
cp a, 1 cp a, 1
jp z, .maybetgm3rot jp z, .maybetgm3rot
cp a, 5 cp a, 5
jr z, .maybetgm3rot jp z, .maybetgm3rot
cp a, 9 cp a, 9
jr z, .maybetgm3rot jr z, .maybetgm3rot
@ -3196,6 +3203,8 @@ BigFieldProcess::
ldh a, [hCurrentPieceY] ldh a, [hCurrentPieceY]
ld b, a ld b, a
ldh a, [hCurrentPieceX] ldh a, [hCurrentPieceX]
cp a, 0
jr z, .maybetgm3rot
dec a dec a
call BigXYToSFieldPtr call BigXYToSFieldPtr
ld d, h ld d, h
@ -3435,22 +3444,19 @@ BigFieldProcess::
; HANDLE MOVEMENT ; HANDLE MOVEMENT
; Do we want to move left? ; Do we want to move left?
.norot .norot
ldh a, [hCurrentPieceX]
ldh [hWantX], a
.wantleft .wantleft
ldh a, [hCurrentPieceX]
cp a, 0
jr z, .wantright
ldh a, [hLeftState] ; Check if held for 1 frame. If so we move. ldh a, [hLeftState] ; Check if held for 1 frame. If so we move.
cp a, 1 cp a, 1
jr z, .doleft jr z, .doleft
cp a, 0 ; We never want to move if the button wasn't held. cp a, 0 ; We never want to move if the button wasn't held.
jr z, .wantright jr z, .wantright
ld b, a ld b, a
ldh a, [hCurrentIntegerGravity]
cp a, 20 ; No increased DAS at 20G.
jr z, .checkdasleft
ldh a, [hGrounded] ; If we're grounded, assume some urgency in getting DAS charged, charge at twice the rate.
cp a, $FF
jr nz, .checkdasleft
inc b
ld a, b
ldh [hLeftState], a
.checkdasleft .checkdasleft
ldh a, [hCurrentDAS] ldh a, [hCurrentDAS]
ld c, a ld c, a
@ -3471,15 +3477,6 @@ BigFieldProcess::
cp a, 0 ; We never want to move if the button wasn't held. cp a, 0 ; We never want to move if the button wasn't held.
jr z, .donemanipulating jr z, .donemanipulating
ld b, a ld b, a
ldh a, [hCurrentIntegerGravity]
cp a, 20 ; No increased DAS at 20G.
jr z, .checkdasright
ldh a, [hGrounded] ; If we're grounded, assume some urgency in getting DAS charged, charge at twice the rate.
cp a, $FF
jr nz, .checkdasright
inc b
ld a, b
ldh [hRightState], a
.checkdasright .checkdasright
ldh a, [hCurrentDAS] ldh a, [hCurrentDAS]
ld c, a ld c, a
@ -3972,7 +3969,23 @@ BigGetTileShade:
; This is called every frame after a piece has been locked until the delay state ends. ; This is called every frame after a piece has been locked until the delay state ends.
; Lines are cleared, levels and score are awarded, and ARE time is waited out. ; Lines are cleared, levels and score are awarded, and ARE time is waited out.
BigFieldDelay:: BigFieldDelay::
; In delay state, DAS increments double speed.
.incl
ldh a, [hLeftState]
cp a, 0
jr z, .incr
inc a
ldh [hLeftState], a
.incr
ldh a, [hRightState]
cp a, 0
jr z, .noinc
inc a
ldh [hRightState], a
; Switch on the delay state. ; Switch on the delay state.
.noinc
ld a, [wDelayState] ld a, [wDelayState]
cp DELAY_STATE_DETERMINE_DELAY cp DELAY_STATE_DETERMINE_DELAY
jr z, .determine jr z, .determine
@ -4432,49 +4445,53 @@ BigClearLines:
BigWidenField:: BigWidenField::
ld de, wField+(4*10) ld de, wField+(3*10)
ld hl, wWideField ld hl, wWideField
ld bc, 5 ld bc, 5
call UnsafeMemCopy call UnsafeMemCopy
ld de, wField+(5*10) ld de, wField+(4*10)
ld hl, wWideField+5 ld hl, wWideField+5
ld bc, 5 ld bc, 5
call UnsafeMemCopy call UnsafeMemCopy
ld de, wField+(6*10) ld de, wField+(5*10)
ld hl, wWideField+10 ld hl, wWideField+10
ld bc, 5 ld bc, 5
call UnsafeMemCopy call UnsafeMemCopy
ld de, wField+(7*10) ld de, wField+(6*10)
ld hl, wWideField+15 ld hl, wWideField+15
ld bc, 5 ld bc, 5
call UnsafeMemCopy call UnsafeMemCopy
ld de, wField+(8*10) ld de, wField+(7*10)
ld hl, wWideField+20 ld hl, wWideField+20
ld bc, 5 ld bc, 5
call UnsafeMemCopy call UnsafeMemCopy
ld de, wField+(9*10) ld de, wField+(8*10)
ld hl, wWideField+25 ld hl, wWideField+25
ld bc, 5 ld bc, 5
call UnsafeMemCopy call UnsafeMemCopy
ld de, wField+(10*10) ld de, wField+(9*10)
ld hl, wWideField+30 ld hl, wWideField+30
ld bc, 5 ld bc, 5
call UnsafeMemCopy call UnsafeMemCopy
ld de, wField+(11*10) ld de, wField+(10*10)
ld hl, wWideField+35 ld hl, wWideField+35
ld bc, 5 ld bc, 5
call UnsafeMemCopy call UnsafeMemCopy
ld de, wField+(12*10) ld de, wField+(11*10)
ld hl, wWideField+40 ld hl, wWideField+40
ld bc, 5 ld bc, 5
call UnsafeMemCopy call UnsafeMemCopy
ld de, wField+(13*10) ld de, wField+(12*10)
ld hl, wWideField+45 ld hl, wWideField+45
ld bc, 5 ld bc, 5
call UnsafeMemCopy call UnsafeMemCopy
ld de, wField+(13*10)
ld hl, wWideField+50
ld bc, 5
call UnsafeMemCopy
DEF piece = 0 DEF piece = 0
REPT 50 REPT 55
ld a, [wWideField+piece] ld a, [wWideField+piece]
ld hl, wWideBlittedField+((piece/5)*20)+((piece%5) * 2) ld hl, wWideBlittedField+((piece/5)*20)+((piece%5) * 2)
ld [hl+], a ld [hl+], a

View File

@ -115,7 +115,7 @@ ToATTR::
ldh [rHDMA3], a ldh [rHDMA3], a
ld a, LOW($9800) ld a, LOW($9800)
ldh [rHDMA4], a ldh [rHDMA4], a
ld a, 40 ld a, 41
ldh [rHDMA5], a ldh [rHDMA5], a
ld a, 0 ld a, 0
ldh [rVBK], a ldh [rVBK], a
@ -221,7 +221,7 @@ GBCGameplayInit::
ld bc, 32*32 ld bc, 32*32
call UnsafeMemCopy call UnsafeMemCopy
; Copy set attrs to pal 7 and copy to shadow. ; Set attrs to pal 7 and copy to shadow.
ld a, 1 ld a, 1
ldh [rVBK], a ldh [rVBK], a
ld d, $07 ld d, $07
@ -251,8 +251,8 @@ GBCTitleProcess::
ld bc, 32 ld bc, 32
call UnsafeMemSet call UnsafeMemSet
ld d, $07 ld d, $07
ld hl, wShadowTileAttrs+32 ld hl, wShadowTileAttrs
ld bc, (19*32) ld bc, (32*32)
call UnsafeMemSet call UnsafeMemSet
; Palette for the title? ; Palette for the title?
@ -272,14 +272,14 @@ GBCTitleProcess::
; Set the palette for the title. ; Set the palette for the title.
ld a, [wTitlePal] ld a, [wTitlePal]
ld d, a ld d, a
ld hl, wShadowTileAttrs + (2*32) ld hl, wShadowTileAttrs + (3*32)
ld bc, (4*32) ld bc, (4*32)
call UnsafeMemSet call UnsafeMemSet
; And the selected row. ; And the selected row.
ld a, [wSelected] ld a, [wSelected]
inc a inc a
ld hl, wShadowTileAttrs + (5*32) ld hl, wShadowTileAttrs + (6*32)
ld bc, 64 ld bc, 64
: add hl, bc : add hl, bc
dec a dec a
@ -346,39 +346,58 @@ GBCGameplayProcess::
ld a, $05 ld a, $05
ld d, a ld d, a
.colorfield .colorfield
ld hl, wShadowTileAttrs ld a, d
ld bc, 32-12 DEF row = 0
REPT 21
ld hl, wShadowTileAttrs+(row*32)+10
ld [hl], a
ld hl, wShadowTileAttrs+(row*32)+19
ld [hl], a
DEF row += 1
ENDR
ld a, 21 ld hl, wShadowTileAttrs+203
ld [wOuterReps], a ld [hl+], a
.outer0 ld [hl+], a
ld a, 12 ld [hl+], a
ld [wInnerReps], a ld [hl+], a
.inner0 ld [hl+], a
ld [hl], d ld [hl+], a
inc hl ld [hl+], a
ld a, [wInnerReps] ld [hl], a
dec a
ld [wInnerReps], a
jr nz, .inner0
add hl, bc ld hl, wShadowTileAttrs+395
ld a, [wOuterReps] ld [hl+], a
dec a ld [hl+], a
ld [wOuterReps], a ld [hl+], a
jr nz, .outer0 ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl], a
ld hl, wShadowTileAttrs+491
ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl], a
; What to copy ; What to copy
: ld de, wField + 40 : ld de, wField + 30
; Where to put it ; Where to put it
ld hl, wShadowTilemap + 1 ld hl, wShadowTilemap
; How much to increment hl after each row ; How much to increment hl after each row
ld bc, 32-10 ld bc, 32-10
; Blit me up daddy. ; Blit me up daddy.
ld a, 20 ld a, 21
ld [wOuterReps], a ld [wOuterReps], a
.outer1 .outer1
ld a, 10 ld a, 10
@ -400,14 +419,14 @@ GBCGameplayProcess::
; What to copy ; What to copy
ld de, wField + 40 ld de, wField + 30
; Where to put it ; Where to put it
ld hl, wShadowTileAttrs + 1 ld hl, wShadowTileAttrs
; How much to increment hl after each row ; How much to increment hl after each row
ld bc, 32-10 ld bc, 32-10
; Blit me up daddy. ; Blit me up daddy.
ld a, 20 ld a, 21
ld [wOuterReps], a ld [wOuterReps], a
.outer2 .outer2
ld a, 10 ld a, 10
@ -564,38 +583,56 @@ GBCBigGameplayProcess::
ld d, a ld d, a
.colorfield .colorfield
ld hl, wShadowTileAttrs ld a, d
ld bc, 32-12 DEF row = 0
REPT 21
ld hl, wShadowTileAttrs+(row*32)+10
ld [hl], a
ld hl, wShadowTileAttrs+(row*32)+19
ld [hl], a
DEF row += 1
ENDR
ld a, 21 ld hl, wShadowTileAttrs+203
ld [wOuterReps], a ld [hl+], a
.outer0 ld [hl+], a
ld a, 12 ld [hl+], a
ld [wInnerReps], a ld [hl+], a
.inner0 ld [hl+], a
ld [hl], d ld [hl+], a
inc hl ld [hl+], a
ld a, [wInnerReps] ld [hl], a
dec a
ld [wInnerReps], a
jr nz, .inner0
add hl, bc ld hl, wShadowTileAttrs+395
ld a, [wOuterReps] ld [hl+], a
dec a ld [hl+], a
ld [wOuterReps], a ld [hl+], a
jr nz, .outer0 ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl], a
ld hl, wShadowTileAttrs+491
ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl+], a
ld [hl], a
; What to copy ; What to copy
: ld de, wWideBlittedField : ld de, wWideBlittedField+10
; Where to put it ; Where to put it
ld hl, wShadowTilemap + 1 ld hl, wShadowTilemap
; How much to increment hl after each row ; How much to increment hl after each row
ld bc, 32-10 ld bc, 32-10
; Blit me up daddy. ; Blit me up daddy.
ld a, 20 ld a, 21
ld [wOuterReps], a ld [wOuterReps], a
.outer1 .outer1
ld a, 10 ld a, 10
@ -617,14 +654,14 @@ GBCBigGameplayProcess::
; What to copy ; What to copy
ld de, wWideBlittedField ld de, wWideBlittedField+10
; Where to put it ; Where to put it
ld hl, wShadowTileAttrs + 1 ld hl, wShadowTileAttrs
; How much to increment hl after each row ; How much to increment hl after each row
ld bc, 32-10 ld bc, 32-10
; Blit me up daddy. ; Blit me up daddy.
ld a, 20 ld a, 21
ld [wOuterReps], a ld [wOuterReps], a
.outer2 .outer2
ld a, 10 ld a, 10
@ -740,7 +777,7 @@ ToVRAM::
ldh [rHDMA3], a ldh [rHDMA3], a
ld a, LOW($9800) ld a, LOW($9800)
ldh [rHDMA4], a ldh [rHDMA4], a
ld a, 40 ld a, 41
ldh [rHDMA5], a ldh [rHDMA5], a
; Bank 0 ; Bank 0
@ -754,7 +791,7 @@ ToVRAM::
ldh [rHDMA3], a ldh [rHDMA3], a
ld a, LOW($9800) ld a, LOW($9800)
ldh [rHDMA4], a ldh [rHDMA4], a
ld a, 39 | $80 ld a, 41 | $80
ldh [rHDMA5], a ldh [rHDMA5], a
jp EventLoop jp EventLoop

View File

@ -163,19 +163,21 @@ DEF PALETTE_LIGHTER_2 EQU %01000000
DEF PALETTE_LIGHTER_3 EQU %00000000 DEF PALETTE_LIGHTER_3 EQU %00000000
; Sprite base positions. ; Sprite base positions.
DEF NEXT_BASE_X EQU 113 DEF NEXT_BASE_X EQU 100
DEF NEXT_BASE_Y EQU 40 DEF NEXT_BASE_Y EQU 37
DEF HOLD_BASE_X EQU 113 DEF HOLD_BASE_X EQU 100
DEF HOLD_BASE_Y EQU 80 DEF HOLD_BASE_Y EQU 77
DEF QUEUE_BASE_X EQU 145 DEF QUEUE_BASE_X EQU 131
DEF QUEUE_BASE_Y EQU 38 DEF QUEUE_BASE_Y EQU 35
DEF SCORE_BASE_X EQU 112 DEF SCORE_BASE_X EQU 112
DEF SCORE_BASE_Y EQU 115 DEF SCORE_BASE_Y EQU 112
DEF LEVEL_BASE_X EQU 120 DEF LEVEL_BASE_X EQU 112
DEF CLEVEL_BASE_Y EQU 136 DEF CLEVEL_BASE_Y EQU 133
DEF NLEVEL_BASE_Y EQU 148 DEF NLEVEL_BASE_Y EQU 145
DEF GRADE_BASE_X EQU 145
DEF GRADE_BASE_Y EQU 20
DEF TELLS_BASE_X EQU 154 DEF TELLS_BASE_X EQU 154
DEF TELLS_BASE_Y EQU 64 DEF TELLS_BASE_Y EQU 61
DEF TELLS_Y_DIST EQU 10 DEF TELLS_Y_DIST EQU 10
; Piece names ; Piece names
@ -263,13 +265,13 @@ DEF HIG_MODE_COUNT EQU 2
; VRAM Offsets for title screen tiles ; VRAM Offsets for title screen tiles
DEF TITLE_OPTIONS EQU 7 DEF TITLE_OPTIONS EQU 7
DEF TITLE_OPTION_0 EQU $98E0 DEF TITLE_OPTION_0 EQU $9900
DEF TITLE_OPTION_1 EQU $9920 DEF TITLE_OPTION_1 EQU $9940
DEF TITLE_OPTION_2 EQU $9960 DEF TITLE_OPTION_2 EQU $9980
DEF TITLE_OPTION_3 EQU $99A0 DEF TITLE_OPTION_3 EQU $99C0
DEF TITLE_OPTION_4 EQU $99E0 DEF TITLE_OPTION_4 EQU $9A00
DEF TITLE_OPTION_5 EQU $9A20 DEF TITLE_OPTION_5 EQU $9A40
DEF TITLE_OPTION_6 EQU $9A60 DEF TITLE_OPTION_6 EQU $9A80
DEF TITLE_OPTION_OFFSET EQU 15 DEF TITLE_OPTION_OFFSET EQU 15
; VRAM Offsets for gameplay tiles ; VRAM Offsets for gameplay tiles
@ -277,7 +279,7 @@ DEF FIELD_RNG EQU $9852
DEF FIELD_ROT EQU $9892 DEF FIELD_ROT EQU $9892
DEF FIELD_DROP EQU $9912 DEF FIELD_DROP EQU $9912
DEF FIELD_HIG EQU $9952 DEF FIELD_HIG EQU $9952
DEF FIELD_TOP_LEFT EQU $9800+1 DEF FIELD_TOP_LEFT EQU $9800
; Gameplay definitions. ; Gameplay definitions.
DEF LEADY_TIME EQU 80 DEF LEADY_TIME EQU 80
@ -298,8 +300,8 @@ DEF STATE_GAMEPLAY_BIG EQU 6
; Other ; Other
DEF STACK_SIZE EQU 64 DEF STACK_SIZE EQU 64
DEF EASTER_0 EQU $9845 DEF EASTER_0 EQU $9865
DEF EASTER_1 EQU $9865 DEF EASTER_1 EQU $9885
; Magic location for bank id. ; Magic location for bank id.
DEF rBANKID EQU $4007 DEF rBANKID EQU $4007

View File

@ -22,6 +22,10 @@ DEF INTERRUPTS_ASM EQU 1
INCLUDE "globals.asm" INCLUDE "globals.asm"
DEF INIT_SCY EQU 3
DEF INIT_LYC EQU 3
SECTION "High Interrupt Variables", HRAM SECTION "High Interrupt Variables", HRAM
hLCDCCtr:: ds 1 hLCDCCtr:: ds 1
@ -37,9 +41,9 @@ IntrInit::
InitializeLCDCInterrupt:: InitializeLCDCInterrupt::
ld a, STATF_LYC ld a, STATF_LYC
ldh [rSTAT], a ldh [rSTAT], a
ld a, 6 ld a, INIT_LYC
ldh [rLYC], a ldh [rLYC], a
ld a, 0 ld a, INIT_SCY
ldh [rSCY], a ldh [rSCY], a
ld a, IEF_STAT ld a, IEF_STAT
ldh [rIE], a ldh [rIE], a
@ -72,19 +76,14 @@ LCDCInterrupt_WaitUntilNotBusy:
ldh [rLYC], a ldh [rLYC], a
; Check our interrupt counter ; Check our interrupt counter
ldh a, [hLCDCCtr] cp a, 144
cp 21 jr c, LCDCInterrupt_End
jr nz, LCDCInterrupt_End ld a, INIT_LYC
ld a, 255
ldh [hLCDCCtr], a
ld a, 6
ldh [rLYC], a ldh [rLYC], a
ld a, 0 ld a, INIT_SCY
ldh [rSCY], a ldh [rSCY], a
LCDCInterrupt_End: LCDCInterrupt_End:
inc a
ldh [hLCDCCtr], a
pop hl pop hl
pop af pop af
reti reti

View File

@ -241,72 +241,74 @@ sBigPieceRotationStates:: ; How each piece is rotated.
db %0000 db %0000
sBigGameplayTileMap:: sBigGameplayTileMap::
DB $02,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$03,$09,$01,$01,$01,$01,$01,$01,$09 DB $03,$01,$01,$01,$01,$01,$01,$01,$01,$09
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00 DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$02,$01,$01,$01,$01,$01,$01,$01 DB $00,$00,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$03,$09,$59,$50,$63,$5F,$01 DB $01,$01,$03,$59,$50,$63,$5F,$01,$01,$01
DB $01,$09,$00,$00,$00,$00,$00,$00,$00,$00 DB $01,$09,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$02,$01,$01,$01,$01,$01 DB $00,$00,$00,$00,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$03,$09,$01,$01,$01 DB $01,$01,$01,$01,$03,$01,$01,$01,$01,$01
DB $01,$01,$01,$09,$00,$00,$00,$00,$00,$00 DB $01,$01,$01,$09,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$02,$01,$01,$01 DB $00,$00,$00,$00,$00,$00,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$03,$09,$01 DB $01,$01,$01,$01,$01,$01,$03,$01,$01,$01
DB $01,$01,$01,$01,$01,$09,$00,$00,$00,$00 DB $01,$01,$01,$01,$01,$09,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$02,$01 DB $00,$00,$00,$00,$00,$00,$00,$00,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$03 DB $01,$01,$01,$01,$01,$01,$01,$01,$03,$01
DB $09,$01,$01,$01,$01,$01,$01,$09,$00,$00 DB $01,$01,$01,$01,$01,$01,$01,$09,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00 DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $02,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$03,$09,$01,$01,$01,$01,$01,$01,$09 DB $03,$01,$01,$01,$01,$01,$01,$01,$01,$09
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00 DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$02,$01,$01,$01,$01,$01,$01,$01 DB $00,$00,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$03,$08,$06,$06,$06,$06,$06 DB $01,$01,$08,$06,$06,$06,$06,$06,$06,$06
DB $06,$07,$00,$00,$00,$00,$00,$00,$00,$00 DB $06,$07,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$02,$01,$01,$01,$01,$01 DB $00,$00,$00,$00,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$03,$09,$53,$5A,$57 DB $01,$01,$01,$01,$03,$53,$5A,$57,$4F,$01
DB $4F,$01,$01,$09,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$02,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$03,$09,$01
DB $01,$01,$01,$01,$01,$09,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$02,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$03
DB $09,$01,$01,$01,$01,$01,$01,$09,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $02,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$03,$09,$01,$01,$01,$01,$01,$01,$09
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$02,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$03,$09,$01,$01,$01,$01,$01
DB $01,$09,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$02,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$03,$08,$06,$06,$06
DB $06,$06,$06,$07,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$02,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$03,$09,$5E
DB $4E,$5A,$5D,$50,$01,$09,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$02,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$03
DB $09,$01,$01,$01,$01,$01,$01,$09,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $02,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$03,$08,$06,$06,$06,$06,$06,$06,$07
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$02,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$03,$09,$57,$50,$61,$50,$57
DB $01,$09,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$02,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$03,$09,$01,$01,$01
DB $01,$01,$01,$09,$00,$00,$00,$00,$00,$00 DB $01,$01,$01,$09,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$02,$01,$01,$01 DB $00,$00,$00,$00,$00,$00,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$03,$09,$01 DB $01,$01,$01,$01,$01,$01,$03,$01,$01,$01
DB $05,$05,$05,$05,$01,$09,$00,$00,$00,$00 DB $01,$01,$01,$01,$01,$09,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$02,$01 DB $00,$00,$00,$00,$00,$00,$00,$00,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$03 DB $01,$01,$01,$01,$01,$01,$01,$01,$03,$01
DB $09,$01,$01,$01,$01,$01,$01,$09,$00,$00 DB $01,$01,$01,$01,$01,$01,$01,$09,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00 DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $02,$00,$00,$00,$00,$00,$00,$00,$00,$00 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $00,$03,$09,$01,$01,$01,$01,$01,$01,$09 DB $03,$01,$01,$01,$01,$01,$01,$01,$01,$09
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$03,$01,$01,$01,$01,$01,$01,$01
DB $01,$09,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$08,$06,$06,$06,$06,$06
DB $06,$06,$06,$07,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$03,$5E,$4E,$5A
DB $5D,$50,$01,$01,$01,$09,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$03,$01
DB $01,$01,$01,$01,$01,$01,$01,$09,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $08,$06,$06,$06,$06,$06,$06,$06,$06,$07
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$03,$57,$50,$61,$50,$57,$01,$01
DB $01,$09,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$03,$01,$01,$01,$01,$01
DB $01,$01,$01,$09,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$03,$01,$01,$05
DB $05,$05,$05,$01,$01,$09,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$03,$01
DB $01,$01,$01,$01,$01,$01,$01,$09,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $03,$01,$01,$01,$01,$01,$01,$01,$01,$09
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00
sBigGameplayTileMapEnd:: sBigGameplayTileMapEnd::

View File

@ -253,72 +253,74 @@ sTGM3Droughts::
db 0, 0, 0, 0, 0, 0, 0 db 0, 0, 0, 0, 0, 0, 0
sGameplayTileMap:: sGameplayTileMap::
DB $02,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$03,$09,$01,$01,$01,$01,$01,$01,$09 DB $03,$01,$01,$01,$01,$01,$01,$01,$01,$09
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00 DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$02,$01,$01,$01,$01,$01,$01,$01 DB $00,$00,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$03,$09,$59,$50,$63,$5F,$01 DB $01,$01,$03,$59,$50,$63,$5F,$01,$01,$01
DB $01,$09,$00,$00,$00,$00,$00,$00,$00,$00 DB $01,$09,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$02,$01,$01,$01,$01,$01 DB $00,$00,$00,$00,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$03,$09,$01,$01,$01 DB $01,$01,$01,$01,$03,$01,$01,$01,$01,$01
DB $01,$01,$01,$09,$00,$00,$00,$00,$00,$00 DB $01,$01,$01,$09,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$02,$01,$01,$01 DB $00,$00,$00,$00,$00,$00,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$03,$09,$01 DB $01,$01,$01,$01,$01,$01,$03,$01,$01,$01
DB $01,$01,$01,$01,$01,$09,$00,$00,$00,$00 DB $01,$01,$01,$01,$01,$09,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$02,$01 DB $00,$00,$00,$00,$00,$00,$00,$00,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$03 DB $01,$01,$01,$01,$01,$01,$01,$01,$03,$01
DB $09,$01,$01,$01,$01,$01,$01,$09,$00,$00 DB $01,$01,$01,$01,$01,$01,$01,$09,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00 DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $02,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$03,$09,$01,$01,$01,$01,$01,$01,$09 DB $03,$01,$01,$01,$01,$01,$01,$01,$01,$09
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00 DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$02,$01,$01,$01,$01,$01,$01,$01 DB $00,$00,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$03,$08,$06,$06,$06,$06,$06 DB $01,$01,$08,$06,$06,$06,$06,$06,$06,$06
DB $06,$07,$00,$00,$00,$00,$00,$00,$00,$00 DB $06,$07,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$02,$01,$01,$01,$01,$01 DB $00,$00,$00,$00,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$03,$09,$53,$5A,$57 DB $01,$01,$01,$01,$03,$53,$5A,$57,$4F,$01
DB $4F,$01,$01,$09,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$02,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$03,$09,$01
DB $01,$01,$01,$01,$01,$09,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$02,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$03
DB $09,$01,$01,$01,$01,$01,$01,$09,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $02,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$03,$09,$01,$01,$01,$01,$01,$01,$09
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$02,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$03,$09,$01,$01,$01,$01,$01
DB $01,$09,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$02,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$03,$08,$06,$06,$06
DB $06,$06,$06,$07,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$02,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$03,$09,$5E
DB $4E,$5A,$5D,$50,$01,$09,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$02,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$03
DB $09,$01,$01,$01,$01,$01,$01,$09,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $02,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$03,$08,$06,$06,$06,$06,$06,$06,$07
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$02,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$03,$09,$57,$50,$61,$50,$57
DB $01,$09,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$02,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$03,$09,$01,$01,$01
DB $01,$01,$01,$09,$00,$00,$00,$00,$00,$00 DB $01,$01,$01,$09,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$02,$01,$01,$01 DB $00,$00,$00,$00,$00,$00,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$03,$09,$01 DB $01,$01,$01,$01,$01,$01,$03,$01,$01,$01
DB $05,$05,$05,$05,$01,$09,$00,$00,$00,$00 DB $01,$01,$01,$01,$01,$09,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$02,$01 DB $00,$00,$00,$00,$00,$00,$00,$00,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$03 DB $01,$01,$01,$01,$01,$01,$01,$01,$03,$01
DB $09,$01,$01,$01,$01,$01,$01,$09,$00,$00 DB $01,$01,$01,$01,$01,$01,$01,$09,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00 DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $02,$00,$00,$00,$00,$00,$00,$00,$00,$00 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $00,$03,$09,$01,$01,$01,$01,$01,$01,$09 DB $03,$01,$01,$01,$01,$01,$01,$01,$01,$09
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$03,$01,$01,$01,$01,$01,$01,$01
DB $01,$09,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$08,$06,$06,$06,$06,$06
DB $06,$06,$06,$07,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$03,$5E,$4E,$5A
DB $5D,$50,$01,$01,$01,$09,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$03,$01
DB $01,$01,$01,$01,$01,$01,$01,$09,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $08,$06,$06,$06,$06,$06,$06,$06,$06,$07
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$03,$57,$50,$61,$50,$57,$01,$01
DB $01,$09,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$03,$01,$01,$01,$01,$01
DB $01,$01,$01,$09,$00,$00,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$03,$01,$01,$05
DB $05,$05,$05,$01,$01,$09,$00,$00,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$03,$01
DB $01,$01,$01,$01,$01,$01,$01,$09,$00,$00
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $03,$01,$01,$01,$01,$01,$01,$01,$01,$09
DB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00
DB $00,$00
sGameplayTileMapEnd:: sGameplayTileMapEnd::

View File

@ -642,8 +642,8 @@ sTiles::
DB $FF,$FF,$00,$00,$00,$00,$00,$00 DB $FF,$FF,$00,$00,$00,$00,$00,$00
DB $1C,$14,$1C,$14,$FC,$E4,$F8,$08 DB $1C,$14,$1C,$14,$FC,$E4,$F8,$08
DB $FC,$E4,$1C,$14,$1C,$14,$00,$00 DB $FC,$E4,$1C,$14,$1C,$14,$00,$00
DB $1C,$14,$1C,$14,$1F,$13,$0F,$08 DB $E6,$F8,$E6,$F8,$FF,$FF,$E7,$F8
DB $1F,$13,$1C,$14,$1C,$14,$00,$00 DB $FF,$FF,$E6,$F8,$E6,$F8,$00,$00
DB $1C,$14,$1C,$14,$1C,$14,$1C,$14 DB $1C,$14,$1C,$14,$1C,$14,$1C,$14
DB $1C,$14,$1C,$14,$1C,$14,$00,$00 DB $1C,$14,$1C,$14,$1C,$14,$00,$00
DB $00,$FF,$7E,$99,$66,$BD,$66,$BD DB $00,$FF,$7E,$99,$66,$BD,$66,$BD
@ -1132,12 +1132,12 @@ sTiles::
DB $8A,$8A,$8A,$8A,$E4,$E4,$00,$00 DB $8A,$8A,$8A,$8A,$E4,$E4,$00,$00
DB $CC,$CC,$22,$22,$22,$22,$44,$44 DB $CC,$CC,$22,$22,$22,$22,$44,$44
DB $82,$82,$82,$82,$EC,$EC,$00,$00 DB $82,$82,$82,$82,$EC,$EC,$00,$00
DB $44,$44,$CA,$CA,$4A,$4A,$4A,$4A DB $44,$44,$CC,$CC,$44,$44,$44,$44
DB $4A,$4A,$4A,$4A,$E4,$E4,$00,$00 DB $44,$44,$44,$44,$EE,$EE,$00,$00
DB $C4,$C4,$2C,$2C,$24,$24,$44,$44 DB $44,$44,$AC,$AC,$A4,$A4,$A4,$A4
DB $24,$24,$24,$24,$CE,$CE,$00,$00 DB $A4,$A4,$A4,$A4,$4E,$4E,$00,$00
DB $00,$00,$42,$42,$BD,$BD,$42,$42 DB $00,$00,$08,$08,$1C,$1C,$30,$30
DB $BD,$BD,$42,$42,$00,$00,$00,$00 DB $3C,$3C,$1C,$1C,$14,$14,$00,$00
sTilesEnd:: sTilesEnd::
sColorTiles:: sColorTiles::

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -74,73 +74,73 @@ sDisabled::
db "----" db "----"
sTitleScreenTileMap:: sTitleScreenTileMap::
DB $C3,$5B,$4C,$59,$4F,$5A,$5D,$4C,$01,$59 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $5A,$61,$4C,$01,$01,$FB,$FC,$FD,$FE,$FF DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$C3,$5B,$4C,$59,$4F,$5A,$5D,$4C
DB $01,$59,$5A,$61,$4C,$01,$01,$FB,$FC,$FD
DB $FE,$FF,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$68 DB $01,$68,$6A,$6C,$6E,$70,$72,$74,$76,$78
DB $6A,$6C,$6E,$70,$72,$74,$76,$78,$7A,$01 DB $7A,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$69,$6B,$6D,$6F,$71,$73,$75
DB $01,$69,$6B,$6D,$6F,$71,$73,$75,$77,$79 DB $77,$79,$7B,$01,$01,$01,$01,$01,$01,$01
DB $7B,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$5B,$5D,$50,$5E,$5E,$01 DB $01,$01,$01,$01,$01,$01,$5B,$5D,$50,$5E
DB $5E,$5F,$4C,$5D,$5F,$66,$01,$01,$01,$01 DB $5E,$01,$5E,$5F,$4C,$5D,$5F,$66,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$C1,$01,$4D,$60,$5F,$5F DB $01,$01,$01,$01,$01,$01,$C1,$01,$4D,$60
DB $5A,$59,$5E,$01,$01,$01,$01,$01,$81,$01 DB $5F,$5F,$5A,$59,$5E,$01,$01,$01,$01,$01
DB $01,$01,$01,$82,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$C2,$01
DB $5D,$59,$52,$01,$58,$5A,$4F,$50,$01,$01
DB $01,$01,$81,$01,$01,$01,$01,$82,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$C2,$01,$5D,$5A,$5F,$01,$58,$5A
DB $4F,$50,$01,$01,$01,$01,$81,$01,$01,$01
DB $01,$82,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$C2,$01,$4F,$5D
DB $5A,$5B,$01,$58,$5A,$4F,$50,$01,$01,$01
DB $81,$01,$01,$01,$01,$82,$01,$01,$01,$01 DB $81,$01,$01,$01,$01,$82,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $C2,$01,$5E,$5B,$50,$50,$4F,$01,$4E,$60 DB $C2,$01,$5D,$59,$52,$01,$58,$5A,$4F,$50
DB $5D,$61,$50,$01,$81,$01,$01,$01,$01,$82 DB $01,$01,$01,$01,$81,$01,$01,$01,$01,$82
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$C2,$01,$4C,$57,$62,$4C DB $01,$01,$01,$01,$C2,$01,$5D,$5A,$5F,$01
DB $64,$5E,$01,$44,$42,$52,$01,$01,$81,$01 DB $58,$5A,$4F,$50,$01,$01,$01,$01,$81,$01
DB $01,$01,$01,$82,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$82,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$C2,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$C2,$01
DB $5E,$5F,$4C,$5D,$5F,$01,$57,$50,$61,$50 DB $4F,$5D,$5A,$5B,$01,$58,$5A,$4F,$50,$01
DB $57,$01,$81,$01,$01,$01,$01,$82,$01,$01 DB $01,$01,$81,$01,$01,$01,$01,$82,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01 DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$C2,$01,$5E,$5B,$50,$50,$4F,$01
DB $4E,$60,$5D,$61,$50,$01,$81,$01,$01,$01
DB $01,$82,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$C2,$01,$4C,$57
DB $62,$4C,$64,$5E,$01,$44,$42,$52,$01,$01
DB $81,$01,$01,$01,$01,$82,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $C2,$01,$5E,$5F,$4C,$5D,$5F,$01,$57,$50
DB $61,$50,$57,$01,$81,$01,$01,$01,$01,$82
DB $01,$01,$01,$01,$01,$01,$01,$01,$01,$01
DB $01,$01 DB $01,$01
sTitleScreenTileMapEnd:: sTitleScreenTileMapEnd::

View File

@ -605,12 +605,12 @@ SetNumberSpritePositions::
GradeRendering:: GradeRendering::
; Set the Y position of the grade objects. ; Set the Y position of the grade objects.
ld a, $17 ld a, GRADE_BASE_Y
ld [wGrade0], a ld [wGrade0], a
ld [wGrade1], a ld [wGrade1], a
; Set the X position of the grade objects. ; Set the X position of the grade objects.
ld a, $91 ld a, GRADE_BASE_X
ld [wGrade0+1], a ld [wGrade0+1], a
add a, $8 add a, $8
ld [wGrade1+1], a ld [wGrade1+1], a

View File

@ -413,8 +413,8 @@ GamePlayEventLoopHandlerB::
; Draw the field in grey. ; Draw the field in grey.
; Yes. This really unrolls the loop that many times. ; Yes. This really unrolls the loop that many times.
ld hl, wField+(4*10) ld hl, wField+(3*10)
REPT 60 REPT 70
ld a, [hl] ld a, [hl]
cp a, TILE_FIELD_EMPTY cp a, TILE_FIELD_EMPTY
jr nz, .notempty1\@ jr nz, .notempty1\@
@ -558,7 +558,7 @@ GamePlayEventLoopHandlerB::
call FromBackupField call FromBackupField
ldh a, [hPrePause] ldh a, [hPrePause]
ldh [hMode], a ldh [hMode], a
jr .drawStaticInfo jp .drawStaticInfo
; Draw PAUSE all over the field. ; Draw PAUSE all over the field.
.nounpause .nounpause
@ -567,6 +567,10 @@ GamePlayEventLoopHandlerB::
ld bc, 20 ld bc, 20
call UnsafeMemCopy call UnsafeMemCopy
ld de, sPause ld de, sPause
ld hl, wField+(2*10)
ld bc, 20
call UnsafeMemCopy
ld de, sPause
ld hl, wField+(6*10) ld hl, wField+(6*10)
ld bc, 20 ld bc, 20
call UnsafeMemCopy call UnsafeMemCopy
@ -1110,7 +1114,7 @@ GamePlayBigEventLoopHandlerB:
.skip6\@ .skip6\@
DEF off += 1 DEF off += 1
ENDR ENDR
REPT 90 REPT 110
ld a, [hl] ld a, [hl]
cp a, TILE_FIELD_EMPTY cp a, TILE_FIELD_EMPTY
jr nz, .notempty7\@ jr nz, .notempty7\@