/* bit 0 = bank switch bit 1 = ? bit 2 = ? bit 3 = ? bit 4 = ? bit 5 = graphics tile offset bit 6 = scroll y hi bit 7 = ? */ static WRITE8_HANDLER( vb_bankswitch_w ) { unsigned char *RAM = memory_region(REGION_CPU1); memory_set_bankptr( 1,&RAM[ 0x10000 + ( 0x4000 * ( data & 1 ) ) ] ); if (vball_gfxset != ((data & 0x20) ^ 0x20)) { vball_gfxset = (data & 0x20) ^ 0x20; vb_mark_all_dirty(); } vb_scrolly_hi = (data & 0x40)<<2; }
/* bit 0 = bank switch bit 1 = ? bit 2 = ? bit 3 = ? bit 4 = ? bit 5 = graphics tile offset bit 6 = scroll y hi bit 7 = ? */ static WRITE8_HANDLER( vb_bankswitch_w ) { vball_state *state = space->machine().driver_data<vball_state>(); UINT8 *RAM = space->machine().region("maincpu")->base(); memory_set_bankptr(space->machine(), "bank1", &RAM[0x10000 + (0x4000 * (data & 1))]); if (state->m_gfxset != ((data & 0x20) ^ 0x20)) { state->m_gfxset = (data & 0x20) ^ 0x20; vb_mark_all_dirty(space->machine()); } state->m_vb_scrolly_hi = (data & 0x40) << 2; }