summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/drivers/alg.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/drivers/alg.cpp')
-rw-r--r--src/mame/drivers/alg.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/mame/drivers/alg.cpp b/src/mame/drivers/alg.cpp
index 2cb251611c7..352fda8a519 100644
--- a/src/mame/drivers/alg.cpp
+++ b/src/mame/drivers/alg.cpp
@@ -48,8 +48,8 @@ public:
{ }
DECLARE_CUSTOM_INPUT_MEMBER(lightgun_pos_r);
- DECLARE_CUSTOM_INPUT_MEMBER(lightgun_trigger_r);
- DECLARE_CUSTOM_INPUT_MEMBER(lightgun_holster_r);
+ DECLARE_READ_LINE_MEMBER(lightgun_trigger_r);
+ DECLARE_READ_LINE_MEMBER(lightgun_holster_r);
void init_aplatoon();
void init_palr3();
@@ -155,14 +155,14 @@ CUSTOM_INPUT_MEMBER(alg_state::lightgun_pos_r)
}
-CUSTOM_INPUT_MEMBER(alg_state::lightgun_trigger_r)
+READ_LINE_MEMBER(alg_state::lightgun_trigger_r)
{
/* read the trigger control based on the input select */
return (m_triggers->read() >> m_input_select) & 1;
}
-CUSTOM_INPUT_MEMBER(alg_state::lightgun_holster_r)
+READ_LINE_MEMBER(alg_state::lightgun_holster_r)
{
/* read the holster control based on the input select */
return (m_triggers->read() >> (2 + m_input_select)) & 1;
@@ -230,11 +230,11 @@ void alg_state::main_map_picmatic(address_map &map)
static INPUT_PORTS_START( alg )
PORT_START("joy_0_dat") /* read by Amiga core */
- PORT_BIT( 0x0303, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(DEVICE_SELF, alg_state,amiga_joystick_convert, (void *)0)
+ PORT_BIT( 0x0303, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(alg_state, amiga_joystick_convert<0>)
PORT_BIT( 0xfcfc, IP_ACTIVE_HIGH, IPT_UNKNOWN )
PORT_START("joy_1_dat") /* read by Amiga core */
- PORT_BIT( 0x0303, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(DEVICE_SELF, alg_state,amiga_joystick_convert, (void *)1)
+ PORT_BIT( 0x0303, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(alg_state, amiga_joystick_convert<1>)
PORT_BIT( 0xfcfc, IP_ACTIVE_HIGH, IPT_UNKNOWN )
PORT_START("potgo") /* read by Amiga core */
@@ -245,7 +245,7 @@ static INPUT_PORTS_START( alg )
PORT_BIT( 0xaaff, IP_ACTIVE_HIGH, IPT_UNUSED )
PORT_START("HVPOS") /* read by Amiga core */
- PORT_BIT( 0x1ffff, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(DEVICE_SELF, alg_state,lightgun_pos_r, nullptr)
+ PORT_BIT( 0x1ffff, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(alg_state, lightgun_pos_r)
PORT_START("FIRE")
PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(1)
@@ -276,13 +276,13 @@ static INPUT_PORTS_START( alg_2p )
PORT_MODIFY("potgo")
PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_START2 )
- PORT_BIT( 0x1000, IP_ACTIVE_LOW, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(DEVICE_SELF, alg_state,lightgun_trigger_r, nullptr)
+ PORT_BIT( 0x1000, IP_ACTIVE_LOW, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(alg_state, lightgun_trigger_r)
PORT_MODIFY("FIRE")
PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNUSED )
PORT_MODIFY("p2_joy")
- PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(DEVICE_SELF, alg_state,lightgun_holster_r, nullptr)
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(alg_state, lightgun_holster_r)
PORT_START("GUN2X") /* referenced by lightgun_pos_r */
PORT_BIT( 0xff, 0x80, IPT_LIGHTGUN_X ) PORT_CROSSHAIR(X, 1.0, 0.0, 0) PORT_SENSITIVITY(50) PORT_KEYDELTA(10) PORT_PLAYER(2)