Skip to content

Commit 2a1059d

Browse files
authored
tvgames/xavix.cpp: Document ekara alternate input dip (#14866)
BGM Down/Up buttons not affected, surprisingly.
1 parent 4b6f920 commit 2a1059d

File tree

1 file changed

+21
-8
lines changed

1 file changed

+21
-8
lines changed

src/mame/tvgames/xavix.cpp

Lines changed: 21 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -854,25 +854,38 @@ INPUT_PORTS_END
854854
static INPUT_PORTS_START( ekara )
855855
PORT_INCLUDE(xavix)
856856

857+
PORT_MODIFY("IN0")
858+
PORT_DIPNAME( 0x80, 0x00, "Alternate Input Mapping" )
859+
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
860+
PORT_DIPSETTING( 0x80, DEF_STR( On ) )
861+
857862
PORT_MODIFY("IN1")
858863
PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(FUNC(xavix_ekara_state::ekara_multi0_r))
859864
PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(FUNC(xavix_ekara_state::ekara_multi1_r))
860865

861866
PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_POWER_OFF ) PORT_NAME("Power Switch") // pressing this will turn the game off.
862867

863868
PORT_START("EXTRA0")
864-
PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Echo")
865-
PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_NAME("Effects")
866-
PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_NAME("Key Down")
867-
PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_NAME("Key Up")
869+
PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Echo") PORT_CONDITION("IN0", 0x80, EQUALS, 0x00)
870+
PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_NAME("Effects") PORT_CONDITION("IN0", 0x80, EQUALS, 0x00)
871+
PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_NAME("Key Down") PORT_CONDITION("IN0", 0x80, EQUALS, 0x00)
872+
PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_NAME("Key Up") PORT_CONDITION("IN0", 0x80, EQUALS, 0x00)
868873
PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON5 ) PORT_NAME("BGM Down")
869874
PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_BUTTON6 ) PORT_NAME("BGM Up")
870-
PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 ) PORT_NAME("Tempo Down")
871-
PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_BUTTON8 ) PORT_NAME("Tempo Up")
875+
PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 ) PORT_NAME("Tempo Down") PORT_CONDITION("IN0", 0x80, EQUALS, 0x00)
876+
PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_BUTTON8 ) PORT_NAME("Tempo Up") PORT_CONDITION("IN0", 0x80, EQUALS, 0x00)
877+
PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Select") PORT_CONDITION("IN0", 0x80, EQUALS, 0x80)
878+
PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Cancel") PORT_CONDITION("IN0", 0x80, EQUALS, 0x80)
879+
PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON7 ) PORT_NAME("Tempo Down") PORT_CONDITION("IN0", 0x80, EQUALS, 0x80)
880+
PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON8 ) PORT_NAME("Tempo Up") PORT_CONDITION("IN0", 0x80, EQUALS, 0x80)
881+
PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_NAME("Key Down") PORT_CONDITION("IN0", 0x80, EQUALS, 0x80)
882+
PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_NAME("Key Up") PORT_CONDITION("IN0", 0x80, EQUALS, 0x80)
872883

873884
PORT_START("EXTRA1")
874-
PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Select")
875-
PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Cancel")
885+
PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Select") PORT_CONDITION("IN0", 0x80, EQUALS, 0x00)
886+
PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Cancel") PORT_CONDITION("IN0", 0x80, EQUALS, 0x00)
887+
PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Echo") PORT_CONDITION("IN0", 0x80, EQUALS, 0x80)
888+
PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_NAME("Effects") PORT_CONDITION("IN0", 0x80, EQUALS, 0x80)
876889
PORT_BIT( 0x3c, IP_ACTIVE_HIGH, IPT_UNUSED )
877890
// no 40/80 due to multiplexer code
878891
INPUT_PORTS_END

0 commit comments

Comments
 (0)