mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-04-18 03:31:31 +12:00
[ActionReplay] Add 16-bit writes
This commit is contained in:
parent
97f8ea6cfd
commit
8e45b8c324
1 changed files with 10 additions and 1 deletions
|
@ -42,7 +42,16 @@ void ActionReplay::runInstruction(const Cheat& cheat, u32 instruction) {
|
||||||
const u32 type = instruction >> 28;
|
const u32 type = instruction >> 28;
|
||||||
|
|
||||||
switch (type) {
|
switch (type) {
|
||||||
// 8 bit write to [XXXXXXX + offset]
|
// 16-bit write to [XXXXXXX + offset]
|
||||||
|
case 0x1: {
|
||||||
|
const u32 baseAddr = Helpers::getBits<0, 28>(instruction);
|
||||||
|
const u16 value = u16(cheat[pc++]);
|
||||||
|
write16(baseAddr + *activeOffset, value);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// 8-bit write to [XXXXXXX + offset]
|
||||||
case 0x2: {
|
case 0x2: {
|
||||||
const u32 baseAddr = Helpers::getBits<0, 28>(instruction);
|
const u32 baseAddr = Helpers::getBits<0, 28>(instruction);
|
||||||
const u8 value = u8(cheat[pc++]);
|
const u8 value = u8(cheat[pc++]);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue