nes: fixed game genie passthrough. nw.

This commit is contained in:
etabeta78 2015-01-14 07:58:42 +01:00
parent 9c2d0ed4a3
commit 65721319dc
3 changed files with 9 additions and 4 deletions

View File

@ -48,6 +48,13 @@ void nes_ggenie_device::device_start()
save_item(NAME(m_gg_bypass));
}
void nes_ggenie_device::pcb_start(running_machine &machine, UINT8 *ciram_ptr, bool cart_mounted)
{
device_nes_cart_interface::pcb_start(machine, ciram_ptr, cart_mounted);
if (m_ggslot->m_cart)
m_ggslot->pcb_start(m_ciram);
}
void nes_ggenie_device::pcb_reset()
{
m_chr_source = m_vrom_chunks ? CHRROM : CHRRAM;
@ -58,10 +65,7 @@ void nes_ggenie_device::pcb_reset()
m_gg_bypass = 0;
if (m_ggslot->m_cart)
{
m_ggslot->pcb_start(m_ciram);
m_ggslot->m_cart->pcb_reset();
}
}

View File

@ -33,6 +33,7 @@ public:
virtual machine_config_constructor device_mconfig_additions() const;
virtual void pcb_reset();
virtual void pcb_start(running_machine &machine, UINT8 *ciram_ptr, bool cart_mounted);
private:
// emulate the Game Genie!

View File

@ -216,7 +216,7 @@ public:
virtual void scanline_irq(int scanline, int vblank, int blanked) {}
virtual void pcb_reset() {} // many pcb expect specific PRG/CHR banking at start
void pcb_start(running_machine &machine, UINT8 *ciram_ptr, bool cart_mounted);
virtual void pcb_start(running_machine &machine, UINT8 *ciram_ptr, bool cart_mounted);
void pcb_reg_postload(running_machine &machine);
void nes_banks_restore();