X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?p=fceu.git;a=blobdiff_plain;f=mappers%2F24and26.c;h=50f732a7d35f04ad318776bdfec8c907e7789895;hp=575e5e63884418332bffc4cd842698923d623ad1;hb=4fdfab079f3f006ae215ab453072a25588aa951d;hpb=c62d28102c77e19c291c78bf6bf7f0a81abd54b9 diff --git a/mappers/24and26.c b/mappers/24and26.c index 575e5e6..50f732a 100644 --- a/mappers/24and26.c +++ b/mappers/24and26.c @@ -95,7 +95,8 @@ DECLFW(Mapper24_write) switch(A&0xF003) { - case 0x8000:ROM_BANK16(0x8000,V);break; + case 0x8000:ROM_BANK16(0x8000,V); + X6502_Rebase();break; case 0xB003: switch(V&0xF) { @@ -105,7 +106,8 @@ DECLFW(Mapper24_write) case 0xC:onemir(1);break; } break; - case 0xC000:ROM_BANK8(0xC000,V);break; + case 0xC000:ROM_BANK8(0xC000,V); + X6502_Rebase();break; case 0xD000:VROM_BANK1(0x0000,V);break; case 0xD001:VROM_BANK1(0x0400,V);break; case 0xD002:VROM_BANK1(0x0800,V);break; @@ -135,8 +137,8 @@ static void DoSQV1(void) int V; int32 start,end; - start=CVBC[0]; - end=(timestamp<<16)/soundtsinc; + start=CVBC[0]; + end=(SOUNDTS<<16)/soundtsinc; if(end<=start) return; CVBC[0]=end; @@ -150,7 +152,7 @@ static void DoSQV1(void) } else { - unsigned long dcycs; + unsigned long dcycs; freq=(((VPSG[0x2]|((VPSG[0x3]&15)<<8))+1)); inc=(long double)((unsigned long)((FSettings.SndRate OVERSAMPLE)<<12))/((long double)PSG_base/freq); switch(VPSG[0]&0x70) @@ -183,7 +185,7 @@ static void DoSQV2(void) int32 start,end; start=CVBC[1]; - end=(timestamp<<16)/soundtsinc; + end=(SOUNDTS<<16)/soundtsinc; if(end<=start) return; CVBC[1]=end; @@ -229,7 +231,7 @@ static void DoSawV(void) int32 start,end; start=CVBC[2]; - end=(timestamp<<16)/soundtsinc; + end=(SOUNDTS<<16)/soundtsinc; if(end<=start) return; CVBC[2]=end; @@ -260,7 +262,7 @@ static void DoSawV(void) b3=0; phaseacc=0; } - if(saw1phaseacc<=0) + if(saw1phaseacc<=0) goto rea; duff=(((phaseacc>>3)&0x1f)<<4); } @@ -292,9 +294,9 @@ void VRC6SoundC(void) { for(x=000;x<0x1000;x+=4) { - SetWriteHandler(0x9000+x,0x9002+x,0); - SetWriteHandler(0xa000+x,0xa002+x,0); - SetWriteHandler(0xb000+x,0xb002+x,0); + SetWriteHandler(0x9000+x,0x9002+x,0); + SetWriteHandler(0xa000+x,0xa002+x,0); + SetWriteHandler(0xb000+x,0xb002+x,0); } } }