mirror of https://github.com/pret/pokecrystal.git
Various cleanup
This commit is contained in:
parent
8259136911
commit
b3f0e11567
|
@ -20,5 +20,4 @@ HP_BAR_LENGTH_PX EQU HP_BAR_LENGTH * TILE_WIDTH ; pixels
|
|||
EXP_BAR_LENGTH EQU 8 ; tiles
|
||||
EXP_BAR_LENGTH_PX EQU EXP_BAR_LENGTH * TILE_WIDTH ; pixels
|
||||
|
||||
|
||||
PALPACKET_LENGTH EQU $10
|
||||
|
|
|
@ -5,7 +5,7 @@ NOT_VERY_EFFECTIVE EQU 05
|
|||
NO_EFFECT EQU 00
|
||||
|
||||
TypeMatchups: ; 34bb1
|
||||
; attacker defender*=
|
||||
; attacker, defender, *=
|
||||
db NORMAL, ROCK, NOT_VERY_EFFECTIVE
|
||||
db NORMAL, STEEL, NOT_VERY_EFFECTIVE
|
||||
db FIRE, FIRE, NOT_VERY_EFFECTIVE
|
||||
|
|
|
@ -383,7 +383,7 @@ MailboxPC_PrintMailAuthor: ; 0x447fb
|
|||
|
||||
MailboxPC: ; 0x44806
|
||||
xor a
|
||||
ld [OBPals + 8 * 6], a
|
||||
ld [OBPals palette 6], a
|
||||
ld a, 1
|
||||
ld [wCurMessageIndex], a
|
||||
.loop
|
||||
|
@ -397,11 +397,11 @@ MailboxPC: ; 0x44806
|
|||
|
||||
ld a, [wCurMessageIndex]
|
||||
ld [wMenuCursorBuffer], a
|
||||
ld a, [OBPals + 8 * 6]
|
||||
ld a, [OBPals palette 6]
|
||||
ld [wMenuScrollPosition], a
|
||||
call ScrollingMenu
|
||||
ld a, [wMenuScrollPosition]
|
||||
ld [OBPals + 8 * 6], a
|
||||
ld [OBPals palette 6], a
|
||||
ld a, [wMenuCursorY]
|
||||
ld [wCurMessageIndex], a
|
||||
|
||||
|
|
|
@ -41,19 +41,18 @@ _TimeOfDayPals:: ; 8c011
|
|||
; update palette id
|
||||
ld [TimeOfDayPal], a
|
||||
|
||||
|
||||
; save bg palette 8
|
||||
ld hl, UnknBGPals + 8 * 7 ; UnknBGPals + 7 pals
|
||||
; save bg palette 7
|
||||
ld hl, UnknBGPals palette PAL_BG_TEXT
|
||||
|
||||
; save wram bank
|
||||
ld a, [rSVBK]
|
||||
ld b, a
|
||||
; wram bank 5
|
||||
ld a, 5
|
||||
ld a, $5
|
||||
ld [rSVBK], a
|
||||
|
||||
; push palette
|
||||
ld c, 4 ; NUM_PAL_COLORS
|
||||
ld c, NUM_PAL_COLORS
|
||||
.push
|
||||
ld d, [hl]
|
||||
inc hl
|
||||
|
@ -73,7 +72,7 @@ _TimeOfDayPals:: ; 8c011
|
|||
call GetSGBLayout
|
||||
|
||||
|
||||
; restore bg palette 8
|
||||
; restore bg palette 7
|
||||
ld hl, UnknOBPals - 1 ; last byte in UnknBGPals
|
||||
|
||||
; save wram bank
|
||||
|
@ -84,7 +83,7 @@ _TimeOfDayPals:: ; 8c011
|
|||
ld [rSVBK], a
|
||||
|
||||
; pop palette
|
||||
ld e, 4 ; NUM_PAL_COLORS
|
||||
ld e, NUM_PAL_COLORS
|
||||
.pop
|
||||
pop bc
|
||||
ld [hl], c
|
||||
|
|
|
@ -126,14 +126,14 @@ HealMachineAnim: ; 12324
|
|||
; 123dc
|
||||
|
||||
.PC_ElmsLab_OAM: ; 123dc
|
||||
dsprite 4, 0, 4, 2, $7c, $16
|
||||
dsprite 4, 0, 4, 6, $7c, $16
|
||||
dsprite 4, 6, 4, 0, $7d, $16
|
||||
dsprite 4, 6, 5, 0, $7d, $36 ; xflip
|
||||
dsprite 5, 3, 4, 0, $7d, $16
|
||||
dsprite 5, 3, 5, 0, $7d, $36 ; xflip
|
||||
dsprite 6, 0, 4, 0, $7d, $16
|
||||
dsprite 6, 0, 5, 0, $7d, $36 ; xflip
|
||||
dsprite 4, 0, 4, 2, $7c, PAL_OW_TREE | OBP_NUM
|
||||
dsprite 4, 0, 4, 6, $7c, PAL_OW_TREE | OBP_NUM
|
||||
dsprite 4, 6, 4, 0, $7d, PAL_OW_TREE | OBP_NUM
|
||||
dsprite 4, 6, 5, 0, $7d, PAL_OW_TREE | OBP_NUM | X_FLIP
|
||||
dsprite 5, 3, 4, 0, $7d, PAL_OW_TREE | OBP_NUM
|
||||
dsprite 5, 3, 5, 0, $7d, PAL_OW_TREE | OBP_NUM | X_FLIP
|
||||
dsprite 6, 0, 4, 0, $7d, PAL_OW_TREE | OBP_NUM
|
||||
dsprite 6, 0, 5, 0, $7d, PAL_OW_TREE | OBP_NUM | X_FLIP
|
||||
; 123fc
|
||||
|
||||
.HealMachineGFX: ; 123fc
|
||||
|
@ -141,12 +141,12 @@ INCBIN "gfx/overworld/heal_machine.2bpp"
|
|||
; 1241c
|
||||
|
||||
.HOF_OAM: ; 1241c
|
||||
dsprite 7, 4, 10, 1, $7d, $16
|
||||
dsprite 7, 4, 10, 6, $7d, $16
|
||||
dsprite 7, 3, 9, 5, $7d, $16
|
||||
dsprite 7, 3, 11, 2, $7d, $16
|
||||
dsprite 7, 1, 9, 1, $7d, $16
|
||||
dsprite 7, 1, 11, 5, $7d, $16
|
||||
dsprite 7, 4, 10, 1, $7d, PAL_OW_TREE | OBP_NUM
|
||||
dsprite 7, 4, 10, 6, $7d, PAL_OW_TREE | OBP_NUM
|
||||
dsprite 7, 3, 9, 5, $7d, PAL_OW_TREE | OBP_NUM
|
||||
dsprite 7, 3, 11, 2, $7d, PAL_OW_TREE | OBP_NUM
|
||||
dsprite 7, 1, 9, 1, $7d, PAL_OW_TREE | OBP_NUM
|
||||
dsprite 7, 1, 11, 5, $7d, PAL_OW_TREE | OBP_NUM
|
||||
; 12434
|
||||
|
||||
.LoadPalettes: ; 12434
|
||||
|
@ -158,8 +158,8 @@ INCBIN "gfx/overworld/heal_machine.2bpp"
|
|||
|
||||
.cgb
|
||||
ld hl, .palettes
|
||||
ld de, OBPals + 8 * 6
|
||||
ld bc, 8
|
||||
ld de, OBPals palette PAL_OW_TREE
|
||||
ld bc, 1 palettes
|
||||
ld a, $5
|
||||
call FarCopyWRAM
|
||||
ld a, $1
|
||||
|
@ -201,7 +201,7 @@ INCBIN "gfx/overworld/heal_machine.2bpp"
|
|||
ld a, $5
|
||||
ld [rSVBK], a
|
||||
|
||||
ld hl, OBPals + 8 * 6
|
||||
ld hl, OBPals palette PAL_OW_TREE
|
||||
ld a, [hli]
|
||||
ld e, a
|
||||
ld a, [hli]
|
||||
|
|
|
@ -246,7 +246,7 @@ CopyPals:: ; d50
|
|||
; copy c palettes in order b from de to hl
|
||||
|
||||
push bc
|
||||
ld c, 4 ; NUM_PAL_COLORS
|
||||
ld c, NUM_PAL_COLORS
|
||||
.loop
|
||||
push de
|
||||
push hl
|
||||
|
@ -280,7 +280,7 @@ CopyPals:: ; d50
|
|||
jr nz, .loop
|
||||
|
||||
; de += 8 (next pal)
|
||||
ld a, 1 palettes ; NUM_PAL_COLORS * 2 ; bytes per pal
|
||||
ld a, NUM_PAL_COLORS * 2
|
||||
add e
|
||||
jr nc, .ok
|
||||
inc d
|
||||
|
|
|
@ -631,8 +631,8 @@ Function8949c: ; 8949c
|
|||
ld a, 5
|
||||
ld [rSVBK], a
|
||||
ld hl, Palette_894b3
|
||||
ld de, UnknBGPals + 8 * 7
|
||||
ld bc, 8
|
||||
ld de, UnknBGPals palette 7
|
||||
ld bc, 1 palettes
|
||||
call CopyBytes
|
||||
pop af
|
||||
ld [rSVBK], a
|
||||
|
|
|
@ -63,7 +63,7 @@ LoadPokeComPalette: ; 494f2
|
|||
; 49501
|
||||
|
||||
PokeComPalette: ; 49501
|
||||
INCLUDE "tilesets/palettes/pokecom_center.pal"
|
||||
INCLUDE "data/palettes/tilesets/pokecom_center.pal"
|
||||
; 49541
|
||||
|
||||
LoadBattleTowerPalette: ; 49541
|
||||
|
@ -76,7 +76,7 @@ LoadBattleTowerPalette: ; 49541
|
|||
; 49550
|
||||
|
||||
BattleTowerPalette: ; 49550
|
||||
INCLUDE "tilesets/palettes/battle_tower.pal"
|
||||
INCLUDE "data/palettes/tilesets/battle_tower.pal"
|
||||
; 49590
|
||||
|
||||
LoadIcePathPalette: ; 49590
|
||||
|
@ -89,7 +89,7 @@ LoadIcePathPalette: ; 49590
|
|||
; 4959f
|
||||
|
||||
IcePathPalette: ; 4959f
|
||||
INCLUDE "tilesets/palettes/ice_path.pal"
|
||||
INCLUDE "data/palettes/tilesets/ice_path.pal"
|
||||
; 495df
|
||||
|
||||
LoadHousePalette: ; 495df
|
||||
|
@ -102,7 +102,7 @@ LoadHousePalette: ; 495df
|
|||
; 495ee
|
||||
|
||||
HousePalette: ; 495ee
|
||||
INCLUDE "tilesets/palettes/house_1.pal"
|
||||
INCLUDE "data/palettes/tilesets/house_1.pal"
|
||||
; 4962e
|
||||
|
||||
LoadRadioTowerPalette: ; 4962e
|
||||
|
@ -115,7 +115,7 @@ LoadRadioTowerPalette: ; 4962e
|
|||
; 4963d
|
||||
|
||||
RadioTowerPalette: ; 4963d
|
||||
INCLUDE "tilesets/palettes/radio_tower.pal"
|
||||
INCLUDE "data/palettes/tilesets/radio_tower.pal"
|
||||
; 4967d
|
||||
|
||||
MansionPalette1: ; 4967d
|
||||
|
|
Loading…
Reference in New Issue