#define VRC3_prg regByte[0] #define VRC3_latch regWord[0] #define VRC3_mode regByte[1] #define VRC3_count regWord[1] static void VRC3_sync() { int AND =prgAND >>1; int OR =prgOR >>1; setprg16(0x8000, VRC3_prg &AND | OR &~AND); setprg16(0xC000, AND | OR &~AND); setchr8(0); setmirror(mapperFlags &4? MI_H: MI_V); } static DECLFW(VRC3_writeReg) { int shift; switch(A &0xF000) { case 0x8000: case 0x9000: case 0xA000: case 0xB000: V &=0xF; shift =A >>10 &0xC; VRC3_latch =VRC3_latch &~(0xF <