Skip to content

Commit

Permalink
Remaining layout constants
Browse files Browse the repository at this point in the history
  • Loading branch information
PikalaxALT committed Jun 6, 2016
1 parent 789ebc7 commit d7a01e9
Show file tree
Hide file tree
Showing 28 changed files with 83 additions and 77 deletions.
2 changes: 1 addition & 1 deletion battle/core.asm
Original file line number Diff line number Diff line change
Expand Up @@ -8916,7 +8916,7 @@ DisplayLinkRecord: ; 3f836
ld bc, SCREEN_WIDTH * SCREEN_HEIGHT
call ByteFill
call WaitBGMap2
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call SetPalettes
ld c, 8
Expand Down
2 changes: 1 addition & 1 deletion battle/trainer_huds.asm
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ _ShowLinkBattleParticipants: ; 2c1b2
ld [hli], a
ld [hl], $6a ; "S"
callba LinkBattle_TrainerHuds ; no need to callba
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call SetPalettes
ld a, $e4
Expand Down
14 changes: 7 additions & 7 deletions constants/cgb_constants.asm
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@
const SCGB_SLOT_MACHINE
const SCGB_06
const SCGB_07
const SCGB_08
const SCGB_DIPLOMA
const SCGB_MAPPALS
const SCGB_0A
const SCGB_0B
const SCGB_PARTY_MENU
const SCGB_EVOLUTION
const SCGB_0C
const SCGB_0D
const SCGB_0E
const SCGB_MOVE_LIST
const SCGB_0F
const SCGB_POKEDEX_SEARCH_OPTION
const SCGB_11
Expand All @@ -22,13 +22,13 @@
const SCGB_PACKPALS
const SCGB_TRAINER_CARD
const SCGB_POKEDEX_UNOWN_MODE
const SCGB_17
const SCGB_18
const SCGB_BILLS_PC
const SCGB_UNOWN_PUZZLE
const SCGB_GAMEFREAK_LOGO
const SCGB_PLAYER_OR_MON_FRONTPIC_PALS
const SCGB_TRADE_TUBE
const SCGB_TRAINER_OR_MON_FRONTPIC_PALS
const SCGB_1D
const SCGB_MYSTERY_GIFT
const SCGB_1E

SCGB_PARTY_MENU_HP_PALS EQU -4
Expand Down
18 changes: 9 additions & 9 deletions engine/billspc.asm
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ _DepositPKMN: ; e2391 (38:6391)
call PCMonInfo
ld a, $ff
ld [CurPartySpecies], a
ld a, SCGB_17
ld a, SCGB_BILLS_PC
call BillsPC_ApplyPalettes
call WaitBGMap
call BillsPC_UpdateSelectionCursor
Expand Down Expand Up @@ -120,7 +120,7 @@ _DepositPKMN: ; e2391 (38:6391)
call ClearSprites
call BillsPC_GetSelectedPokemonSpecies
ld [CurPartySpecies], a
ld a, SCGB_17
ld a, SCGB_BILLS_PC
call BillsPC_ApplyPalettes
ld de, PCString_WhatsUp
call BillsPC_PlaceString
Expand Down Expand Up @@ -181,7 +181,7 @@ BillsPCDepositFuncStats: ; e24c8 (38:64c8)
call PCMonInfo
call BillsPC_GetSelectedPokemonSpecies
ld [CurPartySpecies], a
ld a, SCGB_17
ld a, SCGB_BILLS_PC
call BillsPC_ApplyPalettes
ret

Expand Down Expand Up @@ -333,7 +333,7 @@ _WithdrawPKMN: ; e2583 (38:6583)
call PCMonInfo
ld a, $ff
ld [CurPartySpecies], a
ld a, SCGB_17
ld a, SCGB_BILLS_PC
call BillsPC_ApplyPalettes
call WaitBGMap
call BillsPC_UpdateSelectionCursor
Expand Down Expand Up @@ -388,7 +388,7 @@ _WithdrawPKMN: ; e2583 (38:6583)
call ClearSprites
call BillsPC_GetSelectedPokemonSpecies
ld [CurPartySpecies], a
ld a, SCGB_17
ld a, SCGB_BILLS_PC
call BillsPC_ApplyPalettes
ld de, PCString_WhatsUp
call BillsPC_PlaceString
Expand Down Expand Up @@ -447,7 +447,7 @@ BillsPC_Withdraw: ; e2675 (38:6675)
call PCMonInfo
call BillsPC_GetSelectedPokemonSpecies
ld [CurPartySpecies], a
ld a, SCGB_17
ld a, SCGB_BILLS_PC
call BillsPC_ApplyPalettes
ret

