mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-24 05:49:58 +00:00
Replace frame download in danganronpa 2
This commit is contained in:
parent
3eec3a1497
commit
d7927009d0
@ -729,6 +729,18 @@ static int Hook_bokunonatsuyasumi4_download_frame() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int Hook_danganronpa2_1_download_frame() {
|
||||
const u32 fb_base = currentMIPS->r[MIPS_REG_V0];
|
||||
const u32 fb_offset = currentMIPS->r[MIPS_REG_V1];
|
||||
const u32 fb_offset_fix = fb_offset & 0xFFFFFFFC;
|
||||
const u32 fb_address = fb_base + fb_offset_fix;
|
||||
if (Memory::IsVRAMAddress(fb_address)) {
|
||||
gpu->PerformMemoryDownload(fb_address, 0x00088000);
|
||||
CBreakPoints::ExecMemCheck(fb_address, true, 0x00088000, currentMIPS->pc);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Can either replace with C functions or functions emitted in Asm/ArmAsm.
|
||||
static const ReplacementTableEntry entries[] = {
|
||||
// TODO: I think some games can be helped quite a bit by implementing the
|
||||
@ -789,6 +801,7 @@ static const ReplacementTableEntry entries[] = {
|
||||
{ "soranokiseki_fc_download_frame", &Hook_soranokiseki_fc_download_frame, 0, REPFLAG_HOOKENTER, 0x180 },
|
||||
{ "soranokiseki_sc_download_frame", &Hook_soranokiseki_sc_download_frame, 0, REPFLAG_HOOKENTER, },
|
||||
{ "bokunonatsuyasumi4_download_frame", &Hook_bokunonatsuyasumi4_download_frame, 0, REPFLAG_HOOKENTER, 0x8C },
|
||||
{ "danganronpa2_1_download_frame", &Hook_danganronpa2_1_download_frame, 0, REPFLAG_HOOKENTER, 0x68 },
|
||||
{}
|
||||
};
|
||||
|
||||
|
@ -327,6 +327,7 @@ static const HardHashTableEntry hardcodedHashes[] = {
|
||||
{ 0xafc9968e7d246a5e, 1588, "atan", },
|
||||
{ 0xafcb7dfbc4d72588, 44, "vector_transform_3x4", },
|
||||
{ 0xb07f9d82d79deea9, 536, "brandish_download_frame", }, // Brandish, and Sora no kiseki 3rd
|
||||
{ 0xb09c9bc1343a774c, 456, "danganronpa2_1_download_frame", }, // Danganronpa 2
|
||||
{ 0xb0db731f27d3aa1b, 40, "vmax_s", },
|
||||
{ 0xb0ef265e87899f0a, 32, "vector_divide_t_s", },
|
||||
{ 0xb183a37baa12607b, 32, "vscl_t", },
|
||||
|
Loading…
Reference in New Issue
Block a user