From 9d475a3ccb5b2e1e206cf4c219ec5984cec3574f Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Mon, 20 Jul 2015 21:15:34 -0700 Subject: Full support for Sega mapper when it comes to data. Code in remapped sections may not work reliably. SSF2 now works. --- gst.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'gst.c') diff --git a/gst.c b/gst.c index 28cc4ca..48dbd0e 100644 --- a/gst.c +++ b/gst.c @@ -100,7 +100,7 @@ uint32_t m68k_load_gst(m68k_context * context, FILE * gstfile) return 0; } for(curpos = buffer; curpos < (buffer + sizeof(buffer)); curpos += sizeof(uint16_t)) { - context->mem_pointers[1][i++] = read_be_16(curpos); + ram[i++] = read_be_16(curpos); } } return pc; @@ -141,7 +141,7 @@ uint8_t m68k_save_gst(m68k_context * context, uint32_t pc, FILE * gstfile) fseek(gstfile, GST_68K_RAM, SEEK_SET); for (int i = 0; i < (32*1024);) { for(curpos = buffer; curpos < (buffer + sizeof(buffer)); curpos += sizeof(uint16_t)) { - write_be_16(curpos, context->mem_pointers[1][i++]); + write_be_16(curpos, ram[i++]); } if (fwrite(buffer, 1, sizeof(buffer), gstfile) != sizeof(buffer)) { fputs("Failed to write 68K RAM to savestate\n", stderr); -- cgit v1.2.3