diff --git a/constants/map_data_constants.asm b/constants/map_data_constants.asm index 1d3e6011..11148d62 100644 --- a/constants/map_data_constants.asm +++ b/constants/map_data_constants.asm @@ -29,7 +29,7 @@ DEF MAP_LENGTH EQU _RS const DUNGEON DEF NUM_ENVIRONMENTS EQU const_value - 1 -; map palettes (wEnvironment) +; map palettes (wMapTimeOfDay) const_def const PALETTE_AUTO const PALETTE_DAY diff --git a/constants/wram_constants.asm b/constants/wram_constants.asm index 2eb93ba9..915d1ebd 100644 --- a/constants/wram_constants.asm +++ b/constants/wram_constants.asm @@ -55,7 +55,7 @@ DEF NUM_FRAMES EQU const_value ; wTextboxFlags:: const_def const FAST_TEXT_DELAY_F ; 0 - const NO_TEXT_DELAY_F ; 1 + const TEXT_DELAY_F ; 1 ; wGBPrinterBrightness:: DEF GBPRINTER_LIGHTEST EQU $00 diff --git a/data/events/special_pointers.asm b/data/events/special_pointers.asm index b742b9e3..4c4cc5ae 100644 --- a/data/events/special_pointers.asm +++ b/data/events/special_pointers.asm @@ -62,10 +62,10 @@ SpecialsPointers:: add_special CardFlip add_special UnusedMemoryGame ; unused add_special ClearBGPalettesBufferScreen ; unused - add_special FadeOutPalettes - add_special FadeBlackQuickly - add_special FadeInPalettes - add_special FadeInQuickly + add_special FadeOutToWhite + add_special FadeOutToBlack + add_special FadeInFromWhite + add_special FadeInFromBlack add_special ReloadSpritesNoPalettes, 2 add_special ClearBGPalettes add_special UpdateTimePals diff --git a/data/maps/setup_script_pointers.asm b/data/maps/setup_script_pointers.asm index 2d7e49ab..463d61dc 100644 --- a/data/maps/setup_script_pointers.asm +++ b/data/maps/setup_script_pointers.asm @@ -33,8 +33,8 @@ MapSetupCommands: add_mapsetup LoadMapAttributes ; 1a add_mapsetup LoadMapAttributes_SkipObjects ; 1b add_mapsetup ClearBGPalettes ; 1c - add_mapsetup FadeOutPalettes ; 1d - add_mapsetup FadeInPalettes ; 1e + add_mapsetup FadeOutToWhite ; 1d + add_mapsetup FadeInFromWhite ; 1e add_mapsetup GetMapScreenCoords ; 1f add_mapsetup GetWarpDestCoords ; 20 add_mapsetup SpawnInFacingDown ; 21 diff --git a/data/maps/setup_scripts.asm b/data/maps/setup_scripts.asm index 48216413..b6079331 100644 --- a/data/maps/setup_scripts.asm +++ b/data/maps/setup_scripts.asm @@ -20,7 +20,7 @@ MACRO mapsetup ENDM MapSetupScript_Teleport: - mapsetup FadeOutPalettes + mapsetup FadeOutToWhite mapsetup ResetPlayerObjectAction mapsetup JumpRoamMons MapSetupScript_Warp: @@ -43,7 +43,7 @@ MapSetupScript_Warp: mapsetup RefreshMapSprites mapsetup PlayMapMusicBike mapsetup FadeInToMusic - mapsetup FadeInPalettes + mapsetup FadeInFromWhite mapsetup ActivateMapAnims mapsetup LoadWildMonData db -1 ; end @@ -67,7 +67,7 @@ MapSetupScript_BadWarp: mapsetup SpawnInFacingDown mapsetup RefreshMapSprites mapsetup FadeToMapMusic - mapsetup FadeInPalettes + mapsetup FadeInFromWhite mapsetup ActivateMapAnims mapsetup LoadWildMonData db -1 ; end @@ -93,7 +93,7 @@ MapSetupScript_Connection: MapSetupScript_Fall: mapsetup ResetPlayerObjectAction MapSetupScript_Door: - mapsetup FadeOutPalettes + mapsetup FadeOutToWhite MapSetupScript_Train: mapsetup EnterMapWarp mapsetup LoadMapAttributes @@ -111,7 +111,7 @@ MapSetupScript_Train: mapsetup LoadMapPalettes mapsetup RefreshMapSprites mapsetup FadeToMapMusic - mapsetup FadeInPalettes + mapsetup FadeInFromWhite mapsetup ActivateMapAnims mapsetup LoadWildMonData mapsetup UpdateRoamMons @@ -130,7 +130,7 @@ MapSetupScript_ReloadMap: mapsetup LoadMapPalettes mapsetup RefreshMapSprites mapsetup ForceMapMusic - mapsetup FadeInPalettes + mapsetup FadeInFromWhite mapsetup ActivateMapAnims mapsetup LoadWildMonData db -1 ; end @@ -148,7 +148,7 @@ MapSetupScript_LinkReturn: mapsetup LoadMapPalettes mapsetup RefreshMapSprites mapsetup PlayMapMusicBike - mapsetup FadeInPalettes + mapsetup FadeInFromWhite mapsetup ActivateMapAnims mapsetup LoadWildMonData mapsetup EnableTextAcceleration @@ -169,7 +169,7 @@ MapSetupScript_Continue: mapsetup LoadMapPalettes mapsetup RefreshMapSprites mapsetup PlayMapMusicBike - mapsetup FadeInPalettes + mapsetup FadeInFromWhite mapsetup ActivateMapAnims mapsetup LoadWildMonData db -1 ; end diff --git a/engine/battle/core.asm b/engine/battle/core.asm index ff135df4..271edc9e 100644 --- a/engine/battle/core.asm +++ b/engine/battle/core.asm @@ -2637,7 +2637,7 @@ ForcePlayerMonChoice: call LoadTilemapToTempTilemap call WaitBGMap call GetMemSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP xor a ret @@ -2655,7 +2655,7 @@ ForcePlayerMonChoice: call _LoadHPBar call CloseWindow call GetMemSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP call SendOutMonText call NewBattleMonStatus call BreakAttraction @@ -2699,7 +2699,7 @@ PickPartyMonInBattle: farcall WritePartyMenuTilemap farcall PrintPartyMenuText call WaitBGMap - call SetPalettes + call SetDefaultBGPAndOBP call DelayFrame farcall PartyMenuSelect ret c @@ -2786,7 +2786,7 @@ LostBattle: ; Grayscale ld b, SCGB_BATTLE_GRAYSCALE call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP jr .end .LostLinkBattle: @@ -4774,7 +4774,7 @@ BattleMenu_Pack: and BATTLERESULT_BITMASK ld [wBattleResult], a ; WIN call ClearWindowData - call SetPalettes + call SetDefaultBGPAndOBP scf ret @@ -4793,7 +4793,7 @@ BattleMenuPKMN_Loop: farcall WritePartyMenuTilemap farcall PrintPartyMenuText call WaitBGMap - call SetPalettes + call SetDefaultBGPAndOBP call DelayFrame farcall PartyMenuSelect jr c, .Cancel @@ -4823,7 +4823,7 @@ BattleMenuPKMN_Loop: call CloseWindow call LoadTilemapToTempTilemap call GetMemSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP jp BattleMenu Battle_StatsScreen: @@ -4900,7 +4900,7 @@ TryPlayerSwitch: call _LoadHPBar call CloseWindow call GetMemSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP ld a, [wCurPartyMon] ld [wCurBattleMon], a PlayerSwitch: @@ -6727,7 +6727,7 @@ FinishBattleAnim: push hl ld b, SCGB_BATTLE_COLORS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP call DelayFrame pop hl pop de @@ -8093,7 +8093,7 @@ _DisplayLinkRecord: call WaitBGMap2 ld b, SCGB_DIPLOMA call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP ld c, 8 call DelayFrames call WaitPressAorB_BlinkCursor @@ -8568,7 +8568,7 @@ InitBattleDisplay: call HideSprites ld b, SCGB_BATTLE_COLORS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP ld a, $90 ldh [hWY], a xor a diff --git a/engine/battle/move_effects/baton_pass.asm b/engine/battle/move_effects/baton_pass.asm index caa7272d..1e6a9638 100644 --- a/engine/battle/move_effects/baton_pass.asm +++ b/engine/battle/move_effects/baton_pass.asm @@ -29,7 +29,7 @@ BattleCommand_BatonPass: call ClearBox ld b, SCGB_BATTLE_COLORS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP call BatonPass_LinkPlayerSwitch ld hl, PassedBattleMonEntrance diff --git a/engine/battle/returntobattle_useball.asm b/engine/battle/returntobattle_useball.asm index fd138ae6..0b8ed0d6 100644 --- a/engine/battle/returntobattle_useball.asm +++ b/engine/battle/returntobattle_useball.asm @@ -16,4 +16,4 @@ _ReturnToBattle_UseBall: call CloseWindow call LoadStandardMenuHeader call WaitBGMap - jp SetPalettes + jp SetDefaultBGPAndOBP diff --git a/engine/battle/trainer_huds.asm b/engine/battle/trainer_huds.asm index 248d0cfe..4fdb8989 100644 --- a/engine/battle/trainer_huds.asm +++ b/engine/battle/trainer_huds.asm @@ -251,7 +251,7 @@ _ShowLinkBattleParticipants: farcall LinkBattle_TrainerHuds ; no need to farcall ld b, SCGB_DIPLOMA call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP ld a, $e4 ldh [rOBP0], a ld c, 150 diff --git a/engine/debug/color_picker.asm b/engine/debug/color_picker.asm index 0d238556..0c54bd0f 100644 --- a/engine/debug/color_picker.asm +++ b/engine/debug/color_picker.asm @@ -1065,7 +1065,7 @@ TilesetColorPicker: ; unreferenced ld [wDebugTilesetCurColor], a ldh [hMapAnims], a call ClearSprites - call OverworldTextModeSwitch + call LoadOverworldTilemapAndAttrmapPals call WaitBGMap2 xor a ldh [hBGMapMode], a diff --git a/engine/debug/debug_room.asm b/engine/debug/debug_room.asm index 319f5dc6..ab6e7b59 100644 --- a/engine/debug/debug_room.asm +++ b/engine/debug/debug_room.asm @@ -421,7 +421,7 @@ DebugRoom_EditPagedValues: call WaitBGMap ld b, SCGB_DIPLOMA call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP .resume call DelayFrame call JoyTextDelay diff --git a/engine/events/bug_contest/display_stats.asm b/engine/events/bug_contest/display_stats.asm index 498b33bc..8a2d518f 100644 --- a/engine/events/bug_contest/display_stats.asm +++ b/engine/events/bug_contest/display_stats.asm @@ -76,7 +76,7 @@ DisplayCaughtContestMonStats: call WaitBGMap ld b, SCGB_DIPLOMA call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP ret .Health: diff --git a/engine/events/diploma.asm b/engine/events/diploma.asm index 9147015c..a7e0b152 100644 --- a/engine/events/diploma.asm +++ b/engine/events/diploma.asm @@ -37,7 +37,7 @@ PlaceDiplomaOnScreen: call WaitBGMap ld b, SCGB_DIPLOMA call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP call DelayFrame ret diff --git a/engine/events/field_moves.asm b/engine/events/field_moves.asm index f0997418..494a3b43 100644 --- a/engine/events/field_moves.asm +++ b/engine/events/field_moves.asm @@ -10,14 +10,14 @@ PlayWhirlpoolSound: ret BlindingFlash: - farcall FadeOutPalettes + farcall FadeOutToWhite ld hl, wStatusFlags set STATUSFLAGS_FLASH_F, [hl] farcall ReplaceTimeOfDayPals farcall UpdateTimeOfDayPal ld b, SCGB_MAPPALS call GetSGBLayout - farcall FadeInPalettes + farcall FadeInFromWhite ret ShakeHeadbuttTree: @@ -58,7 +58,7 @@ ShakeHeadbuttTree: jr .loop .done - call OverworldTextModeSwitch + call LoadOverworldTilemapAndAttrmapPals call WaitBGMap xor a ldh [hBGMapMode], a diff --git a/engine/events/halloffame.asm b/engine/events/halloffame.asm index 7f1b2b88..c53880be 100644 --- a/engine/events/halloffame.asm +++ b/engine/events/halloffame.asm @@ -39,7 +39,7 @@ RedCredits:: ld [wMusicFadeID + 1], a ld a, 10 ld [wMusicFade], a - farcall FadeOutPalettes + farcall FadeOutToWhite xor a ld [wVramState], a ldh [hMapAnims], a @@ -59,7 +59,7 @@ HallOfFame_FadeOutMusic: ld [wMusicFadeID + 1], a ld a, 10 ld [wMusicFade], a - farcall FadeOutPalettes + farcall FadeOutToWhite xor a ld [wVramState], a ldh [hMapAnims], a @@ -250,7 +250,7 @@ AnimateHOFMonEntrance: ldh [hBGMapMode], a ld b, SCGB_PLAYER_OR_MON_FRONTPIC_PALS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP call HOF_SlideBackpic xor a ld [wBoxAlignment], a @@ -383,7 +383,7 @@ _HallOfFamePC: call WaitBGMap ld b, SCGB_PLAYER_OR_MON_FRONTPIC_PALS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP ld a, [wCurPartySpecies] call PlayMonCry and a @@ -545,7 +545,7 @@ HOF_AnimatePlayerPic: ld [wCurPartySpecies], a ld b, SCGB_PLAYER_OR_MON_FRONTPIC_PALS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP call HOF_SlideBackpic xor a ld [wBoxAlignment], a diff --git a/engine/events/overworld.asm b/engine/events/overworld.asm index 68e0090b..8fe3e08a 100644 --- a/engine/events/overworld.asm +++ b/engine/events/overworld.asm @@ -220,7 +220,7 @@ CutDownTreeOrGrass: ld [hl], a xor a ldh [hBGMapMode], a - call OverworldTextModeSwitch + call LoadOverworldTilemapAndAttrmapPals call UpdateSprites call DelayFrame ld a, [wCutWhirlpoolAnimationType] @@ -1156,7 +1156,7 @@ DisappearWhirlpool: ld [hl], a xor a ldh [hBGMapMode], a - call OverworldTextModeSwitch + call LoadOverworldTilemapAndAttrmapPals ld a, [wCutWhirlpoolAnimationType] ld e, a farcall PlayWhirlpoolSound diff --git a/engine/events/pokecenter_pc.asm b/engine/events/pokecenter_pc.asm index d2e6ca83..9ffb4361 100644 --- a/engine/events/pokecenter_pc.asm +++ b/engine/events/pokecenter_pc.asm @@ -212,7 +212,7 @@ _PlayersHousePC: call _PlayersPC and a jr nz, .changed_deco_tiles - call OverworldTextModeSwitch + call LoadOverworldTilemapAndAttrmapPals call ApplyTilemap call UpdateSprites call PC_PlayShutdownSound diff --git a/engine/events/pokepic.asm b/engine/events/pokepic.asm index 523c5df5..7050ef1c 100644 --- a/engine/events/pokepic.asm +++ b/engine/events/pokepic.asm @@ -35,7 +35,7 @@ ClosePokepic:: call GetMemSGBLayout xor a ldh [hBGMapMode], a - call OverworldTextModeSwitch + call LoadOverworldTilemapAndAttrmapPals call ApplyTilemap call UpdateSprites call LoadStandardFont diff --git a/engine/events/print_unown.asm b/engine/events/print_unown.asm index 89c08894..1c261d6e 100644 --- a/engine/events/print_unown.asm +++ b/engine/events/print_unown.asm @@ -64,7 +64,7 @@ _UnownPrinter: ld b, SCGB_TRAINER_OR_MON_FRONTPIC_PALS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP .joy_loop call JoyTextDelay diff --git a/engine/events/sacred_ash.asm b/engine/events/sacred_ash.asm index d105b2fb..83b16d60 100644 --- a/engine/events/sacred_ash.asm +++ b/engine/events/sacred_ash.asm @@ -49,12 +49,12 @@ SacredAshScript: special HealParty reloadmappart playsound SFX_WARP_TO - special FadeOutPalettes - special FadeInPalettes - special FadeOutPalettes - special FadeInPalettes - special FadeOutPalettes - special FadeInPalettes + special FadeOutToWhite + special FadeInFromWhite + special FadeOutToWhite + special FadeInFromWhite + special FadeOutToWhite + special FadeInFromWhite waitsfx writetext .UseSacredAshText playsound SFX_CAUGHT_MON diff --git a/engine/events/sweet_scent.asm b/engine/events/sweet_scent.asm index acc1f8a5..3981cadf 100644 --- a/engine/events/sweet_scent.asm +++ b/engine/events/sweet_scent.asm @@ -30,7 +30,7 @@ SweetScentNothing: end SweetScentEncounter: - farcall CanUseSweetScent + farcall CanEncounterWildMonInThisTile jr nc, .no_battle ld hl, wStatusFlags2 bit STATUSFLAGS2_BUG_CONTEST_TIMER_F, [hl] diff --git a/engine/events/whiteout.asm b/engine/events/whiteout.asm index 4b4ff375..e42c9ae0 100644 --- a/engine/events/whiteout.asm +++ b/engine/events/whiteout.asm @@ -9,7 +9,7 @@ OverworldWhiteoutScript:: Script_Whiteout: writetext .WhitedOutText waitbutton - special FadeOutPalettes + special FadeOutToWhite pause 40 special HealParty checkflag ENGINE_BUG_CONTEST_TIMER @@ -39,7 +39,7 @@ OverworldBGMap: BattleBGMap: ld b, SCGB_BATTLE_GRAYSCALE call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP ret HalveMoney: diff --git a/engine/gfx/cgb_layouts.asm b/engine/gfx/cgb_layouts.asm index 005cf5b0..45eb912e 100644 --- a/engine/gfx/cgb_layouts.asm +++ b/engine/gfx/cgb_layouts.asm @@ -29,6 +29,7 @@ LoadSGBLayoutCGB: ret CGBLayoutJumptable: +; entries correspond to SCGB_* constants (see constants/scgb_constants.asm) table_width 2, CGBLayoutJumptable dw _CGB_BattleGrayscale dw _CGB_BattleColors @@ -741,7 +742,7 @@ INCLUDE "gfx/pack/pack.pal" _CGB_Pokepic: call _CGB_MapPals - call SwapTextboxPalettes + call LoadOverworldAttrmapPals ld de, SCREEN_WIDTH hlcoord 0, 0, wAttrmap ld a, [wMenuBorderTopCoord] diff --git a/engine/gfx/color.asm b/engine/gfx/color.asm index 7c5a086d..22ccec5d 100644 --- a/engine/gfx/color.asm +++ b/engine/gfx/color.asm @@ -1126,7 +1126,7 @@ INCLUDE "data/trainers/palettes.asm" LoadMapPals: ; Which palette group is based on whether we're outside or inside ld a, [wEnvironment] - and 7 + maskbits NUM_ENVIRONMENTS + 1 ld e, a ld d, 0 ld hl, EnvironmentColorsPointers diff --git a/engine/gfx/sgb_layouts.asm b/engine/gfx/sgb_layouts.asm index bdc0a77d..51a05e9a 100644 --- a/engine/gfx/sgb_layouts.asm +++ b/engine/gfx/sgb_layouts.asm @@ -22,6 +22,7 @@ LoadSGBLayout: jp hl SGBLayoutJumptable: +; entries correspond to SCGB_* constants (see constants/scgb_constants.asm) table_width 2, SGBLayoutJumptable dw .SGB_BattleGrayscale dw .SGB_BattleColors diff --git a/engine/items/item_effects.asm b/engine/items/item_effects.asm index 911e073c..6677dded 100644 --- a/engine/items/item_effects.asm +++ b/engine/items/item_effects.asm @@ -1716,7 +1716,7 @@ ChooseMonToUseItemOn: farcall WritePartyMenuTilemap farcall PrintPartyMenuText call WaitBGMap - call SetPalettes + call SetDefaultBGPAndOBP call DelayFrame farcall PartyMenuSelect ret @@ -1733,7 +1733,7 @@ ItemActionText: farcall WritePartyMenuTilemap farcall PrintPartyMenuActionText call WaitBGMap - call SetPalettes + call SetDefaultBGPAndOBP call DelayFrame pop bc pop de diff --git a/engine/items/pack.asm b/engine/items/pack.asm index e166249a..a4825501 100644 --- a/engine/items/pack.asm +++ b/engine/items/pack.asm @@ -574,7 +574,7 @@ GiveItem: farcall WritePartyMenuTilemap farcall PrintPartyMenuText call WaitBGMap - call SetPalettes + call SetDefaultBGPAndOBP call DelayFrame farcall PartyMenuSelect jr c, .finish @@ -1426,7 +1426,7 @@ Pack_InitColors: call WaitBGMap ld b, SCGB_PACKPALS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP call DelayFrame ret diff --git a/engine/items/tmhm.asm b/engine/items/tmhm.asm index b9a4ec9e..b8717480 100644 --- a/engine/items/tmhm.asm +++ b/engine/items/tmhm.asm @@ -85,7 +85,7 @@ ChooseMonToLearnTMHM: farcall WritePartyMenuTilemap farcall PrintPartyMenuText call WaitBGMap - call SetPalettes + call SetDefaultBGPAndOBP call DelayFrame farcall PartyMenuSelect push af diff --git a/engine/link/link.asm b/engine/link/link.asm index 38dd5078..3fdd12e9 100644 --- a/engine/link/link.asm +++ b/engine/link/link.asm @@ -1950,7 +1950,7 @@ LoadTradeScreenBorderGFX: SetTradeRoomBGPals: ld b, SCGB_DIPLOMA call GetSGBLayout - jp SetPalettes + jp SetDefaultBGPAndOBP PlaceTradeScreenTextbox: hlcoord 0, 0 diff --git a/engine/link/mystery_gift.asm b/engine/link/mystery_gift.asm index a72d6ab6..89b826b8 100644 --- a/engine/link/mystery_gift.asm +++ b/engine/link/mystery_gift.asm @@ -64,7 +64,7 @@ endc call WaitBGMap ld b, SCGB_DIPLOMA call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP pop de hlcoord 2, 8 diff --git a/engine/link/mystery_gift_3.asm b/engine/link/mystery_gift_3.asm index 4a8d92c4..e92b3cfb 100644 --- a/engine/link/mystery_gift_3.asm +++ b/engine/link/mystery_gift_3.asm @@ -139,7 +139,7 @@ InitMysteryGiftLayout: call WaitBGMap ld b, SCGB_MYSTERY_GIFT call GetSGBLayout - jp SetPalettes + jp SetDefaultBGPAndOBP .Load3GFX: ld b, 3 diff --git a/engine/menus/menu.asm b/engine/menus/menu.asm index 8acc27f2..94acac6e 100644 --- a/engine/menus/menu.asm +++ b/engine/menus/menu.asm @@ -576,7 +576,7 @@ RestoreOverworldMapTiles: ld bc, SCREEN_WIDTH * SCREEN_HEIGHT call CopyBytes call CloseSRAM - call OverworldTextModeSwitch + call LoadOverworldTilemapAndAttrmapPals xor a ; sScratch call OpenSRAM ld hl, sScratch diff --git a/engine/menus/naming_screen.asm b/engine/menus/naming_screen.asm index 0e1b06cc..c904f58b 100644 --- a/engine/menus/naming_screen.asm +++ b/engine/menus/naming_screen.asm @@ -55,7 +55,7 @@ NamingScreen: call .GetNamingScreenSetup call WaitBGMap call WaitTop - call SetPalettes + call SetDefaultBGPAndOBP call NamingScreen_InitNameEntry ret diff --git a/engine/menus/options_menu.asm b/engine/menus/options_menu.asm index f11f535a..8776bdd4 100644 --- a/engine/menus/options_menu.asm +++ b/engine/menus/options_menu.asm @@ -48,7 +48,7 @@ _Option: call WaitBGMap ld b, SCGB_DIPLOMA call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP .joypad_loop call JoyTextDelay diff --git a/engine/menus/save.asm b/engine/menus/save.asm index c0428782..45dd1133 100644 --- a/engine/menus/save.asm +++ b/engine/menus/save.asm @@ -667,7 +667,7 @@ CheckBackupSaveFile: CheckTextDelay: ; Fix options if text delay is invalid ld hl, wTextboxFlags - res NO_TEXT_DELAY_F, [hl] + res TEXT_DELAY_F, [hl] ld a, [wOptions] and TEXT_DELAY_MASK cp TEXT_DELAY_FAST @@ -678,7 +678,7 @@ CheckTextDelay: ret z ld a, [wOptions] and ~TEXT_DELAY_MASK - or (1 << FAST_TEXT_DELAY_F) | (1 << NO_TEXT_DELAY_F) + or (1 << FAST_TEXT_DELAY_F) | (1 << TEXT_DELAY_F) ld [wOptions], a ret diff --git a/engine/menus/start_menu.asm b/engine/menus/start_menu.asm index 42a39c7d..22aa6fec 100644 --- a/engine/menus/start_menu.asm +++ b/engine/menus/start_menu.asm @@ -33,7 +33,7 @@ StartMenu:: call DrawVariableLengthMenuBox call .DrawBugContestStatusBox call SafeUpdateSprites - call _OpenAndCloseMenu_HDMATransferTilemapAndAttrmap + call HDMATransferTilemapAndAttrmap_Menu farcall LoadFonts_NoOAMUpdate call .DrawBugContestStatus call UpdateTimePals @@ -514,7 +514,7 @@ StartMenu_Pokemon: farcall WritePartyMenuTilemap farcall PrintPartyMenuText call WaitBGMap - call SetPalettes ; load regular palettes? + call SetDefaultBGPAndOBP call DelayFrame farcall PartyMenuSelect jr c, .return ; if cancelled or pressed B diff --git a/engine/menus/trainer_card.asm b/engine/menus/trainer_card.asm index a281e395..1295b14c 100644 --- a/engine/menus/trainer_card.asm +++ b/engine/menus/trainer_card.asm @@ -66,7 +66,7 @@ TrainerCard: call WaitBGMap ld b, SCGB_TRAINER_CARD call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP call WaitBGMap ld hl, wJumptableIndex xor a ; TRAINERCARDSTATE_PAGE1_LOADGFX diff --git a/engine/movie/credits.asm b/engine/movie/credits.asm index b42d3792..7206a99c 100644 --- a/engine/movie/credits.asm +++ b/engine/movie/credits.asm @@ -68,7 +68,7 @@ Credits:: ldh [hLCDCPointer], a call GetCreditsPalette - call SetPalettes + call SetDefaultBGPAndOBP ; BUG: Credits sequence changes move selection menu behavior (see docs/bugs_and_glitches.md) ldh a, [hVBlank] push af @@ -316,7 +316,7 @@ ParseCredits: xor a ld [wCreditsBorderFrame], a ; frame call GetCreditsPalette - call SetPalettes ; update hw pal registers + call SetDefaultBGPAndOBP ; update hw pal registers jr .loop .clear diff --git a/engine/movie/init_hof_credits.asm b/engine/movie/init_hof_credits.asm index 70a9b6e7..82d9c900 100644 --- a/engine/movie/init_hof_credits.asm +++ b/engine/movie/init_hof_credits.asm @@ -20,7 +20,7 @@ InitDisplayForHallOfFame: ld hl, .SavingRecordText call PrintText call WaitBGMap2 - call SetPalettes + call SetDefaultBGPAndOBP ret .SavingRecordText: @@ -56,5 +56,5 @@ InitDisplayForRedCredits: ldh [hSCX], a call EnableLCD call WaitBGMap2 - call SetPalettes + call SetDefaultBGPAndOBP ret diff --git a/engine/movie/splash.asm b/engine/movie/splash.asm index 6ebd35e4..90ead224 100644 --- a/engine/movie/splash.asm +++ b/engine/movie/splash.asm @@ -17,7 +17,7 @@ SplashScreen: call WaitBGMap ld b, SCGB_GAMEFREAK_LOGO call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP ld c, 10 call DelayFrames diff --git a/engine/overworld/events.asm b/engine/overworld/events.asm index c5edf09d..72c2d393 100644 --- a/engine/overworld/events.asm +++ b/engine/overworld/events.asm @@ -1119,11 +1119,9 @@ TryTileCollisionEvent:: ret RandomEncounter:: -; Random encounter - call CheckWildEncounterCooldown jr c, .nope - call CanUseSweetScent + call CanEncounterWildMonInThisTile jr nc, .nope ld hl, wStatusFlags2 bit STATUSFLAGS2_BUG_CONTEST_TIMER_F, [hl] @@ -1163,7 +1161,7 @@ WildBattleScript: reloadmapafterbattle end -CanUseSweetScent:: +CanEncounterWildMonInThisTile:: ld hl, wStatusFlags bit STATUSFLAGS_NO_WILD_ENCOUNTERS_F, [hl] jr nz, .no diff --git a/engine/overworld/init_map.asm b/engine/overworld/init_map.asm index c9a9d251..bac9ce77 100644 --- a/engine/overworld/init_map.asm +++ b/engine/overworld/init_map.asm @@ -27,10 +27,10 @@ ReanchorBGMap_NoOAMUpdate:: res 2, [hl] ld a, $90 ldh [hWY], a - call OverworldTextModeSwitch + call LoadOverworldTilemapAndAttrmapPals ld a, HIGH(vBGMap1) call .LoadBGMapAddrIntoHRAM - call _OpenAndCloseMenu_HDMATransferTilemapAndAttrmap + call HDMATransferTilemapAndAttrmap_Menu xor a ldh [hBGMapMode], a ldh [hWY], a diff --git a/engine/overworld/load_map_part.asm b/engine/overworld/load_map_part.asm index bc4d5625..34cfcc0a 100644 --- a/engine/overworld/load_map_part.asm +++ b/engine/overworld/load_map_part.asm @@ -1,4 +1,6 @@ -_LoadMapPart:: +_LoadOverworldTilemap:: +; From the metatile-based 24x20 map in wSurroundingTiles, +; load the corresponding 20x18 tiles to wTilemap. ld hl, wSurroundingTiles ld a, [wPlayerMetatileY] and a diff --git a/engine/overworld/player_object.asm b/engine/overworld/player_object.asm index ed21c617..58a692e3 100644 --- a/engine/overworld/player_object.asm +++ b/engine/overworld/player_object.asm @@ -13,7 +13,7 @@ BlankScreen: ld a, $7 call ByteFill call WaitBGMap2 - call SetPalettes + call SetDefaultBGPAndOBP ret SpawnPlayer: diff --git a/engine/overworld/player_step.asm b/engine/overworld/player_step.asm index 209258f3..abdd21b7 100644 --- a/engine/overworld/player_step.asm +++ b/engine/overworld/player_step.asm @@ -121,25 +121,25 @@ UpdateOverworldMap: .step_down call .ScrollOverworldMapDown - call LoadMapPart + call LoadOverworldTilemap call ScrollMapDown ret .step_up call .ScrollOverworldMapUp - call LoadMapPart + call LoadOverworldTilemap call ScrollMapUp ret .step_left call .ScrollOverworldMapLeft - call LoadMapPart + call LoadOverworldTilemap call ScrollMapLeft ret .step_right call .ScrollOverworldMapRight - call LoadMapPart + call LoadOverworldTilemap call ScrollMapRight ret diff --git a/engine/overworld/scripting.asm b/engine/overworld/scripting.asm index e84508b6..ea032133 100644 --- a/engine/overworld/scripting.asm +++ b/engine/overworld/scripting.asm @@ -2044,7 +2044,7 @@ Script_changeblock: Script_reloadmappart:: xor a ldh [hBGMapMode], a - call OverworldTextModeSwitch + call LoadOverworldTilemapAndAttrmapPals call GetMovementPermissions call ApplyTilemap call UpdateSprites diff --git a/engine/pokedex/new_pokedex_entry.asm b/engine/pokedex/new_pokedex_entry.asm index 844253c5..cdd427b0 100644 --- a/engine/pokedex/new_pokedex_entry.asm +++ b/engine/pokedex/new_pokedex_entry.asm @@ -46,5 +46,5 @@ NewPokedexEntry: ld [wTempMonDVs + 1], a ld b, SCGB_TRAINER_OR_MON_FRONTPIC_PALS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP ret diff --git a/engine/pokegear/pokegear.asm b/engine/pokegear/pokegear.asm index 93de654d..a9fa32d7 100644 --- a/engine/pokegear/pokegear.asm +++ b/engine/pokegear/pokegear.asm @@ -103,7 +103,7 @@ PokeGear: call InitPokegearTilemap ld b, SCGB_POKEGEAR_PALS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP ldh a, [hCGB] and a ret z @@ -1748,7 +1748,7 @@ _TownMap: ld [wTownMapCursorObjectPointer + 1], a ld b, SCGB_POKEGEAR_PALS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP ldh a, [hCGB] and a jr z, .dmg @@ -1994,7 +1994,7 @@ _FlyMap: call Pokegear_DummyFunction ld b, SCGB_POKEGEAR_PALS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP .loop call JoyTextDelay ld hl, hJoyPressed @@ -2315,7 +2315,7 @@ Pokedex_GetArea: call TownMapBGUpdate ld b, SCGB_POKEGEAR_PALS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP xor a ldh [hBGMapMode], a xor a ; JOHTO_REGION @@ -2763,7 +2763,7 @@ EntireFlyMap: ; unreferenced ld [wTownMapCursorCoordinates + 1], a ld b, SCGB_POKEGEAR_PALS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP .loop call JoyTextDelay ld hl, hJoyPressed diff --git a/engine/pokemon/bills_pc_top.asm b/engine/pokemon/bills_pc_top.asm index fa5833ae..27707c0d 100644 --- a/engine/pokemon/bills_pc_top.asm +++ b/engine/pokemon/bills_pc_top.asm @@ -48,7 +48,7 @@ _BillsPC: ld a, $1 .loop ld [wMenuCursorPosition], a - call SetPalettes + call SetDefaultBGPAndOBP xor a ld [wWhichIndexSet], a ldh [hBGMapMode], a @@ -245,7 +245,7 @@ ClearPCItemScreen: lb bc, 4, 18 call Textbox call WaitBGMap2 - call SetPalettes ; load regular palettes? + call SetDefaultBGPAndOBP ret CopyBoxmonToTempMon: diff --git a/engine/pokemon/breeding.asm b/engine/pokemon/breeding.asm index 87ac13d6..ae956827 100644 --- a/engine/pokemon/breeding.asm +++ b/engine/pokemon/breeding.asm @@ -647,7 +647,7 @@ Hatch_UpdateFrontpicBGMapCenter: predef PlaceGraphic pop af call Hatch_LoadFrontpicPal - call SetPalettes + call SetDefaultBGPAndOBP jp WaitBGMap EggHatch_DoAnimFrame: diff --git a/engine/pokemon/mail.asm b/engine/pokemon/mail.asm index 55e6b03f..cf1e02dd 100644 --- a/engine/pokemon/mail.asm +++ b/engine/pokemon/mail.asm @@ -490,7 +490,7 @@ MailboxPC: farcall WritePartyMenuTilemap farcall PrintPartyMenuText call WaitBGMap - call SetPalettes + call SetDefaultBGPAndOBP call DelayFrame farcall PartyMenuSelect jr c, .exit2 diff --git a/engine/pokemon/mail_2.asm b/engine/pokemon/mail_2.asm index 88510551..f951ac86 100644 --- a/engine/pokemon/mail_2.asm +++ b/engine/pokemon/mail_2.asm @@ -34,7 +34,7 @@ ReadAnyMail: ld a, [wCurMailIndex] ld e, a farcall LoadMailPalettes - call SetPalettes + call SetDefaultBGPAndOBP xor a ldh [hJoyPressed], a call .loop diff --git a/engine/pokemon/mon_menu.asm b/engine/pokemon/mon_menu.asm index 8d14ca36..3c4ee4e4 100644 --- a/engine/pokemon/mon_menu.asm +++ b/engine/pokemon/mon_menu.asm @@ -173,7 +173,7 @@ SwitchPartyMons: call AddNTimes ld [hl], "▷" call WaitBGMap - call SetPalettes + call SetDefaultBGPAndOBP call DelayFrame farcall PartyMenuSelect @@ -1150,7 +1150,7 @@ SetUpMoveList: hlcoord 10, 4 predef ListMovePP call WaitBGMap - call SetPalettes + call SetDefaultBGPAndOBP ld a, [wNumMoves] inc a ld [w2DMenuNumRows], a diff --git a/engine/pokemon/party_menu.asm b/engine/pokemon/party_menu.asm index 93b088b7..fa728b73 100644 --- a/engine/pokemon/party_menu.asm +++ b/engine/pokemon/party_menu.asm @@ -5,7 +5,7 @@ SelectMonFromParty: call ClearBGPalettes call InitPartyMenuLayout call WaitBGMap - call SetPalettes + call SetDefaultBGPAndOBP call DelayFrame call PartyMenuSelect call ReturnToMapWithSpeechTextbox @@ -20,7 +20,7 @@ SelectTradeOrDayCareMon: call WaitBGMap ld b, SCGB_PARTY_MENU call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP call DelayFrame call PartyMenuSelect call ReturnToMapWithSpeechTextbox diff --git a/engine/pokemon/stats_screen.asm b/engine/pokemon/stats_screen.asm index d10e811e..d070ef9e 100644 --- a/engine/pokemon/stats_screen.asm +++ b/engine/pokemon/stats_screen.asm @@ -721,7 +721,7 @@ OTString: StatsScreen_PlaceFrontpic: push bc - call SetPalettes + call SetDefaultBGPAndOBP ld hl, wTempMonDVs call GetUnownLetter hlcoord 0, 0 @@ -782,7 +782,7 @@ EggStatsScreen: call WaitBGMap ld a, 1 ldh [hBGMapMode], a - call SetPalettes ; pals + call SetDefaultBGPAndOBP hlcoord 0, 0 call PrepMonFrontpic ld a, [wTempMonHappiness] diff --git a/engine/printer/print_party.asm b/engine/printer/print_party.asm index d4491cb4..80aaacaf 100644 --- a/engine/printer/print_party.asm +++ b/engine/printer/print_party.asm @@ -217,7 +217,7 @@ PrintPartyMonPage1: call WaitBGMap ld b, SCGB_STATS_SCREEN_HP_PALS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP ret PrintPartyMonPage2: @@ -284,7 +284,7 @@ PrintPartyMonPage2: call WaitBGMap ld b, SCGB_STATS_SCREEN_HP_PALS call GetSGBLayout - call SetPalettes + call SetDefaultBGPAndOBP ret .PrintTempMonStats: diff --git a/engine/tilesets/map_palettes.asm b/engine/tilesets/map_palettes.asm index ddc31371..cf5cf184 100644 --- a/engine/tilesets/map_palettes.asm +++ b/engine/tilesets/map_palettes.asm @@ -1,4 +1,5 @@ -_SwapTextboxPalettes:: +_LoadOverworldAttrmapPals:: +; Load wAttrmap palette numbers based on the tileset palettes of current map. hlcoord 0, 0 decoord 0, 0, wAttrmap ld b, SCREEN_HEIGHT diff --git a/engine/tilesets/timeofday_pals.asm b/engine/tilesets/timeofday_pals.asm index a7545bdd..6c5b5cab 100644 --- a/engine/tilesets/timeofday_pals.asm +++ b/engine/tilesets/timeofday_pals.asm @@ -62,14 +62,14 @@ _UpdateTimePals:: call DmgToCgbTimePals ret -FadeInPalettes:: +FadeInFromWhite:: ld c, $12 call GetTimePalFade ld b, $4 call ConvertTimePalsDecHL ret -FadeOutPalettes:: +FadeOutToWhite:: call FillWhiteBGColor ld c, $9 call GetTimePalFade @@ -77,14 +77,14 @@ FadeOutPalettes:: call ConvertTimePalsIncHL ret -FadeInQuickly: +FadeInFromBlack: ld c, $0 call GetTimePalFade ld b, $4 call ConvertTimePalsIncHL ret -FadeBlackQuickly: +FadeOutToBlack: ld c, $9 call GetTimePalFade ld b, $4 diff --git a/home/map.asm b/home/map.asm index 52c23a6b..abef569e 100644 --- a/home/map.asm +++ b/home/map.asm @@ -91,12 +91,12 @@ GetMapSceneID:: pop bc ret -OverworldTextModeSwitch:: - call LoadMapPart - call SwapTextboxPalettes +LoadOverworldTilemapAndAttrmapPals:: + call LoadOverworldTilemap + call LoadOverworldAttrmapPals ret -LoadMapPart:: +LoadOverworldTilemap:: ldh a, [hROMBank] push af @@ -109,9 +109,9 @@ LoadMapPart:: ld bc, SCREEN_WIDTH * SCREEN_HEIGHT call ByteFill - ld a, BANK(_LoadMapPart) + ld a, BANK(_LoadOverworldTilemap) rst Bankswitch - call _LoadMapPart + call _LoadOverworldTilemap pop af rst Bankswitch @@ -234,7 +234,7 @@ LoadMapTimeOfDay:: ld [wSpriteUpdatesEnabled], a farcall ReplaceTimeOfDayPals farcall UpdateTimeOfDayPal - call OverworldTextModeSwitch + call LoadOverworldTilemapAndAttrmapPals call .ClearBGMap call .PushAttrmap ret @@ -2265,7 +2265,7 @@ FadeToMenu:: xor a ldh [hBGMapMode], a call LoadStandardMenuHeader - farcall FadeOutPalettes + farcall FadeOutToWhite call ClearSprites call DisableSpriteUpdates ret @@ -2288,7 +2288,7 @@ FinishExitMenu:: ld b, SCGB_MAPPALS call GetSGBLayout call WaitBGMap2 - farcall FadeInPalettes + farcall FadeInFromWhite call EnableSpriteUpdates ret @@ -2329,7 +2329,7 @@ ReloadTilesetAndPalettes:: ld c, a call SwitchToAnyMapAttributesBank farcall UpdateTimeOfDayPal - call OverworldTextModeSwitch + call LoadOverworldTilemapAndAttrmapPals call LoadTilesetGFX ld a, 8 call SkipMusic diff --git a/home/palettes.asm b/home/palettes.asm index af7f7ba7..c329a4e3 100644 --- a/home/palettes.asm +++ b/home/palettes.asm @@ -287,8 +287,8 @@ ReloadSpritesNoPalettes:: call DelayFrame ret -SwapTextboxPalettes:: - homecall _SwapTextboxPalettes +LoadOverworldAttrmapPals:: + homecall _LoadOverworldAttrmapPals ret ScrollBGMapPalettes:: diff --git a/home/print_text.asm b/home/print_text.asm index df07955e..76818199 100644 --- a/home/print_text.asm +++ b/home/print_text.asm @@ -15,7 +15,7 @@ PrintLetterDelay:: ; non-scrolling text? ld a, [wTextboxFlags] - bit NO_TEXT_DELAY_F, a + bit TEXT_DELAY_F, a ret z push hl diff --git a/home/scrolling_menu.asm b/home/scrolling_menu.asm index cde0e021..5e637395 100644 --- a/home/scrolling_menu.asm +++ b/home/scrolling_menu.asm @@ -20,7 +20,7 @@ ScrollingMenu:: ld hl, wVramState bit 0, [hl] jp nz, UpdateTimePals - jp SetPalettes + jp SetDefaultBGPAndOBP InitScrollingMenu:: ld a, [wMenuBorderTopCoord] diff --git a/home/text.asm b/home/text.asm index 33a9003b..3ce60e8e 100644 --- a/home/text.asm +++ b/home/text.asm @@ -579,7 +579,7 @@ PokeFluteTerminator:: ; unreferenced PlaceHLTextAtBC:: ld a, [wTextboxFlags] push af - set NO_TEXT_DELAY_F, a + set TEXT_DELAY_F, a ld [wTextboxFlags], a call DoTextUntilTerminator diff --git a/home/tilemap.asm b/home/tilemap.asm index f65a0d5b..a9c22a14 100644 --- a/home/tilemap.asm +++ b/home/tilemap.asm @@ -136,12 +136,12 @@ endr ld sp, hl ret -SetPalettes:: +SetDefaultBGPAndOBP:: ; Inits the Palettes ; depending on the system the monochromes palettes or color palettes ldh a, [hCGB] and a - jr nz, .SetPalettesForGameBoyColor + jr nz, .SetDefaultBGPAndOBPForGameBoyColor ld a, %11100100 ldh [rBGP], a ld a, %11010000 @@ -149,7 +149,7 @@ SetPalettes:: ldh [rOBP1], a ret -.SetPalettesForGameBoyColor: +.SetDefaultBGPAndOBPForGameBoyColor: push de ld a, %11100100 call DmgToCgbBGPals diff --git a/home/window.asm b/home/window.asm index e8e0604d..24f490d7 100644 --- a/home/window.asm +++ b/home/window.asm @@ -6,7 +6,7 @@ RefreshScreen:: rst Bankswitch call ReanchorBGMap_NoOAMUpdate - call _OpenAndCloseMenu_HDMATransferTilemapAndAttrmap + call HDMATransferTilemapAndAttrmap_Menu call LoadFonts_NoOAMUpdate pop af @@ -29,8 +29,8 @@ CloseText:: call ClearWindowData xor a ldh [hBGMapMode], a - call OverworldTextModeSwitch - call _OpenAndCloseMenu_HDMATransferTilemapAndAttrmap + call LoadOverworldTilemapAndAttrmapPals + call HDMATransferTilemapAndAttrmap_Menu xor a ldh [hBGMapMode], a call SafeUpdateSprites @@ -50,16 +50,16 @@ OpenText:: ld a, BANK(ReanchorBGMap_NoOAMUpdate) ; aka BANK(LoadFonts_NoOAMUpdate) rst Bankswitch - call ReanchorBGMap_NoOAMUpdate ; clear bgmap + call ReanchorBGMap_NoOAMUpdate ; anchor bgmap call SpeechTextbox - call _OpenAndCloseMenu_HDMATransferTilemapAndAttrmap ; anchor bgmap + call HDMATransferTilemapAndAttrmap_Menu ; transfer bgmap call LoadFonts_NoOAMUpdate ; load font pop af rst Bankswitch ret -_OpenAndCloseMenu_HDMATransferTilemapAndAttrmap:: +HDMATransferTilemapAndAttrmap_Menu:: ldh a, [hOAMUpdate] push af ld a, $1 diff --git a/maps/BluesHouse.asm b/maps/BluesHouse.asm index 55a38d1d..5413d149 100644 --- a/maps/BluesHouse.asm +++ b/maps/BluesHouse.asm @@ -31,10 +31,10 @@ DaisyScript: writetext DaisyAlrightText waitbutton closetext - special FadeOutPalettes + special FadeOutToWhite playmusic MUSIC_HEAL pause 60 - special FadeInPalettes + special FadeInFromWhite special RestartMapMusic opentext writetext GroomedMonLooksContentText diff --git a/maps/FastShip1F.asm b/maps/FastShip1F.asm index 8d078e0f..baa3e32e 100644 --- a/maps/FastShip1F.asm +++ b/maps/FastShip1F.asm @@ -66,7 +66,7 @@ FastShip1FSailor1Script: closetext scall .LetThePlayerOut playsound SFX_EXIT_BUILDING - special FadeOutPalettes + special FadeOutToWhite waitsfx setevent EVENT_VERMILION_PORT_SAILOR_AT_GANGWAY setmapscene VERMILION_PORT, SCENE_VERMILIONPORT_LEAVE_SHIP @@ -79,7 +79,7 @@ FastShip1FSailor1Script: closetext scall .LetThePlayerOut playsound SFX_EXIT_BUILDING - special FadeOutPalettes + special FadeOutToWhite waitsfx setevent EVENT_OLIVINE_PORT_SAILOR_AT_GANGWAY setmapscene OLIVINE_PORT, SCENE_OLIVINEPORT_LEAVE_SHIP diff --git a/maps/FastShipCabins_SE_SSE_CaptainsCabin.asm b/maps/FastShipCabins_SE_SSE_CaptainsCabin.asm index fa924b6d..7ba851f5 100644 --- a/maps/FastShipCabins_SE_SSE_CaptainsCabin.asm +++ b/maps/FastShipCabins_SE_SSE_CaptainsCabin.asm @@ -46,7 +46,7 @@ SSAquaGranddaughterBefore: writetext SSAquaGranddaughterHasToFindGrandpaText waitbutton closetext - special FadeBlackQuickly + special FadeOutToBlack special ReloadSpritesNoPalettes disappear FASTSHIPCABINS_SE_SSE_CAPTAINSCABIN_TWIN2 applymovement PLAYER, SSAquaCaptainsCabinWarpsToGrandpasCabinMovement @@ -54,7 +54,7 @@ SSAquaGranddaughterBefore: appear FASTSHIPCABINS_SE_SSE_CAPTAINSCABIN_TWIN1 turnobject PLAYER, UP turnobject FASTSHIPCABINS_SE_SSE_CAPTAINSCABIN_TWIN1, UP - special FadeInQuickly + special FadeInFromBlack turnobject FASTSHIPCABINS_SE_SSE_CAPTAINSCABIN_GENTLEMAN, DOWN showemote EMOTE_SHOCK, FASTSHIPCABINS_SE_SSE_CAPTAINSCABIN_GENTLEMAN, 15 applymovement FASTSHIPCABINS_SE_SSE_CAPTAINSCABIN_TWIN1, SSAquaGranddaughterEntersCabinMovement diff --git a/maps/FastShipCabins_SW_SSW_NW.asm b/maps/FastShipCabins_SW_SSW_NW.asm index 083f4d0e..47919666 100644 --- a/maps/FastShipCabins_SW_SSW_NW.asm +++ b/maps/FastShipCabins_SW_SSW_NW.asm @@ -58,13 +58,13 @@ FastShipBed: writetext FastShipBedText1 waitbutton closetext - special FadeBlackQuickly + special FadeOutToBlack special ReloadSpritesNoPalettes special HealParty playmusic MUSIC_HEAL pause 60 special RestartMapMusic - special FadeInQuickly + special FadeInFromBlack opentext writetext FastShipBedText2 waitbutton diff --git a/maps/GoldenrodUnderground.asm b/maps/GoldenrodUnderground.asm index 2d3282e0..c50029b6 100644 --- a/maps/GoldenrodUnderground.asm +++ b/maps/GoldenrodUnderground.asm @@ -233,10 +233,10 @@ OlderHaircutBrotherScript: writetext GoldenrodUndergroundOlderHaircutBrotherWatchItBecomeBeautifulText waitbutton closetext - special FadeOutPalettes + special FadeOutToWhite playmusic MUSIC_HEAL pause 60 - special FadeInPalettes + special FadeInFromWhite special RestartMapMusic opentext writetext GoldenrodUndergroundOlderHaircutBrotherAllDoneText @@ -316,10 +316,10 @@ YoungerHaircutBrotherScript: writetext GoldenrodUndergroundYoungerHaircutBrotherIllMakeItLookCoolText waitbutton closetext - special FadeOutPalettes + special FadeOutToWhite playmusic MUSIC_HEAL pause 60 - special FadeInPalettes + special FadeInFromWhite special RestartMapMusic opentext writetext GoldenrodUndergroundYoungerHaircutBrotherAllDoneText diff --git a/maps/IndigoPlateauPokecenter1F.asm b/maps/IndigoPlateauPokecenter1F.asm index 7d837047..d894cee8 100644 --- a/maps/IndigoPlateauPokecenter1F.asm +++ b/maps/IndigoPlateauPokecenter1F.asm @@ -156,7 +156,7 @@ TeleportGuyScript: waitbutton closetext playsound SFX_WARP_TO - special FadeOutPalettes + special FadeOutToWhite waitsfx warp NEW_BARK_TOWN, 13, 6 end diff --git a/maps/LancesRoom.asm b/maps/LancesRoom.asm index 07292bcd..6f65559a 100644 --- a/maps/LancesRoom.asm +++ b/maps/LancesRoom.asm @@ -123,7 +123,7 @@ LancesRoomLanceScript: pause 30 closetext applymovement LANCESROOM_MARY, LancesRoomMovementData_MaryRunsBackAndForth - special FadeOutPalettes + special FadeOutToWhite pause 15 warp HALL_OF_FAME, 4, 13 end diff --git a/maps/MrPokemonsHouse.asm b/maps/MrPokemonsHouse.asm index 8292d0f5..2e326cb0 100644 --- a/maps/MrPokemonsHouse.asm +++ b/maps/MrPokemonsHouse.asm @@ -108,12 +108,12 @@ MrPokemonsHouse_OakScript: writetext MrPokemonsHouse_MrPokemonHealText waitbutton closetext - special FadeBlackQuickly + special FadeOutToBlack special ReloadSpritesNoPalettes playmusic MUSIC_HEAL special HealParty pause 60 - special FadeInQuickly + special FadeInFromBlack special RestartMapMusic opentext writetext MrPokemonText_ImDependingOnYou diff --git a/maps/OlivineLighthouse6F.asm b/maps/OlivineLighthouse6F.asm index 6f9e43dd..94af79d1 100644 --- a/maps/OlivineLighthouse6F.asm +++ b/maps/OlivineLighthouse6F.asm @@ -45,9 +45,9 @@ OlivineLighthouseJasmine: closetext special RestartMapMusic cry AMPHAROS - special FadeOutPalettes + special FadeOutToWhite pause 10 - special FadeInPalettes + special FadeInFromWhite opentext writetext AmphyPaluPaluluText waitbutton @@ -119,10 +119,10 @@ OlivineLighthouseAmphy: cry AMPHAROS waitbutton closetext - special FadeOutPalettes - special FadeInPalettes - special FadeOutPalettes - special FadeInPalettes + special FadeOutToWhite + special FadeInFromWhite + special FadeOutToWhite + special FadeInFromWhite end OlivineLighthouse6FSuperPotion: diff --git a/maps/OlivinePort.asm b/maps/OlivinePort.asm index 74e34d0f..19c8d898 100644 --- a/maps/OlivinePort.asm +++ b/maps/OlivinePort.asm @@ -44,7 +44,7 @@ OlivinePortSailorAtGangwayScript: waitsfx applymovement PLAYER, OlivinePortEnterFastShipMovement playsound SFX_EXIT_BUILDING - special FadeOutPalettes + special FadeOutToWhite waitsfx checkevent EVENT_FAST_SHIP_FIRST_TIME iffalse .FirstTime diff --git a/maps/RadioTower5F.asm b/maps/RadioTower5F.asm index cc3dac53..313e32ce 100644 --- a/maps/RadioTower5F.asm +++ b/maps/RadioTower5F.asm @@ -92,12 +92,12 @@ RadioTower5FRocketBossScript: writetext RadioTower5FRocketBossAfterText waitbutton closetext - special FadeBlackQuickly + special FadeOutToBlack special ReloadSpritesNoPalettes disappear RADIOTOWER5F_ROCKET disappear RADIOTOWER5F_ROCKET_GIRL pause 15 - special FadeInQuickly + special FadeInFromBlack setevent EVENT_BEAT_ROCKET_EXECUTIVEM_1 setevent EVENT_CLEARED_RADIO_TOWER clearflag ENGINE_ROCKETS_IN_RADIO_TOWER diff --git a/maps/Route24.asm b/maps/Route24.asm index dd2d2241..13b83184 100644 --- a/maps/Route24.asm +++ b/maps/Route24.asm @@ -26,11 +26,11 @@ Route24RocketScript: writetext Route24RocketDisappearsText waitbutton closetext - special FadeBlackQuickly + special FadeOutToBlack special ReloadSpritesNoPalettes disappear ROUTE24_ROCKET pause 25 - special FadeInQuickly + special FadeInFromBlack playmapmusic end diff --git a/maps/Route26HealHouse.asm b/maps/Route26HealHouse.asm index 48273f0f..331a4720 100644 --- a/maps/Route26HealHouse.asm +++ b/maps/Route26HealHouse.asm @@ -12,12 +12,12 @@ Route26HealHouseTeacherScript: writetext Route26HealHouseRestAWhileText waitbutton closetext - special FadeBlackQuickly + special FadeOutToBlack special ReloadSpritesNoPalettes playmusic MUSIC_HEAL special HealParty pause 60 - special FadeInQuickly + special FadeInFromBlack special RestartMapMusic opentext writetext Route26HealHouseKeepAtItText diff --git a/maps/Route35NationalParkGate.asm b/maps/Route35NationalParkGate.asm index db82df79..33da7f8d 100644 --- a/maps/Route35NationalParkGate.asm +++ b/maps/Route35NationalParkGate.asm @@ -72,7 +72,7 @@ Route35NationalParkGateLeavingContestEarlyScript: closetext scall Route35NationalParkGate_EnterContest playsound SFX_ENTER_DOOR - special FadeOutPalettes + special FadeOutToWhite waitsfx warp NATIONAL_PARK_BUG_CONTEST, 10, 47 end @@ -109,7 +109,7 @@ Route35NationalParkGate_OkayToProceed: special GiveParkBalls scall Route35NationalParkGate_EnterContest playsound SFX_ENTER_DOOR - special FadeOutPalettes + special FadeOutToWhite waitsfx special SelectRandomBugContestContestants warp NATIONAL_PARK_BUG_CONTEST, 10, 47 diff --git a/maps/Route36NationalParkGate.asm b/maps/Route36NationalParkGate.asm index 9a1b1f20..b9808884 100644 --- a/maps/Route36NationalParkGate.asm +++ b/maps/Route36NationalParkGate.asm @@ -73,14 +73,14 @@ Route36NationalParkGateLeavingContestEarlyScript: writetext Route36NationalParkGateOfficer1WaitHereForAnnouncementText waitbutton closetext - special FadeBlackQuickly + special FadeOutToBlack special ReloadSpritesNoPalettes scall .CopyContestants disappear ROUTE36NATIONALPARKGATE_OFFICER1 appear ROUTE36NATIONALPARKGATE_OFFICER2 applymovement PLAYER, Route36NationalParkGatePlayerWaitWithContestantsMovement pause 15 - special FadeInQuickly + special FadeInFromBlack jumpstd BugContestResultsScript .GoBackToContest: @@ -89,7 +89,7 @@ Route36NationalParkGateLeavingContestEarlyScript: closetext turnobject PLAYER, LEFT playsound SFX_EXIT_BUILDING - special FadeOutPalettes + special FadeOutToWhite waitsfx warp NATIONAL_PARK_BUG_CONTEST, 33, 18 end @@ -172,7 +172,7 @@ Route36OfficerScriptContest: special GiveParkBalls turnobject PLAYER, LEFT playsound SFX_EXIT_BUILDING - special FadeOutPalettes + special FadeOutToWhite waitsfx special SelectRandomBugContestContestants warp NATIONAL_PARK_BUG_CONTEST, 33, 18 diff --git a/maps/SilverCaveRoom3.asm b/maps/SilverCaveRoom3.asm index 1c86473b..811a8506 100644 --- a/maps/SilverCaveRoom3.asm +++ b/maps/SilverCaveRoom3.asm @@ -23,11 +23,11 @@ Red: writetext RedLeavesText waitbutton closetext - special FadeBlackQuickly + special FadeOutToBlack special ReloadSpritesNoPalettes disappear SILVERCAVEROOM3_RED pause 15 - special FadeInQuickly + special FadeInFromBlack pause 30 special HealParty refreshscreen diff --git a/maps/SlowpokeWellB1F.asm b/maps/SlowpokeWellB1F.asm index 11e401a6..ea6b6ba6 100644 --- a/maps/SlowpokeWellB1F.asm +++ b/maps/SlowpokeWellB1F.asm @@ -36,14 +36,14 @@ TrainerGruntM1: writetext TrainerGruntM1WhenTalkText waitbutton closetext - special FadeBlackQuickly + special FadeOutToBlack special ReloadSpritesNoPalettes disappear SLOWPOKEWELLB1F_ROCKET1 disappear SLOWPOKEWELLB1F_ROCKET2 disappear SLOWPOKEWELLB1F_ROCKET3 disappear SLOWPOKEWELLB1F_ROCKET_GIRL pause 15 - special FadeInQuickly + special FadeInFromBlack disappear SLOWPOKEWELLB1F_KURT moveobject SLOWPOKEWELLB1F_KURT, 11, 6 appear SLOWPOKEWELLB1F_KURT @@ -65,7 +65,7 @@ TrainerGruntM1: clearevent EVENT_AZALEA_TOWN_SLOWPOKES clearevent EVENT_KURTS_HOUSE_SLOWPOKE clearevent EVENT_KURTS_HOUSE_KURT_1 - special FadeOutPalettes + special FadeOutToWhite special HealParty pause 15 warp KURTS_HOUSE, 3, 3 diff --git a/maps/SproutTower3F.asm b/maps/SproutTower3F.asm index c126f769..dd456db8 100644 --- a/maps/SproutTower3F.asm +++ b/maps/SproutTower3F.asm @@ -52,11 +52,11 @@ SproutTower3FRivalScene: pause 15 closetext playsound SFX_WARP_TO - special FadeBlackQuickly + special FadeOutToBlack special ReloadSpritesNoPalettes disappear SPROUTTOWER3F_RIVAL waitsfx - special FadeInQuickly + special FadeInFromBlack setscene SCENE_SPROUTTOWER3F_NOOP special RestartMapMusic end diff --git a/maps/TeamRocketBaseB1F.asm b/maps/TeamRocketBaseB1F.asm index 375cbe7d..e6a97025 100644 --- a/maps/TeamRocketBaseB1F.asm +++ b/maps/TeamRocketBaseB1F.asm @@ -446,9 +446,9 @@ ExplodingTrap22: end VoltorbExplodingTrap: - special FadeOutPalettes + special FadeOutToWhite cry VOLTORB - special FadeInPalettes + special FadeInFromWhite setlasttalked -1 loadvar VAR_BATTLETYPE, BATTLETYPE_TRAP loadwildmon VOLTORB, 23 @@ -456,9 +456,9 @@ VoltorbExplodingTrap: end GeodudeExplodingTrap: - special FadeOutPalettes + special FadeOutToWhite cry GEODUDE - special FadeInPalettes + special FadeInFromWhite setlasttalked -1 loadvar VAR_BATTLETYPE, BATTLETYPE_TRAP loadwildmon GEODUDE, 21 @@ -466,9 +466,9 @@ GeodudeExplodingTrap: end KoffingExplodingTrap: - special FadeOutPalettes + special FadeOutToWhite cry KOFFING - special FadeInPalettes + special FadeInFromWhite setlasttalked -1 loadvar VAR_BATTLETYPE, BATTLETYPE_TRAP loadwildmon KOFFING, 21 diff --git a/maps/TeamRocketBaseB2F.asm b/maps/TeamRocketBaseB2F.asm index 9b1b54a2..ff7fd4ed 100644 --- a/maps/TeamRocketBaseB2F.asm +++ b/maps/TeamRocketBaseB2F.asm @@ -107,7 +107,7 @@ RocketBaseBossFScript: writetext RocketBaseBossRetreatText waitbutton closetext - special FadeBlackQuickly + special FadeOutToBlack special ReloadSpritesNoPalettes disappear TEAMROCKETBASEB2F_ROCKET1 disappear TEAMROCKETBASEB2F_ROCKET_GIRL @@ -115,7 +115,7 @@ RocketBaseBossFScript: disappear TEAMROCKETBASEB2F_ROCKET3 disappear TEAMROCKETBASEB2F_ROCKET4 pause 15 - special FadeInQuickly + special FadeInFromBlack setscene SCENE_TEAMROCKETBASEB2F_ELECTRODES clearevent EVENT_TEAM_ROCKET_BASE_B2F_LANCE turnobject TEAMROCKETBASEB2F_LANCE, DOWN @@ -164,10 +164,10 @@ LanceHealsCommon: writetext LanceHealsText1 waitbutton closetext - special FadeOutPalettes + special FadeOutToWhite playsound SFX_FULL_HEAL special HealParty - special FadeInPalettes + special FadeInFromWhite opentext writetext LanceHealsText2 waitbutton diff --git a/maps/VermilionPort.asm b/maps/VermilionPort.asm index a08d5196..3b331738 100644 --- a/maps/VermilionPort.asm +++ b/maps/VermilionPort.asm @@ -50,7 +50,7 @@ VermilionPortSailorAtGangwayScript: waitsfx applymovement PLAYER, VermilionPortEnterFastShipMovement playsound SFX_EXIT_BUILDING - special FadeOutPalettes + special FadeOutToWhite waitsfx setevent EVENT_FAST_SHIP_PASSENGERS_EASTBOUND clearevent EVENT_FAST_SHIP_PASSENGERS_WESTBOUND