Remove unnecessary DMG and SGB checking (#7)

This commit is contained in:
xCrystal
2023-07-26 14:29:16 +02:00
parent 15f452ff26
commit acd022d765
30 changed files with 10 additions and 713 deletions

View File

@@ -155,13 +155,6 @@ INCBIN "gfx/overworld/heal_machine.2bpp"
dbsprite 11, 7, 5, 1, $7d, PAL_OW_TREE | OBP_NUM
.LoadPalettes:
call IsCGB
jr nz, .cgb
ld a, %11100000
ldh [rOBP1], a
ret
.cgb
ld hl, .palettes
ld de, wOBPals2 palette PAL_OW_TREE
ld bc, 1 palettes
@@ -187,14 +180,6 @@ INCLUDE "gfx/overworld/heal_machine.pal"
ret
.FlashPalettes:
call IsCGB
jr nz, .go
ldh a, [rOBP1]
xor %00101000
ldh [rOBP1], a
ret
.go
ldh a, [rSVBK]
push af
ld a, BANK(wOBPals2)

View File

@@ -438,7 +438,7 @@ Mom_ContinueMenuSetup:
lb bc, PRINTNUM_MONEY | PRINTNUM_LEADINGZEROS | 3, 6
call PrintNum
call UpdateSprites
call CGBOnly_CopyTilemapAtOnce
call CopyTilemapAtOnce
ret
Mom_Wait10Frames:

View File

@@ -1,30 +1,8 @@
LoadPoisonBGPals:
call .LoadPals
ldh a, [hCGB]
and a
ret nz
; code was probably dummied out here
ret
.LoadPals:
ldh a, [hCGB]
and a
jr nz, .cgb
ld a, [wTimeOfDayPal]
maskbits NUM_DAYTIMES
cp DARKNESS_F
ld a, %00000000
jr z, .convert_pals
ld a, %10101010
.convert_pals
call DmgToCgbBGPals
ld c, 4
call DelayFrames
farcall _UpdateTimePals
ret
.cgb
ldh a, [rSVBK]
push af
ld a, BANK(wBGPals2)