From 0ef0afed15d98c5fc9ec026fe14bbafd8bfd1e66 Mon Sep 17 00:00:00 2001 From: zeromus Date: Thu, 11 Jun 2009 04:33:11 +0000 Subject: [PATCH] try a little hack to fix tomb raider underworld savefile which was writing past its 512B limit --- desmume/src/mc.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/desmume/src/mc.cpp b/desmume/src/mc.cpp index adcc62c42..a833d781a 100644 --- a/desmume/src/mc.cpp +++ b/desmume/src/mc.cpp @@ -397,12 +397,13 @@ u8 BackupDevice::data_command(u8 val) addr |= val; addr_counter++; //if(addr_counter==addr_size) printf("ADR: %08X\n",addr); - //why does tomb raider underworld access 0x180 and go clear through to 0x280? - //should this wrap around at 0 or at 0x100? - //if(addr_size == 1) addr &= 0x1FF; } else { + //why does tomb raider underworld access 0x180 and go clear through to 0x280? + //should this wrap around at 0 or at 0x100? + if(addr_size == 1) addr &= 0x1FF; + //address is complete ensure(addr+1); if(com == BM_CMD_READLOW)