Skip to content

Commit

Permalink
games: Add Resident Evil: Revelations 2 [EU/US/JP] IB res. patch
Browse files Browse the repository at this point in the history
Signed-off-by: Michal Chvila <miso.chvila@gmail.com>
  • Loading branch information
Electry committed Nov 3, 2018
1 parent 5e6b3c9 commit 4dfc0d6
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ NOTE: If some options are left out, the plugin will use their default values.
| ![](https://placehold.it/20/eeee22/000000?text=+) | Ratchet & Clank 2: Locked and Loaded / Going Commando | PCSF00485 <br/> PCSF00482 <br/> PCSA00133 | Framebuffer | 720x408 | [#121](https://github.com/Electry/VitaGrafix/issues/121) |
| ![](https://placehold.it/20/eeee22/000000?text=+) | Ratchet & Clank 3 / Up Your Arsenal | PCSF00486 <br/> PCSF00482 <br/> PCSA00133 | Framebuffer | 720x408 | [#121](https://github.com/Electry/VitaGrafix/issues/121) |
| ![](https://placehold.it/20/22bb22/000000?text=+) | Ratchet & Clank: QForce / Full Frontal Assault | PCSF00191 <br/> PCSA00086 | Framebuffer | 720x408 | |
| ![](https://placehold.it/20/22bb22/000000?text=+) | Resident Evil: Revelations 2 | PCSF00728 <br/> PCSE00608 <br/> PCSG00594 | Internal res. | 720x408 | |
| ![](https://placehold.it/20/22bb22/000000?text=+) | Ridge Racer | PCSB00048 <br/> PCSE00001 <br/> PCSG00001 | Internal res. | 720x408 | |
| ![](https://placehold.it/20/22bb22/000000?text=+) | Sly Cooper and the Thievius Raccoonus | PCSF00269 <br/> PCSF00338 <br/> PCSA00095 <br/> PCSA00096 <br/> | Framebuffer <br/> FPS cap | 720x408 <br/> 30 | |
| ![](https://placehold.it/20/22bb22/000000?text=+) | Sly Cooper 2: Band of Thieves | PCSF00270 <br/> PCSF00338 <br/> PCSA00095 <br/> PCSA00097 <br/> | Framebuffer <br/> FPS cap | 960x544 <br/> 30 | |
Expand Down
21 changes: 21 additions & 0 deletions patch.c
Original file line number Diff line number Diff line change
Expand Up @@ -1106,4 +1106,25 @@ void vgPatchGame() {
vgInjectData(0, g_main.offset[0] + 18, &movs_r1_h2, sizeof(movs_r1_h2));
}
}
//
// Resident Evil: Revelations 2
//
else if (vgPatchIsGame("PCSF00728", SELF_EBOOT, NID_ANY) || // EU [1.04]
vgPatchIsGame("PCSE00608", SELF_EBOOT, NID_ANY) || // US [1.04]
vgPatchIsGame("PCSG00594", SELF_EBOOT, NID_ANY)) { // JP [1.04]
vgConfigSetSupported(FT_UNSUPPORTED, FT_ENABLED, FT_UNSUPPORTED);

if (vgConfigIsIbEnabled()) {
uint8_t movs_r1_width[4], movs_r1_height[4];
vgMakeThumb2_T2_MOV(1, 1, g_main.config.ib[0].width, movs_r1_width);
vgMakeThumb2_T2_MOV(1, 1, g_main.config.ib[0].height, movs_r1_height);

vgPatchAddOffset("PCSF00728", SELF_EBOOT, NID_ANY, 1, 0xCCFE76);
vgPatchAddOffset("PCSE00608", SELF_EBOOT, NID_ANY, 1, 0xCCFE7A);
vgPatchAddOffset("PCSG00594", SELF_EBOOT, NID_ANY, 1, 0xCCFF3A);

vgInjectData(0, g_main.offset[0], &movs_r1_width, sizeof(movs_r1_width));
vgInjectData(0, g_main.offset[0] + 8, &movs_r1_height, sizeof(movs_r1_height));
}
}
}

0 comments on commit 4dfc0d6

Please sign in to comment.