From 31c3c94d64e1ac1e40c95acfda7de8b99b4f302b Mon Sep 17 00:00:00 2001 From: vulcandth Date: Sat, 12 Mar 2022 17:34:04 -0600 Subject: Build the Virtual Console patch with `make crystal11_vc` (#882) Fixes #813 --- engine/menus/menu.asm | 2 ++ engine/menus/save.asm | 9 +++++++++ 2 files changed, 11 insertions(+) (limited to 'engine/menus') diff --git a/engine/menus/menu.asm b/engine/menus/menu.asm index f20a6dceb..edae1c982 100644 --- a/engine/menus/menu.asm +++ b/engine/menus/menu.asm @@ -362,7 +362,9 @@ Menu_WasButtonPressed: call GetMenuJoypad and a ret z + vc_hook print_forbid_3 scf + vc_hook print_forbid_2 ret _2DMenuInterpretJoypad: diff --git a/engine/menus/save.asm b/engine/menus/save.asm index 82dab1046..381e3cc7c 100644 --- a/engine/menus/save.asm +++ b/engine/menus/save.asm @@ -161,6 +161,15 @@ AddHallOfFameEntry: ld bc, wHallOfFamePokemonListEnd - wHallOfFamePokemonList + 1 call CopyBytes call CloseSRAM +; This vc_hook causes the Virtual Console to set [sMobileEventIndex] and [sMobileEventIndexBackup] +; to MOBILE_EVENT_OBJECT_GS_BALL ($b), which enables you to get the GS Ball, take it to Kurt, and +; encounter Celebi. It assumes that sMobileEventIndex and sMobileEventIndexBackup are at their +; original addresses. + vc_hook BiographySave_ret + vc_assert BANK(sMobileEventIndex) == $1 && sMobileEventIndex == $be3c, \ + "sMobileEventIndex is no longer located at 01:be3c." + vc_assert BANK(sMobileEventIndexBackup) == $1 && sMobileEventIndexBackup == $be44, \ + "sMobileEventIndexBackup is no longer located at 01:be44." ret SaveGameData: -- cgit v1.2.3