Expand Down Expand Up @@ -584,7 +584,7 @@ _MovePKMNWithoutMail: ; e2759
call PCMonInfo
ld a, $ff
ld [CurPartySpecies], a
ld a, SCGB_17
ld a, SCGB_BILLS_PC
call BillsPC_ApplyPalettes
call WaitBGMap
call BillsPC_UpdateSelectionCursor
Expand Down Expand Up @@ -650,7 +650,7 @@ _MovePKMNWithoutMail: ; e2759
call ClearSprites
call BillsPC_GetSelectedPokemonSpecies
ld [CurPartySpecies], a
ld a, SCGB_17
ld a, SCGB_BILLS_PC
call BillsPC_ApplyPalettes
ld de, PCString_WhatsUp
call BillsPC_PlaceString
Expand Down Expand Up @@ -708,7 +708,7 @@ _MovePKMNWithoutMail: ; e2759
call PCMonInfo
call BillsPC_GetSelectedPokemonSpecies
ld [CurPartySpecies], a
ld a, SCGB_17
ld a, SCGB_BILLS_PC
call BillsPC_ApplyPalettes
ret
; e28bd
Expand Down
2 changes: 1 addition & 1 deletion engine/breeding/egg.asm
Original file line number Diff line number Diff line change
Expand Up @@ -786,7 +786,7 @@ EggHatch_AnimationSequence: ; 1728f (5:728f)

Hatch_LoadFrontpicPal: ; 17363 (5:7363)
ld [PlayerHPPal], a
ld b, SCGB_0B
ld b, SCGB_EVOLUTION
ld c, $0
jp GetSGBLayout

Expand Down
2 changes: 1 addition & 1 deletion engine/color.asm
Original file line number Diff line number Diff line change
Expand Up @@ -2035,7 +2035,7 @@ INCLUDE "tilesets/ob.pal"
RoofPals:
INCLUDE "tilesets/roof.pal"

Palettes_b641:
DiplomaPalettes:
RGB 27, 31, 27
RGB 21, 21, 21
RGB 13, 13, 13
Expand Down
4 changes: 2 additions & 2 deletions engine/delete_save_change_clock.asm
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
_ResetClock: ; 4d3b1
callba BlankScreen
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call LoadStandardFont
call LoadFontsExtra
Expand Down Expand Up @@ -261,7 +261,7 @@ ClockResetPassword: ; 4d41e

_DeleteSaveData: ; 4d54c
callba BlankScreen
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call LoadStandardFont
call LoadFontsExtra
Expand Down
2 changes: 1 addition & 1 deletion engine/diploma.asm
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ PlaceDiplomaOnScreen: ; 1dd709
call PlaceString
call EnableLCD
call WaitBGMap
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call SetPalettes
call DelayFrame
Expand Down
2 changes: 1 addition & 1 deletion engine/dummy_game.asm
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ _DummyGame: ; e1e5b (38:5e5b)

.LoadGFXAndPals:
call DisableLCD
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
callab ClearSpriteAnims
ld hl, LZ_e2221
Expand Down
2 changes: 1 addition & 1 deletion engine/evolution_animation.asm
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ EvolutionAnimation: ; 4e5e1
; 4e703

.GetSGBLayout: ; 4e703
ld b, SCGB_0B
ld b, SCGB_EVOLUTION
jp GetSGBLayout
; 4e708

Expand Down
2 changes: 1 addition & 1 deletion engine/intro_menu.asm
Original file line number Diff line number Diff line change
Expand Up @@ -1048,7 +1048,7 @@ StartTitleScreen: ; 6219
ld [hWX], a
ld a, $90
ld [hWY], a
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call UpdateTimePals
ld a, [wcf64]
Expand Down
6 changes: 3 additions & 3 deletions engine/link.asm
Original file line number Diff line number Diff line change
Expand Up @@ -498,7 +498,7 @@ LinkTimeout: ; 283b2
call PlaceHLTextAtBC
call RotateThreePalettesRight
call ClearScreen
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call WaitBGMap2
ret
Expand Down Expand Up @@ -1597,7 +1597,7 @@ Function28ade: ; 28ade
Function28b22: ; 28b22
call RotateThreePalettesRight
call ClearScreen
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call WaitBGMap2
xor a
Expand Down Expand Up @@ -1902,7 +1902,7 @@ LinkTrade: ; 28b87
call DelayFrames
call ClearTileMap
call LoadFontsBattleExtra
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
ld a, [hLinkPlayerNumber]
cp $1
Expand Down
2 changes: 1 addition & 1 deletion engine/link_trade.asm
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Function16d43b: ; 16d43b
call ClearSprites
callba __LoadTradeScreenBorder ; useless to farcall
callba Function16d42e ; useless to farcall
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call SetPalettes
call WaitBGMap
Expand Down
2 changes: 1 addition & 1 deletion engine/main_menu.asm
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ MainMenu: ; 49cdc
xor a
ld [wDisableTextAcceleration], a
call Function49ed0
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call SetPalettes
ld hl, GameTimerPause
Expand Down
6 changes: 3 additions & 3 deletions engine/mysterygift.asm
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ DoMysteryGift: ; 1048ba (41:48ba)
call ClearTileMap
call EnableLCD
call WaitBGMap
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call SetPalettes
pop de
Expand Down Expand Up @@ -1333,7 +1333,7 @@ Function105153: ; 105153 (41:5153)
ld [hl], $41
call EnableLCD
call WaitBGMap
ld b, SCGB_1D
ld b, SCGB_MYSTERY_GIFT
call GetSGBLayout
call SetPalettes
ret
Expand Down Expand Up @@ -1511,7 +1511,7 @@ Function105777: ; 105777 (41:5777)
call ClearTileMap
call EnableLCD
call WaitBGMap
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call SetPalettes
ret
Expand Down
4 changes: 2 additions & 2 deletions engine/namingscreen.asm
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ NamingScreen: ; 116c1

