FSkip behaviour changed, RefreshLine_PPU_hook optimized
[fceu.git] / ines.c
diff --git a/ines.c b/ines.c
index 6665a13..ad1e926 100644 (file)
--- a/ines.c
+++ b/ines.c
@@ -80,7 +80,7 @@ static DECLFR(TrainerRead)
  return(trainerpoo[A&0x1FF]);\r
 }\r
 \r
-static void iNESGI(int h)\r
+static void iNESGI(int h, void *param)\r
 {\r
  switch(h)\r
  {\r
@@ -121,7 +121,16 @@ static void iNESGI(int h)
                 if(trainerpoo) {FCEU_gfree(trainerpoo);trainerpoo=0;}\r
                }\r
                break;\r
-     }\r
+  case GI_INFOSTRING:\r
+               {\r
+                int MapperNo;\r
+                MapperNo = (head.ROM_type>>4);\r
+                MapperNo|=(head.ROM_type2&0xF0);\r
+                sprintf(param, "iNES, %s, Mapper: %d%s%s", PAL?"PAL":"NTSC",\r
+                       MapperNo, (head.ROM_type&2)?", BB":"", (head.ROM_type&4)?", T":"");\r
+               }\r
+               break;\r
+ }\r
 }\r
 \r
 uint32 iNESGameCRC32=0;\r
@@ -916,6 +925,10 @@ static void iNESPower(void)
         setprg8r(1,0x6000,0);\r
 \r
         SetReadHandler(0x6000,0x7FFF,AWRAM);\r
+#ifdef ASM_6502\r
+        // asm code needs pages to be set again..\r
+        Page[12]=Page[13]=Page[14]=Page[15]=WRAM-0x6000;\r
+#endif\r
         SetWriteHandler(0x6000,0x7FFF,BWRAM);\r
         FCEU_CheatAddRAM(8,0x6000,WRAM);\r
 \r
@@ -1106,8 +1119,3 @@ static int NewiNES_Init(int num)
  return(0);\r
 }\r
 \r
-iNES_HEADER *iNESGetHead(void)\r
-{\r
-       return &head;\r
-}\r
-\r