Exemple #1
0
static DECLFW(Mapper76_write)
{
        switch(A&0xE001){
        case 0x8000:
         MMC3_cmd = V;
         break;
        case 0x8001:
                switch(MMC3_cmd&0x07){
                case 2: VROM_BANK2(0x000,V);break;
                case 3: VROM_BANK2(0x800,V);break;
                case 4: VROM_BANK2(0x1000,V);break;
                case 5: VROM_BANK2(0x1800,V);break;
                case 6:
                        if(MMC3_cmd&0x40) ROM_BANK8(0xC000,V);
                        else ROM_BANK8(0x8000,V);
                        break;
                case 7: ROM_BANK8(0xA000,V);
                        break;
               }
               break;
        case 0xA000:
        MIRROR_SET(V&1);
        break;
 }
}
Exemple #2
0
void Mapper46_init(void)
{
 MIRROR_SET(0);
 ROM_BANK32(0);
 SetWriteHandler(0x8000,0xffff,Mapper46_write);
 SetWriteHandler(0x6000,0x7fff,Mapper46_writel);
}
Exemple #3
0
static DECLFW(Mapper202_write)
{
 int tmp=(A>>1)&0x7;

 MIRROR_SET(A&1);
 ROM_BANK16(0x8000,tmp);
 ROM_BANK16(0xc000,tmp+(((tmp&0x6)==0x6)?1:0));
 VROM_BANK8(tmp);
}
Exemple #4
0
static DECLFW(Mapper32_write)
{
 switch(A>>12)
 {
  case 0x8:
           mapbyte1[1]=V;
           if(IREMCon) {ROM_BANK8(0xc000,V);ROM_BANK8(0x8000,~1);}
           else {ROM_BANK8(0x8000,V);ROM_BANK8(0xc000,~1);}
           break;
  case 0x9:IREMCon=(V>>1)&1;
           if(IREMCon) {ROM_BANK8(0xc000,mapbyte1[1]);ROM_BANK8(0x8000,~1);}
           else {ROM_BANK8(0x8000,mapbyte1[1]); ROM_BANK8(0xc000,~1);}
           MIRROR_SET(V&1);
           break;
  case 0xa:ROM_BANK8(0xA000,V);
           break;
 }

 if((A&0xF000)==0xb000)
  VROM_BANK1((A&0x7)<<10,V);
}