all repos — mgba @ 029638ae99d948c4a759f4446eed0e0266b3d0aa

mGBA Game Boy Advance Emulator

GBA Memory: Fix writing to OBJ memory in modes 3 and 5
Vicki Pfau vi@endrift.com
Tue, 30 Apr 2019 17:45:38 -0700
commit

029638ae99d948c4a759f4446eed0e0266b3d0aa

parent

d54a36c66e542a3d48011f6627427b998f498321

2 files changed, 2 insertions(+), 1 deletions(-)

jump to
M CHANGESCHANGES

@@ -5,6 +5,7 @@ - GBA DMA: Fix DMA0-2 lengths (fixes mgba.io/i/1344)

- GB Video: Fix window y changing mid-window (fixes mgba.io/i/1345) - GB Video: Fix more window edge cases (fixes mgba.io/i/1346) - GB Timer: Fix timing adjustments when writing to TAC (fixes mgba.io/i/1340) + - GBA Memory: Fix writing to OBJ memory in modes 3 and 5 Other fixes: - Qt: More app metadata fixes - Qt: Fix load recent from archive (fixes mgba.io/i/1325)
M src/gba/memory.csrc/gba/memory.c

@@ -938,7 +938,7 @@ case REGION_PALETTE_RAM:

GBAStore16(cpu, address & ~1, ((uint8_t) value) | ((uint8_t) value << 8), cycleCounter); break; case REGION_VRAM: - if ((address & 0x0001FFFF) >= ((GBARegisterDISPCNTGetMode(gba->memory.io[REG_DISPCNT >> 1]) == 4) ? 0x00014000 : 0x00010000)) { + if ((address & 0x0001FFFF) >= ((GBARegisterDISPCNTGetMode(gba->memory.io[REG_DISPCNT >> 1]) >= 3) ? 0x00014000 : 0x00010000)) { // TODO: check BG mode mLOG(GBA_MEM, GAME_ERROR, "Cannot Store8 to OBJ: 0x%08X", address); break;