all repos — mgba @ 93a2f160667e0bb29b544f638d224261a0a168f5

mGBA Game Boy Advance Emulator

Loading 8/16 bits from ROM
Jeffrey Pfau jeffrey@endrift.com
Mon, 08 Apr 2013 02:13:40 -0700
commit

93a2f160667e0bb29b544f638d224261a0a168f5

parent

67c00f378ae0e7a5a516e9b07f863def12c72169

1 files changed, 4 insertions(+), 0 deletions(-)

jump to
M src/gba.csrc/gba.c

@@ -129,6 +129,7 @@ case BASE_CART1:

case BASE_CART1_EX: case BASE_CART2: case BASE_CART2_EX: + return ((int16_t*) gbaMemory->rom)[(address & (SIZE_CART0 - 1)) >> 1]; break; case BASE_CART_SRAM: break;

@@ -163,6 +164,7 @@ case BASE_CART1:

case BASE_CART1_EX: case BASE_CART2: case BASE_CART2_EX: + return ((uint16_t*) gbaMemory->rom)[(address & (SIZE_CART0 - 1)) >> 1]; break; case BASE_CART_SRAM: break;

@@ -197,6 +199,7 @@ case BASE_CART1:

case BASE_CART1_EX: case BASE_CART2: case BASE_CART2_EX: + return ((int8_t*) gbaMemory->rom)[(address & (SIZE_CART0 - 1))]; break; case BASE_CART_SRAM: break;

@@ -231,6 +234,7 @@ case BASE_CART1:

case BASE_CART1_EX: case BASE_CART2: case BASE_CART2_EX: + return ((uint8_t*) gbaMemory->rom)[(address & (SIZE_CART0 - 1))]; break; case BASE_CART_SRAM: break;