12-in-1 + realtec mapper
[picodrive.git] / Pico / Pico.c
index c47cf19..a76c9e4 100644 (file)
@@ -64,6 +64,9 @@ int PicoReset(int hard)
 \r
   if (Pico.romsize<=0) return 1;\r
 \r
+  /* must call now, so that banking is reset, and correct vectors get fetched */\r
+  if (PicoResetHook) PicoResetHook();\r
+\r
   PicoMemReset();\r
   SekReset();\r
   // s68k doesn't have the TAS quirk, so we just globally set normal TAS handler in MCD mode (used by Batman games).\r
@@ -79,7 +82,7 @@ int PicoReset(int hard)
   Pico.video.pending_ints=0;\r
   emustatus = 0;\r
 \r
-  if(hard) {\r
+  if (hard) {\r
     // clear all memory of the emulated machine\r
     memset(&Pico.ram,0,(unsigned int)&Pico.rom-(unsigned int)&Pico.ram);\r
   }\r
@@ -142,8 +145,6 @@ int PicoReset(int hard)
 \r
   PsndReset(); // pal must be known here\r
 \r
-  if (PicoResetHook) PicoResetHook();\r
-\r
   if (PicoMCD & 1) {\r
     PicoResetMCD(hard);\r
     return 0;\r