summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/drivers/ninjaw.cpp
diff options
context:
space:
mode:
author angelosa <salese_corp_ltd@email.it>2017-08-30 11:10:29 +0200
committer angelosa <salese_corp_ltd@email.it>2017-08-30 11:11:35 +0200
commit2ba92b043b6511adeecf039affb8bace37001845 (patch)
tree63af7c2ed7b1fcbb502c28b4b088cd6b9c4ef805 /src/mame/drivers/ninjaw.cpp
parentd46093315a9496f31072d53ef164f0b2d53a76ec (diff)
ninjaw.cpp: saner interleave CPU timings, attempt to fix missing enemies bug in Ninja Warriors [Angelo Salese]
Diffstat (limited to 'src/mame/drivers/ninjaw.cpp')
-rw-r--r--src/mame/drivers/ninjaw.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/mame/drivers/ninjaw.cpp b/src/mame/drivers/ninjaw.cpp
index 27e91125712..a8cc0ba4eed 100644
--- a/src/mame/drivers/ninjaw.cpp
+++ b/src/mame/drivers/ninjaw.cpp
@@ -742,7 +742,11 @@ static MACHINE_CONFIG_START( ninjaw )
MCFG_CPU_PROGRAM_MAP(ninjaw_slave_map)
MCFG_CPU_VBLANK_INT_DRIVER("lscreen", ninjaw_state, irq4_line_hold)
- MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* CPU slices */
+ // TODO: if CPUs are unsynched then seldomly stages loads up with no enemies
+ // Let's use a better timer (was 6000 before) based off actual CPU timing.
+ // Might as well bump the divider in case the bug still occurs before resorting to perfect CPU.
+ MCFG_QUANTUM_TIME(attotime::from_hz(16000000/1024)) /* CPU slices */
+ //MCFG_QUANTUM_PERFECT_CPU("maincpu")
MCFG_DEVICE_ADD("tc0040ioc", TC0040IOC, 0)
MCFG_TC0040IOC_READ_0_CB(IOPORT("DSWA"))
@@ -863,7 +867,8 @@ static MACHINE_CONFIG_START( darius2 )
MCFG_CPU_PROGRAM_MAP(darius2_slave_map)
MCFG_CPU_VBLANK_INT_DRIVER("lscreen", ninjaw_state, irq4_line_hold)
- MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* CPU slices */
+ MCFG_QUANTUM_TIME(attotime::from_hz(16000000/1024)) /* CPU slices */
+ //MCFG_QUANTUM_PERFECT_CPU("maincpu")
MCFG_DEVICE_ADD("tc0040ioc", TC0040IOC, 0)
MCFG_TC0040IOC_READ_0_CB(IOPORT("DSWA"))