Merge pull request #244 from retro-wertz/fix_gba_cheats

Fix cheats not working in GBA
This commit is contained in:
Zach Bacon 2018-06-05 21:50:22 -04:00 committed by GitHub
commit 1d4dacc6f9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 7 deletions

View File

@ -2464,14 +2464,14 @@ void cheatsAddCBACode(const char* code, const char* desc)
sscanf(buffer, "%x", &value);
uint8_t array[8] = {
static_cast<uint8_t>(address & 255,
(address >> 8) & 255,
(address >> 16) & 255,
(address >> 24) & 255,
(value & 255),
(value >> 8) & 255,
(uint8_t)(address & 255),
(uint8_t)((address >> 8) & 255),
(uint8_t)((address >> 16) & 255),
(uint8_t)((address >> 24) & 255),
(uint8_t)(value & 255),
(uint8_t)((value >> 8) & 255),
0,
0)
0
};
if (cheatsCBAGetCount() == 0 && (address >> 28) == 9) {