Skip to content

Commit

Permalink
FF7: Fix crash when entering config menu on Steam/SP
Browse files Browse the repository at this point in the history
  • Loading branch information
julianxhokaxhiu committed Sep 28, 2024
1 parent 699d7c9 commit 13b4823
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
4 changes: 4 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

- Full commit list since last stable release: https://github.com/julianxhokaxhiu/FFNx/compare/1.20.1...master

## FF7 Steam

- Core: Fix crash when entering Config menu in Spanish ( https://github.com/julianxhokaxhiu/FFNx/discussions/735 )

# 1.20.1

- Full commit list since last stable release: https://github.com/julianxhokaxhiu/FFNx/compare/1.20.0...1.20.1
Expand Down
13 changes: 10 additions & 3 deletions src/ff7_opengl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -403,19 +403,26 @@ void ff7_init_hooks(struct game_obj *_game_object)
{
case VERSION_FF7_102_US:
replace_call_function(ff7_externals.menu_sub_6FEDB0 + 0x1096, ff7_write_save_file);
// Disable "Normal" setting in Controller section of the Config menu (it softlocks on Steam)
memset_code(ff7_externals.config_menu_sub + 0x8AC, 0x90, 0xE6);
break;
case VERSION_FF7_102_DE:
replace_call_function(ff7_externals.menu_sub_6FEDB0 + 0x10B2, ff7_write_save_file);
// Disable "Normal" setting in Controller section of the Config menu (it softlocks on Steam)
memset_code(ff7_externals.config_menu_sub + 0x8B3, 0x90, 0xE6);
break;
case VERSION_FF7_102_FR:
replace_call_function(ff7_externals.menu_sub_6FEDB0 + 0x10B2, ff7_write_save_file);
// Disable "Normal" setting in Controller section of the Config menu (it softlocks on Steam)
memset_code(ff7_externals.config_menu_sub + 0x8AC, 0x90, 0xE6);
break;
case VERSION_FF7_102_SP:
replace_call_function(ff7_externals.menu_sub_6FEDB0 + 0x10FE, ff7_write_save_file);
// Disable "Normal" setting in Controller section of the Config menu (it softlocks on Steam)
memset_code(ff7_externals.config_menu_sub + 0x8B3, 0x90, 0xE6);
break;
}

// Disable "Normal" setting in Controller section of the Config menu (it softlocks on Steam)
memset_code(ff7_externals.config_menu_sub + 0x8AC, 0x90, 0xE6);

// Restore Steam release behavior on character name screen when using gamepads in Steam Input mode
// Aali driver used to patch out these three functions to fix this issue
replace_function(ff7_externals.set_default_input_settings_save, noop);
Expand Down

0 comments on commit 13b4823

Please sign in to comment.