Replace function in ATV Offroad Fury Pro

This commit is contained in:
daniel229 2016-01-03 22:13:42 +08:00
parent 5037cd15e1
commit 107fa1c09a
2 changed files with 10 additions and 0 deletions

View File

@ -1043,6 +1043,14 @@ static int Hook_sdgundamggenerationportable_download_frame() {
return 0;
}
static int Hook_atvoffroadfurypro_download_frame() {
const u32 fb_address = currentMIPS->r[MIPS_REG_A1];
if (Memory::IsVRAMAddress(fb_address)) {
gpu->PerformMemoryDownload(fb_address, 0x00088000);
CBreakPoints::ExecMemCheck(fb_address, true, 0x00088000, currentMIPS->pc);
}
return 0;
}
#ifdef ARM
#define JITFUNC(f) (&MIPSComp::ArmJit::f)
@ -1141,6 +1149,7 @@ static const ReplacementTableEntry entries[] = {
{ "youkosohitsujimura_download_frame", &Hook_youkosohitsujimura_download_frame, 0, REPFLAG_HOOKENTER, 0x94 },
{ "tonyhawkp8_upload_tutorial_frame", &Hook_tonyhawkp8_upload_tutorial_frame, 0, REPFLAG_HOOKENTER, },
{ "sdgundamggenerationportable_download_frame", &Hook_sdgundamggenerationportable_download_frame, 0, REPFLAG_HOOKENTER, 0x34 },
{ "atvoffroadfurypro_download_frame", &Hook_atvoffroadfurypro_download_frame, 0, REPFLAG_HOOKENTER, },
{}
};

View File

@ -95,6 +95,7 @@ static const HardHashTableEntry hardcodedHashes[] = {
{ 0x06e2826e02056114, 56, "wcslen", },
{ 0x073cf0b61d3b875a, 416, "hexyzforce_monoclome_thread", }, // Hexyz Force (US)
{ 0x075fa9b234b41e9b, 32, "fmodf", },
{ 0x09ab0791e1da9647, 180, "atvoffroadfurypro_download_frame", }, // ATV Offroad Fury Pro (US)
{ 0x0a051019bdd786c3, 184, "strcasecmp", },
{ 0x0a1bed70958935d2, 644, "youkosohitsujimura_download_frame", }, // Youkoso Hitsuji-Mura Portable
{ 0x0a46dc426054bb9d, 24, "vector_add_t", },