1
0
mirror of synced 2024-11-28 09:21:03 +01:00

Move amframework files to current directory

This commit is contained in:
esuo1198 2024-03-08 13:30:09 +09:00
parent fe19c709e7
commit c52e249295

View File

@ -79,6 +79,16 @@ Init () {
auto amHandle = (u64)GetModuleHandle ("AMFrameWork.dll"); auto amHandle = (u64)GetModuleHandle ("AMFrameWork.dll");
INSTALL_HOOK_DYNAMIC (AMFWTerminate, (void *)(amHandle + 0x42DE0)); INSTALL_HOOK_DYNAMIC (AMFWTerminate, (void *)(amHandle + 0x42DE0));
// Move various files to current directory
WRITE_MEMORY (amHandle + 0x15252, u8, 0xEB); // CreditLogPathA
WRITE_MEMORY (amHandle + 0x15419, u8, 0xEB); // CreditLogPathB
WRITE_MEMORY (amHandle + 0x416DA, u8, 0xEB); // ErrorLogPathA
WRITE_MEMORY (amHandle + 0x41859, u8, 0xEB); // ErrorLogPathB
WRITE_MEMORY (amHandle + 0x41C21, u8, 0xEB); // CommonLogPathA
WRITE_MEMORY (amHandle + 0x41DA5, u8, 0xEB); // CommonLogPathB
WRITE_MEMORY (amHandle + 0x420F1, u8, 0x90, 0x90, 0x90, 0x90, 0x90); // BackupDataPathA
WRITE_MEMORY (amHandle + 0x42167, u8, 0x90, 0x90, 0x90, 0x90, 0x90); // BackupDataPathB
// Redirect garmc requests // Redirect garmc requests
auto garmcHandle = (u64)GetModuleHandle ("garmc.dll"); auto garmcHandle = (u64)GetModuleHandle ("garmc.dll");
INSTALL_HOOK_DYNAMIC (curl_easy_setopt, (void *)(garmcHandle + 0x1FBBB0)); INSTALL_HOOK_DYNAMIC (curl_easy_setopt, (void *)(garmcHandle + 0x1FBBB0));