diff --git a/src/mame/drivers/legionna.c b/src/mame/drivers/legionna.c index 85f50473d45..aa41c6793a8 100644 --- a/src/mame/drivers/legionna.c +++ b/src/mame/drivers/legionna.c @@ -122,9 +122,9 @@ static ADDRESS_MAP_START( legionna_cop_mem, AS_PROGRAM, 16, legionna_state ) AM_RANGE(0x1004a0, 0x1004ad) AM_DEVREADWRITE("raiden2cop", raiden2cop_device, cop_reg_high_r, cop_reg_high_w) AM_RANGE(0x1004c0, 0x1004cd) AM_DEVREADWRITE("raiden2cop", raiden2cop_device, cop_reg_low_r, cop_reg_low_w) // AM_RANGE(0x100500, 0x100505) AM_WRITE(cop_cmd_w) -// AM_RANGE(0x100580, 0x100581) AM_READ(cop_collision_status_r) + AM_RANGE(0x100580, 0x100581) AM_DEVREAD("raiden2cop", raiden2cop_device, cop_collision_status_r) // AM_RANGE(0x100582, 0x100587) AM_READ(cop_collision_status_val_r) -// AM_RANGE(0x100588, 0x100589) AM_READ(cop_collision_status_stat_r) + AM_RANGE(0x100588, 0x100589) AM_DEVREAD("raiden2cop", raiden2cop_device, cop_collision_status_stat_r) AM_RANGE(0x100590, 0x100599) AM_DEVREAD("raiden2cop", raiden2cop_device, cop_itoa_digits_r) AM_RANGE(0x1005a0, 0x1005a7) AM_DEVREAD("raiden2cop", raiden2cop_device, cop_prng_r) diff --git a/src/mame/machine/raiden2cop.c b/src/mame/machine/raiden2cop.c index f96127753ee..13b0232fdcb 100644 --- a/src/mame/machine/raiden2cop.c +++ b/src/mame/machine/raiden2cop.c @@ -624,6 +624,7 @@ WRITE16_MEMBER(raiden2cop_device::cop_dma_trigger_w) // according to score display in https://www.youtube.com/watch?v=T1M8sxYgt9A // we should return 0x30 for unused digits? according to Raiden 2 and Zero // Team the value should be 0x20, can this be configured? +// grainbow doesn't like this implementation at all (21 credits, 2 digit high scores etc.) WRITE16_MEMBER(raiden2cop_device::cop_itoa_low_w) { cop_itoa = (cop_itoa & ~UINT32(mem_mask)) | (data & mem_mask); diff --git a/src/mame/machine/seicop.c b/src/mame/machine/seicop.c index 1d444174b94..56107a79d64 100644 --- a/src/mame/machine/seicop.c +++ b/src/mame/machine/seicop.c @@ -1601,11 +1601,9 @@ const device_type SEIBU_COP_LEGACY = &device_creator; seibu_cop_legacy_device::seibu_cop_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) : device_t(mconfig, SEIBU_COP_LEGACY, "Seibu COP Legacy", tag, owner, clock, "seibu_cop_legacy", __FILE__), m_cop_mcu_ram(NULL), - m_copd2_offs(0), m_cop_hit_val_x(0), m_cop_hit_val_y(0), m_cop_hit_val_z(0), - m_cop_hit_val_unk(0), m_legacycop_angle_compare(0), m_legacycop_angle_mod_val(0), m_r0(0), @@ -1645,11 +1643,9 @@ void seibu_cop_legacy_device::device_start() m_cop_mcu_ram = reinterpret_cast(machine().root_device().memshare("cop_mcu_ram")->ptr()); - save_item(NAME(m_copd2_offs)); save_item(NAME(m_cop_hit_val_x)); save_item(NAME(m_cop_hit_val_y)); save_item(NAME(m_cop_hit_val_z)); - save_item(NAME(m_cop_hit_val_unk)); save_item(NAME(m_legacycop_angle_compare)); save_item(NAME(m_legacycop_angle_mod_val)); save_item(NAME(m_r0)); @@ -2022,7 +2018,7 @@ UINT8 seibu_cop_legacy_device::cop_calculate_collsion_detection() m_cop_hit_val_x = (m_cop_collision_info[0].x - m_cop_collision_info[1].x) >> 16; m_cop_hit_val_y = (m_cop_collision_info[0].y - m_cop_collision_info[1].y) >> 16; m_cop_hit_val_z = 1; - m_cop_hit_val_unk = res; // TODO: there's also bit 2 and 3 triggered in the tests, no known meaning + m_raiden2cop->cop_hit_val_stat = res; // TODO: there's also bit 2 and 3 triggered in the tests, no known meaning //popmessage("%d %d %04x %04x %04x %04x",m_cop_hit_val_x,m_cop_hit_val_y,m_cop_collision_info[0].hitbox_x,m_cop_collision_info[0].hitbox_y,m_cop_collision_info[1].hitbox_x,m_cop_collision_info[1].hitbox_y); @@ -2054,8 +2050,6 @@ READ16_MEMBER( seibu_cop_legacy_device::generic_cop_r ) case 0x186/2: return (m_cop_hit_val_z); - case 0x188/2: - return m_cop_hit_val_unk; diff --git a/src/mame/machine/seicop.h b/src/mame/machine/seicop.h index 79eb6aac353..d589d0af98d 100644 --- a/src/mame/machine/seicop.h +++ b/src/mame/machine/seicop.h @@ -42,8 +42,7 @@ private: - UINT16 m_copd2_offs; - INT16 m_cop_hit_val_x,m_cop_hit_val_y,m_cop_hit_val_z,m_cop_hit_val_unk; + INT16 m_cop_hit_val_x,m_cop_hit_val_y,m_cop_hit_val_z; INT8 m_legacycop_angle_compare; INT8 m_legacycop_angle_mod_val; struct collision_info m_cop_collision_info[2];