mirror of
https://github.com/holub/mame
synced 2025-04-20 23:42:22 +03:00
namcos22: separate classes for some of the ss22 games
This commit is contained in:
parent
4278ce8014
commit
be56eaed49
@ -1878,7 +1878,7 @@ void namcos22s_state::namcos22s_am(address_map &map)
|
||||
|
||||
|
||||
// Time Crisis gun
|
||||
u16 namcos22s_state::timecris_gun_r(offs_t offset)
|
||||
u16 timecris_state::gun_r(offs_t offset)
|
||||
{
|
||||
u16 xpos = m_opt[0]->read();
|
||||
u16 ypos = m_opt[1]->read();
|
||||
@ -1907,20 +1907,20 @@ u16 namcos22s_state::timecris_gun_r(offs_t offset)
|
||||
}
|
||||
}
|
||||
|
||||
void namcos22s_state::timecris_am(address_map &map)
|
||||
void timecris_state::timecris_am(address_map &map)
|
||||
{
|
||||
namcos22s_am(map);
|
||||
map(0x430000, 0x43000f).r(FUNC(namcos22s_state::timecris_gun_r)).umask32(0xffff0000);
|
||||
map(0x430000, 0x43000f).r(FUNC(timecris_state::gun_r)).umask32(0xffff0000);
|
||||
}
|
||||
|
||||
|
||||
// Alpine Surfer protection
|
||||
u32 namcos22s_state::alpinesa_prot_r()
|
||||
u32 alpine_state::alpinesa_prot_r()
|
||||
{
|
||||
return m_alpinesa_protection;
|
||||
}
|
||||
|
||||
void namcos22s_state::alpinesa_prot_w(u32 data)
|
||||
void alpine_state::alpinesa_prot_w(u32 data)
|
||||
{
|
||||
switch (data)
|
||||
{
|
||||
@ -1941,11 +1941,11 @@ void namcos22s_state::alpinesa_prot_w(u32 data)
|
||||
}
|
||||
}
|
||||
|
||||
void namcos22s_state::alpinesa_am(address_map &map)
|
||||
void alpine_state::alpinesa_am(address_map &map)
|
||||
{
|
||||
namcos22s_am(map);
|
||||
map(0x200000, 0x200003).r(FUNC(namcos22s_state::alpinesa_prot_r));
|
||||
map(0x300000, 0x300003).w(FUNC(namcos22s_state::alpinesa_prot_w));
|
||||
map(0x200000, 0x200003).r(FUNC(alpine_state::alpinesa_prot_r));
|
||||
map(0x300000, 0x300003).w(FUNC(alpine_state::alpinesa_prot_w));
|
||||
}
|
||||
|
||||
|
||||
@ -2842,12 +2842,12 @@ void namcos22_state::handle_cybrcomm_io()
|
||||
|
||||
// Alpine skiing games
|
||||
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(namcos22s_state::alpine_steplock_callback)
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(alpine_state::alpine_steplock_callback)
|
||||
{
|
||||
m_motor_status = param;
|
||||
}
|
||||
|
||||
void namcos22s_state::alpine_mcu_port4_w(u8 data)
|
||||
void alpine_state::alpine_mcu_port4_w(u8 data)
|
||||
{
|
||||
if (~m_mcu_iocontrol & data & 0x20)
|
||||
{
|
||||
@ -2878,13 +2878,13 @@ void namcos22s_state::alpine_mcu_port4_w(u8 data)
|
||||
|
||||
// Prop Cycle
|
||||
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(namcos22s_state::propcycl_pedal_interrupt)
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(propcycl_state::pedal_interrupt)
|
||||
{
|
||||
m_mcu->set_input_line(M37710_LINE_TIMERA3OUT, param ? ASSERT_LINE : CLEAR_LINE);
|
||||
m_mcu->pulse_input_line(M37710_LINE_TIMERA3IN, m_mcu->minimum_quantum_time());
|
||||
}
|
||||
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(namcos22s_state::propcycl_pedal_update)
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(propcycl_state::pedal_update)
|
||||
{
|
||||
// arbitrary timer for reading optical pedal
|
||||
int pedal = m_opt[0]->read() - 0x80;
|
||||
@ -2902,25 +2902,25 @@ TIMER_DEVICE_CALLBACK_MEMBER(namcos22s_state::propcycl_pedal_update)
|
||||
const int range = 100000;
|
||||
|
||||
attotime freq = attotime::from_usec(base + range * (1.0 / abs(pedal)));
|
||||
m_pc_pedal_interrupt->adjust(std::min(freq, m_pc_pedal_interrupt->remaining()), pedal < 0, freq);
|
||||
m_pedal_interrupt->adjust(std::min(freq, m_pedal_interrupt->remaining()), pedal < 0, freq);
|
||||
}
|
||||
else
|
||||
{
|
||||
// not moving
|
||||
m_pc_pedal_interrupt->adjust(attotime::never, 0, attotime::never);
|
||||
m_pedal_interrupt->adjust(attotime::never, 0, attotime::never);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Armadillo Racing
|
||||
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(namcos22s_state::adillor_trackball_interrupt)
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(adillor_state::trackball_interrupt)
|
||||
{
|
||||
m_mcu->set_input_line((param & 1) ? M37710_LINE_TIMERA2OUT : M37710_LINE_TIMERA3OUT, (param & 2) ? ASSERT_LINE : CLEAR_LINE);
|
||||
m_mcu->pulse_input_line((param & 1) ? M37710_LINE_TIMERA2IN : M37710_LINE_TIMERA3IN, m_mcu->minimum_quantum_time());
|
||||
}
|
||||
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(namcos22s_state::adillor_trackball_update)
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(adillor_state::trackball_update)
|
||||
{
|
||||
// arbitrary timer for reading optical trackball
|
||||
// -1.0 .. 1.0
|
||||
@ -2948,12 +2948,12 @@ TIMER_DEVICE_CALLBACK_MEMBER(namcos22s_state::adillor_trackball_update)
|
||||
if (t[axis] > (1.0 / range))
|
||||
{
|
||||
attotime freq = attotime::from_hz(base + range * t[axis]);
|
||||
m_ar_tb_interrupt[axis]->adjust(std::min(freq, m_ar_tb_interrupt[axis]->remaining()), params[axis], freq);
|
||||
m_trackball_interrupt[axis]->adjust(std::min(freq, m_trackball_interrupt[axis]->remaining()), params[axis], freq);
|
||||
}
|
||||
else
|
||||
{
|
||||
// not moving
|
||||
m_ar_tb_interrupt[axis]->adjust(attotime::never, axis, attotime::never);
|
||||
m_trackball_interrupt[axis]->adjust(attotime::never, axis, attotime::never);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -3218,7 +3218,7 @@ INPUT_PORTS_END
|
||||
/*********************************************************************************************/
|
||||
|
||||
template <int N>
|
||||
READ_LINE_MEMBER(namcos22s_state::alpine_motor_r)
|
||||
READ_LINE_MEMBER(alpine_state::alpine_motor_r)
|
||||
{
|
||||
return BIT(m_motor_status, N);
|
||||
}
|
||||
@ -3232,8 +3232,8 @@ static INPUT_PORTS_START( alpiner )
|
||||
PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_START1 ) // Decision / View Change
|
||||
PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_16WAY // L Selection
|
||||
PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT) PORT_16WAY // R Selection
|
||||
PORT_BIT( 0x0080, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(namcos22s_state, alpine_motor_r<0>) // steps are free
|
||||
PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(namcos22s_state, alpine_motor_r<1>) // steps are locked
|
||||
PORT_BIT( 0x0080, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(alpine_state, alpine_motor_r<0>) // steps are free
|
||||
PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(alpine_state, alpine_motor_r<1>) // steps are locked
|
||||
PORT_BIT( 0xfe00, IP_ACTIVE_LOW, IPT_UNKNOWN )
|
||||
|
||||
PORT_START("ADC.0")
|
||||
@ -3725,13 +3725,19 @@ void namcos22s_state::machine_start()
|
||||
|
||||
save_item(NAME(m_spotram_enable));
|
||||
save_item(NAME(m_spotram_address));
|
||||
save_item(NAME(m_alpinesa_protection));
|
||||
save_item(NAME(m_motor_status));
|
||||
save_item(NAME(m_mcu_iocontrol));
|
||||
save_item(NAME(m_mcu_outdata));
|
||||
save_item(NAME(m_chipselect));
|
||||
}
|
||||
|
||||
void alpine_state::machine_start()
|
||||
{
|
||||
namcos22s_state::machine_start();
|
||||
|
||||
save_item(NAME(m_alpinesa_protection));
|
||||
save_item(NAME(m_motor_status));
|
||||
}
|
||||
|
||||
// System22
|
||||
void namcos22_state::namcos22(machine_config &config)
|
||||
{
|
||||
@ -3846,20 +3852,19 @@ void namcos22s_state::airco22b(machine_config &config)
|
||||
m_c352->add_route(2, "bodysonic", 0.50); // to subwoofer behind back
|
||||
}
|
||||
|
||||
void namcos22s_state::alpine(machine_config &config)
|
||||
void alpine_state::alpine(machine_config &config)
|
||||
{
|
||||
namcos22s(config);
|
||||
|
||||
m_mcu->p4_out_cb().set(FUNC(namcos22s_state::alpine_mcu_port4_w));
|
||||
|
||||
TIMER(config, m_motor_timer).configure_generic(FUNC(namcos22s_state::alpine_steplock_callback));
|
||||
m_mcu->p4_out_cb().set(FUNC(alpine_state::alpine_mcu_port4_w));
|
||||
TIMER(config, m_motor_timer).configure_generic(FUNC(alpine_state::alpine_steplock_callback));
|
||||
}
|
||||
|
||||
void namcos22s_state::alpinesa(machine_config &config)
|
||||
void alpine_state::alpinesa(machine_config &config)
|
||||
{
|
||||
alpine(config);
|
||||
|
||||
m_maincpu->set_addrmap(AS_PROGRAM, &namcos22s_state::alpinesa_am);
|
||||
m_maincpu->set_addrmap(AS_PROGRAM, &alpine_state::alpinesa_am);
|
||||
}
|
||||
|
||||
void namcos22s_state::cybrcycc(machine_config &config)
|
||||
@ -3878,11 +3883,11 @@ void namcos22s_state::dirtdash(machine_config &config)
|
||||
m_c352->add_route(3, "road", 1.00);
|
||||
}
|
||||
|
||||
void namcos22s_state::timecris(machine_config &config)
|
||||
void timecris_state::timecris(machine_config &config)
|
||||
{
|
||||
namcos22s(config);
|
||||
|
||||
m_maincpu->set_addrmap(AS_PROGRAM, &namcos22s_state::timecris_am);
|
||||
m_maincpu->set_addrmap(AS_PROGRAM, &timecris_state::timecris_am);
|
||||
}
|
||||
|
||||
void namcos22s_state::tokyowar(machine_config &config)
|
||||
@ -3896,21 +3901,21 @@ void namcos22s_state::tokyowar(machine_config &config)
|
||||
m_c352->add_route(3, "seat", 1.00);
|
||||
}
|
||||
|
||||
void namcos22s_state::propcycl(machine_config &config)
|
||||
void propcycl_state::propcycl(machine_config &config)
|
||||
{
|
||||
namcos22s(config);
|
||||
|
||||
TIMER(config, "pc_p_upd").configure_periodic(FUNC(namcos22s_state::propcycl_pedal_update), attotime::from_msec(20));
|
||||
TIMER(config, m_pc_pedal_interrupt).configure_generic(FUNC(namcos22s_state::propcycl_pedal_interrupt));
|
||||
TIMER(config, "pedal_update").configure_periodic(FUNC(propcycl_state::pedal_update), attotime::from_msec(20));
|
||||
TIMER(config, m_pedal_interrupt).configure_generic(FUNC(propcycl_state::pedal_interrupt));
|
||||
}
|
||||
|
||||
void namcos22s_state::adillor(machine_config &config)
|
||||
void adillor_state::adillor(machine_config &config)
|
||||
{
|
||||
namcos22s(config);
|
||||
|
||||
TIMER(config, "ar_tb_upd").configure_periodic(FUNC(namcos22s_state::adillor_trackball_update), attotime::from_msec(20));
|
||||
TIMER(config, "trackball_update").configure_periodic(FUNC(adillor_state::trackball_update), attotime::from_msec(20));
|
||||
for (int i = 0; i < 2; i++)
|
||||
TIMER(config, m_ar_tb_interrupt[i]).configure_generic(FUNC(namcos22s_state::adillor_trackball_interrupt));
|
||||
TIMER(config, m_trackball_interrupt[i]).configure_generic(FUNC(adillor_state::trackball_interrupt));
|
||||
}
|
||||
|
||||
|
||||
@ -6103,7 +6108,7 @@ void namcos22_state::init_cybrcomm()
|
||||
install_c74_speedup();
|
||||
}
|
||||
|
||||
void namcos22s_state::init_alpiner()
|
||||
void alpine_state::init_alpiner()
|
||||
{
|
||||
m_gametype = NAMCOS22_ALPINE_RACER;
|
||||
install_130_speedup();
|
||||
@ -6111,7 +6116,7 @@ void namcos22s_state::init_alpiner()
|
||||
m_motor_status = 2;
|
||||
}
|
||||
|
||||
void namcos22s_state::init_alpiner2()
|
||||
void alpine_state::init_alpiner2()
|
||||
{
|
||||
m_gametype = NAMCOS22_ALPINE_RACER_2;
|
||||
install_130_speedup();
|
||||
@ -6119,7 +6124,7 @@ void namcos22s_state::init_alpiner2()
|
||||
m_motor_status = 2;
|
||||
}
|
||||
|
||||
void namcos22s_state::init_alpinesa()
|
||||
void alpine_state::init_alpinesa()
|
||||
{
|
||||
m_gametype = NAMCOS22_ALPINE_SURFER;
|
||||
install_141_speedup();
|
||||
@ -6133,7 +6138,7 @@ void namcos22s_state::init_airco22()
|
||||
install_130_speedup(); // S22-BIOS ver1.20 namco all rights reserved 94/12/21
|
||||
}
|
||||
|
||||
void namcos22s_state::init_propcycl()
|
||||
void propcycl_state::init_propcycl()
|
||||
{
|
||||
u32 *ROM = (u32 *)memregion("maincpu")->base();
|
||||
|
||||
@ -6157,7 +6162,7 @@ void namcos22s_state::init_propcycl()
|
||||
install_141_speedup();
|
||||
}
|
||||
|
||||
void namcos22s_state::init_propcyclj()
|
||||
void propcycl_state::init_propcyclj()
|
||||
{
|
||||
// see init_propcycl for notes
|
||||
u32 *ROM = (u32 *)memregion("maincpu")->base();
|
||||
@ -6177,7 +6182,7 @@ void namcos22s_state::init_cybrcyc()
|
||||
install_130_speedup();
|
||||
}
|
||||
|
||||
void namcos22s_state::init_timecris()
|
||||
void timecris_state::init_timecris()
|
||||
{
|
||||
m_gametype = NAMCOS22_TIME_CRISIS;
|
||||
install_130_speedup();
|
||||
@ -6195,7 +6200,7 @@ void namcos22s_state::init_aquajet()
|
||||
install_141_speedup();
|
||||
}
|
||||
|
||||
void namcos22s_state::init_adillor()
|
||||
void adillor_state::init_adillor()
|
||||
{
|
||||
m_gametype = NAMCOS22_ARMADILLO_RACING;
|
||||
install_141_speedup();
|
||||
@ -6233,24 +6238,24 @@ GAME( 1996, victlapa, victlap, namcos22, victlap, namcos22_state, init_vi
|
||||
GAME( 1996, victlapj, victlap, namcos22, victlap, namcos22_state, init_victlap, ROT0, "Namco", "Ace Driver: Victory Lap (Rev. ADV1 Ver.C, Japan)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NODEVICE_LAN ) // 96/02/13 17:29:10
|
||||
|
||||
// System Super22 games
|
||||
GAME( 1994, alpinerd, 0, alpine, alpiner, namcos22s_state, init_alpiner, ROT0, "Namco", "Alpine Racer (Rev. AR2 Ver.D, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS )
|
||||
GAME( 1994, alpinerc, alpinerd, alpine, alpiner, namcos22s_state, init_alpiner, ROT0, "Namco", "Alpine Racer (Rev. AR2 Ver.C, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS )
|
||||
GAME( 1994, alpinerjc, alpinerd, alpine, alpiner, namcos22s_state, init_alpiner, ROT0, "Namco", "Alpine Racer (Rev. AR1 Ver.C, Japan)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS )
|
||||
GAME( 1994, alpinerd, 0, alpine, alpiner, alpine_state, init_alpiner, ROT0, "Namco", "Alpine Racer (Rev. AR2 Ver.D, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS )
|
||||
GAME( 1994, alpinerc, alpinerd, alpine, alpiner, alpine_state, init_alpiner, ROT0, "Namco", "Alpine Racer (Rev. AR2 Ver.C, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS )
|
||||
GAME( 1994, alpinerjc, alpinerd, alpine, alpiner, alpine_state, init_alpiner, ROT0, "Namco", "Alpine Racer (Rev. AR1 Ver.C, Japan)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS )
|
||||
GAME( 1995, airco22b, 0, airco22b, airco22, namcos22s_state, init_airco22, ROT0, "Namco", "Air Combat 22 (Rev. ACS1 Ver.B, Japan)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS )
|
||||
GAME( 1995, cybrcycc, 0, cybrcycc, cybrcycc, namcos22s_state, init_cybrcyc, ROT0, "Namco", "Cyber Cycles (Rev. CB2 Ver.C, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NODEVICE_LAN ) // 95/04/04
|
||||
GAME( 1995, cybrcyccj, cybrcycc, cybrcycc, cybrcycc, namcos22s_state, init_cybrcyc, ROT0, "Namco", "Cyber Cycles (Rev. CB1 Ver.C, Japan)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NODEVICE_LAN ) // 95/04/04
|
||||
GAME( 1995, dirtdash, 0, dirtdash, dirtdash, namcos22s_state, init_dirtdash, ROT0, "Namco", "Dirt Dash (Rev. DT2 Ver.B, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NOT_WORKING ) // 96/?1/0? 21:03:?6, one ROM is bad
|
||||
GAME( 1995, dirtdasha, dirtdash, dirtdash, dirtdash, namcos22s_state, init_dirtdash, ROT0, "Namco", "Dirt Dash (Rev. DT2 Ver.A, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS ) // 95/12/20 20:01:56
|
||||
GAME( 1995, dirtdashj, dirtdash, dirtdash, dirtdash, namcos22s_state, init_dirtdash, ROT0, "Namco", "Dirt Dash (Rev. DT1 Ver.A, Japan)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS ) // 95/12/20 20:06:45
|
||||
GAME( 1995, timecris, 0, timecris, timecris, namcos22s_state, init_timecris, ROT0, "Namco", "Time Crisis (Rev. TS2 Ver.B, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS ) // 96/04/02 18:48:00
|
||||
GAME( 1995, timecrisa, timecris, timecris, timecris, namcos22s_state, init_timecris, ROT0, "Namco", "Time Crisis (Rev. TS2 Ver.A, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS ) // 96/01/08 18:56:09
|
||||
GAME( 1996, propcycl, 0, propcycl, propcycl, namcos22s_state, init_propcycl, ROT0, "Namco", "Prop Cycle (Rev. PR2 Ver.A, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS ) // 96/06/18 21:22:13
|
||||
GAME( 1996, propcyclj, propcycl, propcycl, propcycl, namcos22s_state, init_propcyclj, ROT0, "Namco", "Prop Cycle (Rev. PR1 Ver.A, Japan)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS ) // 96/06/18 21:06:03
|
||||
GAME( 1996, alpinesa, 0, alpinesa, alpiner, namcos22s_state, init_alpinesa, ROT0, "Namco", "Alpine Surfer (Rev. AF2 Ver.A, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING ) // 96/07/01 15:19:23. major problems, protection?
|
||||
GAME( 1995, timecris, 0, timecris, timecris, timecris_state, init_timecris, ROT0, "Namco", "Time Crisis (Rev. TS2 Ver.B, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS ) // 96/04/02 18:48:00
|
||||
GAME( 1995, timecrisa, timecris, timecris, timecris, timecris_state, init_timecris, ROT0, "Namco", "Time Crisis (Rev. TS2 Ver.A, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS ) // 96/01/08 18:56:09
|
||||
GAME( 1996, propcycl, 0, propcycl, propcycl, propcycl_state, init_propcycl, ROT0, "Namco", "Prop Cycle (Rev. PR2 Ver.A, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS ) // 96/06/18 21:22:13
|
||||
GAME( 1996, propcyclj, propcycl, propcycl, propcycl, propcycl_state, init_propcyclj, ROT0, "Namco", "Prop Cycle (Rev. PR1 Ver.A, Japan)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS ) // 96/06/18 21:06:03
|
||||
GAME( 1996, alpinesa, 0, alpinesa, alpiner, alpine_state, init_alpinesa, ROT0, "Namco", "Alpine Surfer (Rev. AF2 Ver.A, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING ) // 96/07/01 15:19:23. major problems, protection?
|
||||
GAME( 1996, tokyowar, 0, tokyowar, tokyowar, namcos22s_state, init_tokyowar, ROT0, "Namco", "Tokyo Wars (Rev. TW2 Ver.A, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NODEVICE_LAN ) // 96/09/03 14:08:47
|
||||
GAME( 1996, tokyowarj, tokyowar, tokyowar, tokyowar, namcos22s_state, init_tokyowar, ROT0, "Namco", "Tokyo Wars (Rev. TW1 Ver.A, Japan)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NODEVICE_LAN ) // 96/09/03 14:16:29
|
||||
GAME( 1996, aquajet, 0, cybrcycc, aquajet, namcos22s_state, init_aquajet, ROT0, "Namco", "Aqua Jet (Rev. AJ2 Ver.B, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS ) // 96/09/20 14:28:30
|
||||
GAME( 1996, alpinr2b, 0, alpine, alpiner, namcos22s_state, init_alpiner2, ROT0, "Namco", "Alpine Racer 2 (Rev. ARS2 Ver.B, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NODEVICE_LAN ) // 97/01/10 17:10:59
|
||||
GAME( 1996, alpinr2a, alpinr2b, alpine, alpiner, namcos22s_state, init_alpiner2, ROT0, "Namco", "Alpine Racer 2 (Rev. ARS2 Ver.A, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NODEVICE_LAN ) // 96/12/06 13:45:05
|
||||
GAME( 1997, adillor, 0, adillor, adillor, namcos22s_state, init_adillor, ROT0, "Namco", "Armadillo Racing (Rev. AM2 Ver.A, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NODEVICE_LAN ) // 97/04/07 19:43:29
|
||||
GAME( 1997, adillorj, adillor, adillor, adillor, namcos22s_state, init_adillor, ROT0, "Namco", "Armadillo Racing (Rev. AM1 Ver.A, Japan)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NODEVICE_LAN ) // 97/04/07 19:19:41
|
||||
GAME( 1996, alpinr2b, 0, alpine, alpiner, alpine_state, init_alpiner2, ROT0, "Namco", "Alpine Racer 2 (Rev. ARS2 Ver.B, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NODEVICE_LAN ) // 97/01/10 17:10:59
|
||||
GAME( 1996, alpinr2a, alpinr2b, alpine, alpiner, alpine_state, init_alpiner2, ROT0, "Namco", "Alpine Racer 2 (Rev. ARS2 Ver.A, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NODEVICE_LAN ) // 96/12/06 13:45:05
|
||||
GAME( 1997, adillor, 0, adillor, adillor, adillor_state, init_adillor, ROT0, "Namco", "Armadillo Racing (Rev. AM2 Ver.A, World)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NODEVICE_LAN ) // 97/04/07 19:43:29
|
||||
GAME( 1997, adillorj, adillor, adillor, adillor, adillor_state, init_adillor, ROT0, "Namco", "Armadillo Racing (Rev. AM1 Ver.A, Japan)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_GRAPHICS | MACHINE_NODEVICE_LAN ) // 97/04/07 19:19:41
|
||||
|
@ -502,37 +502,20 @@ class namcos22s_state : public namcos22_state
|
||||
{
|
||||
public:
|
||||
namcos22s_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
namcos22_state(mconfig, type, tag),
|
||||
m_motor_timer(*this, "motor_timer"),
|
||||
m_pc_pedal_interrupt(*this, "pc_p_int"),
|
||||
m_ar_tb_interrupt(*this, "ar_tb_int%u", 0)
|
||||
namcos22_state(mconfig, type, tag)
|
||||
{ }
|
||||
|
||||
void namcos22s(machine_config &config);
|
||||
void propcycl(machine_config &config);
|
||||
void dirtdash(machine_config &config);
|
||||
void airco22b(machine_config &config);
|
||||
void cybrcycc(machine_config &config);
|
||||
void tokyowar(machine_config &config);
|
||||
void alpine(machine_config &config);
|
||||
void alpinesa(machine_config &config);
|
||||
void adillor(machine_config &config);
|
||||
void timecris(machine_config &config);
|
||||
|
||||
void init_aquajet();
|
||||
void init_adillor();
|
||||
void init_cybrcyc();
|
||||
void init_timecris();
|
||||
void init_tokyowar();
|
||||
void init_propcycl();
|
||||
void init_propcyclj();
|
||||
void init_alpiner2();
|
||||
void init_dirtdash();
|
||||
void init_airco22();
|
||||
void init_alpiner();
|
||||
void init_alpinesa();
|
||||
|
||||
template <int N> DECLARE_READ_LINE_MEMBER(alpine_motor_r);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
@ -540,7 +523,6 @@ protected:
|
||||
virtual void init_tables() override;
|
||||
virtual void draw_text_layer(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) override;
|
||||
|
||||
private:
|
||||
void install_130_speedup();
|
||||
void install_141_speedup();
|
||||
|
||||
@ -557,9 +539,6 @@ private:
|
||||
u16 spotram_r(offs_t offset);
|
||||
void spotram_w(offs_t offset, u16 data, u16 mem_mask = ~0);
|
||||
|
||||
u32 alpinesa_prot_r();
|
||||
void alpinesa_prot_w(u32 data);
|
||||
u16 timecris_gun_r(offs_t offset);
|
||||
void mb87078_gain_changed(offs_t offset, u8 data);
|
||||
void namcos22s_chipselect_w(offs_t offset, u32 data, u32 mem_mask = ~0);
|
||||
|
||||
@ -570,26 +549,14 @@ private:
|
||||
void mcu_port6_w(u8 data);
|
||||
u8 mcu_port6_r();
|
||||
template <int Channel> u16 mcu_adc_r();
|
||||
void alpine_mcu_port4_w(u8 data);
|
||||
u16 mcu130_speedup_r();
|
||||
u16 mcu141_speedup_r();
|
||||
|
||||
INTERRUPT_GEN_MEMBER(namcos22s_interrupt);
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(mcu_irq);
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(adillor_trackball_update);
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(adillor_trackball_interrupt);
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(propcycl_pedal_update);
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(propcycl_pedal_interrupt);
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(alpine_steplock_callback);
|
||||
|
||||
void alpinesa_am(address_map &map);
|
||||
void mcu_program(address_map &map);
|
||||
void namcos22s_am(address_map &map);
|
||||
void timecris_am(address_map &map);
|
||||
|
||||
optional_device<timer_device> m_motor_timer;
|
||||
optional_device<timer_device> m_pc_pedal_interrupt;
|
||||
optional_device_array<timer_device, 2> m_ar_tb_interrupt;
|
||||
|
||||
int m_spotram_enable = 0;
|
||||
int m_spotram_address = 0;
|
||||
@ -597,11 +564,96 @@ private:
|
||||
std::unique_ptr<u16[]> m_banked_czram[4];
|
||||
u32 m_cz_was_written[4];
|
||||
|
||||
u32 m_alpinesa_protection = 0;
|
||||
int m_motor_status = 0;
|
||||
u8 m_mcu_iocontrol = 0;
|
||||
u8 m_mcu_outdata = 0;
|
||||
int m_chipselect = 0;
|
||||
};
|
||||
|
||||
class alpine_state : public namcos22s_state
|
||||
{
|
||||
public:
|
||||
alpine_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
namcos22s_state(mconfig, type, tag),
|
||||
m_motor_timer(*this, "motor_timer")
|
||||
{ }
|
||||
|
||||
void alpine(machine_config &config);
|
||||
void alpinesa(machine_config &config);
|
||||
|
||||
void init_alpiner2();
|
||||
void init_alpiner();
|
||||
void init_alpinesa();
|
||||
|
||||
template <int N> DECLARE_READ_LINE_MEMBER(alpine_motor_r);
|
||||
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
|
||||
u32 alpinesa_prot_r();
|
||||
void alpinesa_prot_w(u32 data);
|
||||
|
||||
void alpine_mcu_port4_w(u8 data);
|
||||
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(alpine_steplock_callback);
|
||||
|
||||
void alpinesa_am(address_map &map);
|
||||
|
||||
required_device<timer_device> m_motor_timer;
|
||||
|
||||
u32 m_alpinesa_protection = 0;
|
||||
int m_motor_status = 0;
|
||||
};
|
||||
|
||||
class timecris_state : public namcos22s_state
|
||||
{
|
||||
public:
|
||||
timecris_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
namcos22s_state(mconfig, type, tag)
|
||||
{ }
|
||||
|
||||
void timecris(machine_config &config);
|
||||
void init_timecris();
|
||||
|
||||
private:
|
||||
u16 gun_r(offs_t offset);
|
||||
void timecris_am(address_map &map);
|
||||
};
|
||||
|
||||
class propcycl_state : public namcos22s_state
|
||||
{
|
||||
public:
|
||||
propcycl_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
namcos22s_state(mconfig, type, tag),
|
||||
m_pedal_interrupt(*this, "pedal_int")
|
||||
{ }
|
||||
|
||||
void propcycl(machine_config &config);
|
||||
void init_propcycl();
|
||||
void init_propcyclj();
|
||||
|
||||
private:
|
||||
required_device<timer_device> m_pedal_interrupt;
|
||||
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(pedal_update);
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(pedal_interrupt);
|
||||
};
|
||||
|
||||
class adillor_state : public namcos22s_state
|
||||
{
|
||||
public:
|
||||
adillor_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
namcos22s_state(mconfig, type, tag),
|
||||
m_trackball_interrupt(*this, "trackball_int%u", 0)
|
||||
{ }
|
||||
|
||||
void adillor(machine_config &config);
|
||||
void init_adillor();
|
||||
|
||||
private:
|
||||
required_device_array<timer_device, 2> m_trackball_interrupt;
|
||||
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(trackball_update);
|
||||
TIMER_DEVICE_CALLBACK_MEMBER(trackball_interrupt);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_NAMCOS22_H
|
||||
|
Loading…
Reference in New Issue
Block a user