.SetUpNamingScreen: ; 116f8
call ClearBGPalettes
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call DisableLCD
call LoadNamingScreenGFX
Expand Down Expand Up @@ -1049,7 +1049,7 @@ _ComposeMailMessage: ; 11e75 (mail?)
ld a, $e3
ld [rLCDC], a
call .initwNamingScreenMaxNameLength
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call WaitBGMap
call WaitTop
Expand Down
2 changes: 1 addition & 1 deletion engine/options_menu.asm
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ _OptionsMenu: ; e41d0
inc a
ld [hBGMapMode], a
call WaitBGMap
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call SetPalettes

Expand Down
4 changes: 2 additions & 2 deletions engine/party_menu.asm
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ SelectTradeOrDaycareMon: ; 5001d
call ClearBGPalettes
call InitPartyMenuLayout
call WaitBGMap
ld b, SCGB_0A
ld b, SCGB_PARTY_MENU
call GetSGBLayout
call SetPalettes
call DelayFrame
Expand Down Expand Up @@ -160,7 +160,7 @@ PlacePartyHPBar: ; 500cf
inc b
dec c
jr nz, .loop
ld b, SCGB_0A
ld b, SCGB_PARTY_MENU
call GetSGBLayout
ret
; 50117
Expand Down
2 changes: 1 addition & 1 deletion engine/startmenu.asm
Original file line number Diff line number Diff line change
Expand Up @@ -1797,7 +1797,7 @@ SetUpMoveScreenBG: ; 13172
call PrintLevel
ld hl, PlayerHPPal
call SetHPPal
ld b, SCGB_0E
ld b, SCGB_MOVE_LIST
call GetSGBLayout
hlcoord 16, 0
lb bc, 1, 3
Expand Down
2 changes: 1 addition & 1 deletion engine/timeset.asm
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ InitClock: ; 90672 (24:4672)
call RotateFourPalettesLeft
call ClearTileMap
call ClearSprites
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
xor a
ld [hBGMapMode], a
Expand Down
2 changes: 1 addition & 1 deletion engine/unown_puzzle.asm
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ UnownPuzzle: ; e1190
ld a, $93
ld [rLCDC], a
call WaitBGMap
ld b, SCGB_18
ld b, SCGB_UNOWN_PUZZLE
call GetSGBLayout
ld a, $e4
call DmgToCgbBGPals
Expand Down
2 changes: 1 addition & 1 deletion home/map.asm
Original file line number Diff line number Diff line change
Expand Up @@ -1382,7 +1382,7 @@ UpdateBGMapColumn:: ; 27f8

; unreferenced
ld hl, BGMapBuffer
ld bc, SGBPredef - BGMapBuffer
ld bc, BGMapBufferEnd - BGMapBuffer
xor a
call ByteFill
ret
Expand Down
2 changes: 1 addition & 1 deletion main.asm
Original file line number Diff line number Diff line change
Expand Up @@ -5227,7 +5227,7 @@ DisplayCaughtContestMonStats: ; cc000
ld [Options], a

call WaitBGMap
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
call SetPalettes
ret
Expand Down
2 changes: 1 addition & 1 deletion misc/mobile_12.asm
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ Function4820d: ; 4820d (12:420d)
call Function48d30
pop bc
call ClearTileMap
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
ld hl, wd479
set 1, [hl]
Expand Down
2 changes: 1 addition & 1 deletion misc/mobile_menu.asm
Original file line number Diff line number Diff line change
Expand Up @@ -845,7 +845,7 @@ Function4a6ab: ; 4a6ab (12:66ab)
ld a, $2
call MenuClickSound
call ClearBGPalettes
ld b, SCGB_08
ld b, SCGB_DIPLOMA
call GetSGBLayout
callba Function11c1ab
pop bc
Expand Down
Loading

0 comments on commit d7a01e9

Please sign in to comment.