diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/devices/bus/isa/ide.cpp | 7 | ||||
-rw-r--r-- | src/devices/bus/isa/mcd.cpp | 7 | ||||
-rw-r--r-- | src/devices/cpu/z80/z80.lst | 4 | ||||
-rw-r--r-- | src/mame/bmc/bmcpokr.cpp | 6 | ||||
-rw-r--r-- | src/mame/casio/cps2000.cpp | 21 | ||||
-rw-r--r-- | src/mame/itech/itech32.cpp | 9 | ||||
-rw-r--r-- | src/mame/misc/gms.cpp | 582 | ||||
-rw-r--r-- | src/mame/misc/xtom3d.cpp | 11 | ||||
-rw-r--r-- | src/mame/nec/pc9801.cpp | 7 | ||||
-rw-r--r-- | src/mame/pinball/macp.cpp | 8 | ||||
-rw-r--r-- | src/mame/skeleton/alesis_qs.cpp | 7 | ||||
-rw-r--r-- | src/mame/tvgames/generalplus_gp327902.cpp | 3 | ||||
-rw-r--r-- | src/mame/tvgames/generalplus_gpm453x_nand.cpp | 3 |
13 files changed, 305 insertions, 370 deletions
diff --git a/src/devices/bus/isa/ide.cpp b/src/devices/bus/isa/ide.cpp index 9565851fafc..22ac0defe64 100644 --- a/src/devices/bus/isa/ide.cpp +++ b/src/devices/bus/isa/ide.cpp @@ -50,8 +50,8 @@ void isa16_ide_device::ide_interrupt(int state) void isa16_ide_device::cdrom_headphones(device_t *device) { cdda_device *cdda = device->subdevice<cdda_device>("cdda"); - cdda->add_route(0, "^^lheadphone", 1.0); - cdda->add_route(1, "^^rheadphone", 1.0); + cdda->add_route(0, "^^headphone", 1.0, 0); + cdda->add_route(1, "^^headphone", 1.0, 1); } static INPUT_PORTS_START( ide ) @@ -76,8 +76,7 @@ void isa16_ide_device::device_add_mconfig(machine_config &config) IDE_CONTROLLER(config, m_ide).options(ata_devices, "hdd", nullptr, false); m_ide->irq_handler().set(FUNC(isa16_ide_device::ide_interrupt)); - SPEAKER(config, "lheadphone").front_left(); - SPEAKER(config, "rheadphone").front_right(); + SPEAKER(config, "headphone", 2).front(); m_ide->slot(0).set_option_machine_config("cdrom", cdrom_headphones); m_ide->slot(1).set_option_machine_config("cdrom", cdrom_headphones); diff --git a/src/devices/bus/isa/mcd.cpp b/src/devices/bus/isa/mcd.cpp index 085ab3676b9..0b78d68a98f 100644 --- a/src/devices/bus/isa/mcd.cpp +++ b/src/devices/bus/isa/mcd.cpp @@ -26,11 +26,10 @@ DEFINE_DEVICE_TYPE(ISA16_MCD, mcd_isa_device, "mcd_isa", "Mitsumi ISA CD-ROM Ada void mcd_isa_device::device_add_mconfig(machine_config &config) { - SPEAKER(config, "lheadphone").front_left(); - SPEAKER(config, "rheadphone").front_right(); + SPEAKER(config, "headphone", 2).front(); CDDA(config, m_cdda); - m_cdda->add_route(0, "lheadphone", 1.0); - m_cdda->add_route(1, "rheadphone", 1.0); + m_cdda->add_route(0, "headphone", 1.0, 0); + m_cdda->add_route(1, "headphone", 1.0, 1); m_cdda->set_cdrom_tag(*this); } diff --git a/src/devices/cpu/z80/z80.lst b/src/devices/cpu/z80/z80.lst index e3d23e925a9..17298dffca5 100644 --- a/src/devices/cpu/z80/z80.lst +++ b/src/devices/cpu/z80/z80.lst @@ -29,7 +29,7 @@ macro rm16 %addr TDAT_H = TDAT_L; @rm %addr+1 using std::swap; - std::swap(TDAT_H, TDAT_L); + swap(TDAT_H, TDAT_L); macro wm %addr m_memrq_cycles !! data_write(%addr, TDAT8); @@ -334,7 +334,7 @@ macro sbc_hl @nomreq_ir 7 u32 res = HL - TDAT - (F & CF); WZ = HL + 1; - set_f((((HL ^ res ^ TDAT) >> 8) & HF) | NF | ((res >> 16) & CF) | ((res >> 8) & (SF | YF | XF)) | ((res & 0xffff) ? 0 : ZF) | (((TDAT ^ HL) & (HL ^ res) &0x8000) >> 13)); + set_f((((HL ^ res ^ TDAT) >> 8) & HF) | NF | ((res >> 16) & CF) | ((res >> 8) & (SF | YF | XF)) | ((res & 0xffff) ? 0 : ZF) | (((TDAT ^ HL) & (HL ^ res) & 0x8000) >> 13)); HL = (u16)res; } diff --git a/src/mame/bmc/bmcpokr.cpp b/src/mame/bmc/bmcpokr.cpp index f8b94ae5e8f..5b94ac115a4 100644 --- a/src/mame/bmc/bmcpokr.cpp +++ b/src/mame/bmc/bmcpokr.cpp @@ -794,7 +794,7 @@ static INPUT_PORTS_START( mjmaglmp ) PORT_DIPNAME( 0x10, 0x10, "Game Hint" ) PORT_DIPLOCATION("DIP1:5") PORT_DIPSETTING( 0x10, DEF_STR( No ) ) PORT_DIPSETTING( 0x00, DEF_STR( Yes ) ) - PORT_DIPNAME( 0x20, 0x20, "Direct Double" ) PORT_DIPLOCATION("DIP1:6") + PORT_DIPNAME( 0x20, 0x20, "Direct Double Up" ) PORT_DIPLOCATION("DIP1:6") PORT_DIPSETTING( 0x20, DEF_STR( No ) ) PORT_DIPSETTING( 0x00, DEF_STR( Yes ) ) PORT_DIPNAME( 0x40, 0x40, "Coin Acceptor" ) PORT_DIPLOCATION("DIP1:7") @@ -971,7 +971,7 @@ static INPUT_PORTS_START( fengyunh ) PORT_DIPNAME( 0x10, 0x10, "Game Hint" ) PORT_DIPLOCATION("DIP1:5") // 吃碰提示 PORT_DIPSETTING( 0x10, DEF_STR( No ) ) // 無 PORT_DIPSETTING( 0x00, DEF_STR( Yes ) ) // 有 - PORT_DIPNAME( 0x20, 0x20, "Direct Double" ) PORT_DIPLOCATION("DIP1:6") // 直接比倍 + PORT_DIPNAME( 0x20, 0x20, "Direct Double Up" ) PORT_DIPLOCATION("DIP1:6") // 直接比倍 PORT_DIPSETTING( 0x20, DEF_STR( No ) ) // 無 PORT_DIPSETTING( 0x00, DEF_STR( Yes ) ) // 有 PORT_DIPNAME( 0x40, 0x40, "Coin Acceptor" ) PORT_DIPLOCATION("DIP1:7") // 投幣器 @@ -1076,7 +1076,7 @@ static INPUT_PORTS_START( shendeng ) PORT_DIPNAME( 0x10, 0x10, "Game Hint" ) PORT_DIPLOCATION("DIP1:5") // 吃碰提示 PORT_DIPSETTING( 0x10, DEF_STR( No ) ) // 無 PORT_DIPSETTING( 0x00, DEF_STR( Yes ) ) // 有 - PORT_DIPNAME( 0x20, 0x20, "Direct Double" ) PORT_DIPLOCATION("DIP1:6") // 直接比倍 + PORT_DIPNAME( 0x20, 0x20, "Direct Double Up" ) PORT_DIPLOCATION("DIP1:6") // 直接比倍 PORT_DIPSETTING( 0x20, DEF_STR( No ) ) // 無 PORT_DIPSETTING( 0x00, DEF_STR( Yes ) ) // 有 PORT_DIPNAME( 0x40, 0x40, "Coin Acceptor" ) PORT_DIPLOCATION("DIP1:7") // 投幣器 diff --git a/src/mame/casio/cps2000.cpp b/src/mame/casio/cps2000.cpp index eba186ad19a..df68b1f60a3 100644 --- a/src/mame/casio/cps2000.cpp +++ b/src/mame/casio/cps2000.cpp @@ -312,8 +312,7 @@ void cps2000_state::cps2000(machine_config &config) MSM6200(config, m_kbd, 4.9468_MHz_XTAL); m_kbd->irq_cb().set_inputline(m_maincpu, UPD7810_INTF1); - SPEAKER(config, "lspeaker").front_left(); - SPEAKER(config, "rspeaker").front_right(); + SPEAKER(config, "speaker", 2).front(); // UPD932(config, "upd932a", 4.9468_MHz_XTAL); // UPD932(config, "upd932b", 4.9468_MHz_XTAL); @@ -326,17 +325,17 @@ void cps2000_state::cps2000(machine_config &config) FILTER_RC(config, "bass_rc1").set_lowpass(RES_K(47), CAP_N(47)).add_route(0, "bass_rc2", 1.0); FILTER_RC(config, "bass_rc2").set_lowpass(RES_K(22), CAP_N(47)) - .add_route(0, "lspeaker", 0.25).add_route(0, "rspeaker", 0.25); + .add_route(0, "speaker", 0.25, 0).add_route(0, "speaker", 0.25, 1); UPD934G(config, m_pcm, 4.9468_MHz_XTAL / 4); - m_pcm->add_route(0, "lspeaker", 0.25); - m_pcm->add_route(0, "rspeaker", 0.125); - m_pcm->add_route(1, "lspeaker", 0.25); - m_pcm->add_route(1, "rspeaker", 0.125); - m_pcm->add_route(2, "lspeaker", 0.125); - m_pcm->add_route(2, "rspeaker", 0.25); - m_pcm->add_route(3, "lspeaker", 0.125); - m_pcm->add_route(3, "rspeaker", 0.25); + m_pcm->add_route(0, "speaker", 0.25, 0); + m_pcm->add_route(0, "speaker", 0.125, 1); + m_pcm->add_route(1, "speaker", 0.25, 0); + m_pcm->add_route(1, "speaker", 0.125, 1); + m_pcm->add_route(2, "speaker", 0.125, 0); + m_pcm->add_route(2, "speaker", 0.25, 1); + m_pcm->add_route(3, "speaker", 0.125, 0); + m_pcm->add_route(3, "speaker", 0.25, 1); } /**************************************************************************/ diff --git a/src/mame/itech/itech32.cpp b/src/mame/itech/itech32.cpp index ceb01d738a1..ca31776556d 100644 --- a/src/mame/itech/itech32.cpp +++ b/src/mame/itech/itech32.cpp @@ -1867,12 +1867,13 @@ void drivedge_state::drivedge(machine_config &config) m_screen->screen_vblank().set_nop(); // interrupt not used? - SPEAKER(config, "left_back").front_left(); // Sound PCB has hook-ups & AMPs for 5 channels - SPEAKER(config, "right_back").front_right(); // As per Sound Tests Menu: Left Front, Right Front, Left Rear, Right Rear, Under Seat + // Sound PCB has hook-ups & AMPs for 5 channels + // As per Sound Tests Menu: Left Front, Right Front, Left Rear, Right Rear, Under Seat + SPEAKER(config, "back", 2).rear(); m_ensoniq->set_channels(2); - m_ensoniq->add_route(2, "right_back", 0.1); // swapped stereo - m_ensoniq->add_route(3, "left_back", 0.1); + m_ensoniq->add_route(2, "back", 0.1, 1); // swapped stereo + m_ensoniq->add_route(3, "back", 0.1, 0); } void shoottv_state::shoottv(machine_config &config) diff --git a/src/mame/misc/gms.cpp b/src/mame/misc/gms.cpp index c5271b4215d..1ec7172a253 100644 --- a/src/mame/misc/gms.cpp +++ b/src/mame/misc/gms.cpp @@ -68,15 +68,19 @@ Hold service credit (9) and reset (F3) to enter service mode. TODO: +- work out how flip flop input is read in mahjong games in mahjong keyboard mode +- work out how payout/key-out input is read in mahjong games in mahjong keyboard mode +- work out how payout/key-out input is read in mahjong games in joystick mode - correct EEPROM hookup for all games (this would get rid of a lot of ROM patches) - hookup MCU and YM2151 / YM3812 sound for the mahjong games - hookup PIC16F84 for rbspm - emulate protection devices correctly instead of patching - hookup lamps and do layouts -- keyboard inputs for mahjong games - use real values for reel tilemaps offsets instead of hardcoded ones (would fix magslot) - complete inputs for baile, yyhm, jinpaish, ssanguoj, cjdlz (needs someone who understands Chinese and knows how to play) +- game logic seems broken in mahjong games (reach permitted when it shouldn't be, chi not + permitted when it should be, other issues) - game logic in baile seems broken (you always win), maybe due to the patches? - broken title GFX in yyhm (transparent pen problem?) - the newer games seem to use range 0x9e1000-0x9e1fff during gameplay @@ -474,29 +478,129 @@ void gms_2layers_state::mcu_io(address_map &map) map(0x0ff00, 0x0ffff).rw(FUNC(gms_2layers_state::mcu_io_r), FUNC(gms_2layers_state::mcu_io_w)); } + +#define GMS_MAHJONG_COMMON(dsw_port, dsw_bit, dsw_on) \ + PORT_START("IN1") \ + PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_MEMORY_RESET ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_SERVICE_NO_TOGGLE(0x02, IP_ACTIVE_LOW) \ + PORT_BIT( 0x00fc, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_COIN1 ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_GAMBLE_KEYIN ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x0c00, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0xf000, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) PORT_CUSTOM_MEMBER(FUNC(gms_3layers_state::keyboard_r<0>)) \ + PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_COIN1 ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_START1 ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_BUTTON3 ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_START("IN2") \ + PORT_BIT( 0x0003, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) PORT_CUSTOM_MEMBER(FUNC(gms_3layers_state::keyboard_r<4>)) \ + PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_GAMBLE_BOOK ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_GAMBLE_BOOK ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_MEMORY_RESET ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_GAMBLE_KEYIN ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_START("KEY0") \ + PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_START1 ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_KAN ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_M ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_I ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_E ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_A ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x3f, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_START("KEY1") \ + PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_BET ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_REACH ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_N ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_J ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_F ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_B ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x3f, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_START("KEY2") \ + PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_RON ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_CHI ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_K ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_G ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_C ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x3f, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_START("KEY3") \ + PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_PON ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_L ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_H ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_D ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x3f, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) \ + PORT_START("KEY4") \ + PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_BIG ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_SCORE ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_DOUBLE_UP ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_SMALL ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_LAST_CHANCE ) PORT_CONDITION(dsw_port, dsw_bit, EQUALS, dsw_on) \ + PORT_BIT( 0x3f, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_CONDITION(dsw_port, dsw_bit, NOTEQUALS, dsw_on) + +#define GMS_MAHJONG_COINAGE(tag, loc) \ + PORT_DIPNAME( 0x0007, 0x0000, DEF_STR(Coinage) ) PORT_DIPLOCATION(loc ":1,2,3") /* 投幣比例 */ \ + PORT_DIPSETTING( 0x0000, DEF_STR(1C_1C) ) \ + PORT_DIPSETTING( 0x0001, DEF_STR(1C_2C) ) \ + PORT_DIPSETTING( 0x0002, DEF_STR(1C_3C) ) \ + PORT_DIPSETTING( 0x0003, DEF_STR(1C_5C) ) \ + PORT_DIPSETTING( 0x0004, "1 Coin/10 Credits" ) \ + PORT_DIPSETTING( 0x0005, "1 Coin/20 Credits" ) \ + PORT_DIPSETTING( 0x0006, "1 Coin/50 Credits" ) \ + PORT_DIPSETTING( 0x0007, "1 Coin/100 Credits" ) \ + PORT_DIPNAME( 0x0018, 0x0000, "Key-In Rate" ) PORT_DIPLOCATION(loc ":4,5") /* 投幣×開分倍率 */ \ + PORT_DIPSETTING( 0x0018, "5" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0000) \ + PORT_DIPSETTING( 0x0000, "10" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0000) \ + PORT_DIPSETTING( 0x0008, "20" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0000) \ + PORT_DIPSETTING( 0x0010, "50" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0000) \ + PORT_DIPSETTING( 0x0018, "10" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0001) \ + PORT_DIPSETTING( 0x0000, "20" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0001) \ + PORT_DIPSETTING( 0x0008, "40" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0001) \ + PORT_DIPSETTING( 0x0010, "100" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0001) \ + PORT_DIPSETTING( 0x0018, "15" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0002) \ + PORT_DIPSETTING( 0x0000, "30" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0002) \ + PORT_DIPSETTING( 0x0008, "60" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0002) \ + PORT_DIPSETTING( 0x0010, "150" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0002) \ + PORT_DIPSETTING( 0x0018, "25" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0003) \ + PORT_DIPSETTING( 0x0000, "50" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0003) \ + PORT_DIPSETTING( 0x0008, "100" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0003) \ + PORT_DIPSETTING( 0x0010, "250" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0003) \ + PORT_DIPSETTING( 0x0018, "50" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0004) \ + PORT_DIPSETTING( 0x0000, "100" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0004) \ + PORT_DIPSETTING( 0x0008, "200" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0004) \ + PORT_DIPSETTING( 0x0010, "500" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0004) \ + PORT_DIPSETTING( 0x0018, "100" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0005) \ + PORT_DIPSETTING( 0x0000, "200" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0005) \ + PORT_DIPSETTING( 0x0008, "400" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0005) \ + PORT_DIPSETTING( 0x0010, "1000" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0005) \ + PORT_DIPSETTING( 0x0018, "250" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0006) \ + PORT_DIPSETTING( 0x0000, "500" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0006) \ + PORT_DIPSETTING( 0x0008, "1000" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0006) \ + PORT_DIPSETTING( 0x0010, "2500" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0006) \ + PORT_DIPSETTING( 0x0018, "500" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0007) \ + PORT_DIPSETTING( 0x0000, "1000" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0007) \ + PORT_DIPSETTING( 0x0008, "2000" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0007) \ + PORT_DIPSETTING( 0x0010, "5000" ) PORT_CONDITION(tag, 0x0007, EQUALS, 0x0007) + + static INPUT_PORTS_START( rbmk ) - PORT_START("IN1") // 16bit - PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_SERVICE1 ) - PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_COIN1 ) - PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_START1 ) - PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_MAHJONG_DOUBLE_UP ) - PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) - PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) - PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_BUTTON1 ) - PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_MAHJONG_BET ) - PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_BUTTON2 ) - PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x1000, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x2000, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_UNKNOWN ) + GMS_MAHJONG_COMMON("DSW2", 0x0080, 0x0000) - PORT_START("IN2") // 16bit - PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_GAMBLE_BOOK ) PORT_TOGGLE - PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_MEMORY_RESET ) PORT_TOGGLE - PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_COIN2 ) + PORT_MODIFY("IN1") // 16bit + PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x1000, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x2000, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + + PORT_MODIFY("IN2") // 16bit PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_UNKNOWN ) @@ -561,31 +665,17 @@ static INPUT_PORTS_START( rbmk ) PORT_DIPSETTING( 0x8000, "Mahjong" ) PORT_DIPSETTING( 0x0000, "Chess" ) - PORT_START("DSW2") // 16bit, in test mode first 8 are recognized as dsw2, second 8 as dsw5 - PORT_DIPNAME( 0x0007, 0x0000, DEF_STR( Coinage ) ) PORT_DIPLOCATION("DSW2:1,2,3") - PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C ) ) - PORT_DIPSETTING( 0x0001, DEF_STR( 1C_2C ) ) - PORT_DIPSETTING( 0x0002, DEF_STR( 1C_3C ) ) - PORT_DIPSETTING( 0x0003, DEF_STR( 1C_5C ) ) - PORT_DIPSETTING( 0x0004, "1 Coin/10 Credits" ) - PORT_DIPSETTING( 0x0005, "1 Coin/20 Credits" ) - PORT_DIPSETTING( 0x0006, "1 Coin/50 Credits" ) - PORT_DIPSETTING( 0x0007, "1 Coin/100 Credits" ) - PORT_DIPNAME( 0x0018, 0x0000, "Credits per Note" ) PORT_DIPLOCATION("DSW2:4,5,") - PORT_DIPSETTING( 0x0018, "1 Note/5 Credits" ) - PORT_DIPSETTING( 0x0000, "1 Note/10 Credits" ) - PORT_DIPSETTING( 0x0008, "1 Note/20 Credits" ) - PORT_DIPSETTING( 0x0010, "1 Note/50 Credits" ) + GMS_MAHJONG_COINAGE("DSW2", "DSW2") PORT_DIPNAME( 0x0020, 0x0000, "Show Tiles after Reach" ) PORT_DIPLOCATION("DSW2:6") PORT_DIPSETTING( 0x0020, DEF_STR( Off ) ) PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) PORT_DIPNAME( 0x0040, 0x0000, "Pay Out Type" ) PORT_DIPLOCATION("DSW2:7") PORT_DIPSETTING( 0x0040, "Credits" ) PORT_DIPSETTING( 0x0000, "Coins" ) - PORT_DIPNAME( 0x0080, 0x0080, "Controls" ) PORT_DIPLOCATION("DSW2:8") // should default to keyboard, but set on joystick since the former isn't emulated yet + PORT_DIPNAME( 0x0080, 0x0080, "Controls" ) PORT_DIPLOCATION("DSW2:8") + PORT_DIPSETTING( 0x0000, "Mahjong" ) PORT_DIPSETTING( 0x0080, DEF_STR( Joystick ) ) - PORT_DIPSETTING( 0x0000, "Keyboard" ) PORT_DIPNAME( 0x0100, 0x0000, DEF_STR( Unused ) ) PORT_DIPLOCATION("DSW5:1") PORT_DIPSETTING( 0x0100, DEF_STR( Off ) ) PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) @@ -671,28 +761,17 @@ INPUT_PORTS_END static INPUT_PORTS_START( ssanguoj ) - PORT_START("IN1") // 16bit - PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_SERVICE1 ) - PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_COIN1 ) - PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_START1 ) - PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_MAHJONG_DOUBLE_UP ) - PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) - PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) - PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_BUTTON1 ) - PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_MAHJONG_BET ) - PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_BUTTON2 ) - PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x1000, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x2000, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_UNKNOWN ) + GMS_MAHJONG_COMMON("DSW1", 0x0080, 0x0000) - PORT_START("IN2") // 16bit - PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_GAMBLE_BOOK ) PORT_TOGGLE - PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_MEMORY_RESET ) PORT_TOGGLE - PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_COIN2 ) + PORT_MODIFY("IN1") // 16bit + PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x1000, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x2000, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + + PORT_MODIFY("IN2") // 16bit PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_UNKNOWN ) @@ -708,32 +787,18 @@ static INPUT_PORTS_START( ssanguoj ) PORT_BIT( 0x8000, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("eeprom", FUNC(eeprom_serial_93cxx_device::do_read)) // Only 4 DIP banks are actually populated on PCBs (2 empty spaces), but test mode reads all 6. - // TODO: dips - PORT_START("DSW1") // 16bit, in test mode first 8 are recognized as dsw1, second 8 as dsw4. - PORT_DIPNAME( 0x0001, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:1") - PORT_DIPSETTING( 0x0001, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0002, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:2") - PORT_DIPSETTING( 0x0002, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0004, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:3") - PORT_DIPSETTING( 0x0004, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0008, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:4") - PORT_DIPSETTING( 0x0008, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0010, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:5") - PORT_DIPSETTING( 0x0010, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) + // TODO: DIPs (apparently no settings display in game) + PORT_START("DSW1") // 16bit, in test mode first 8 are recognized as DSW1, second 8 as DSW4. + GMS_MAHJONG_COINAGE("DSW1", "DSW1") PORT_DIPNAME( 0x0020, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:6") PORT_DIPSETTING( 0x0020, DEF_STR( Off ) ) PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) PORT_DIPNAME( 0x0040, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:7") PORT_DIPSETTING( 0x0040, DEF_STR( Off ) ) PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0080, 0x0080, "Controls" ) PORT_DIPLOCATION("DSW1:8") // should default to keyboard, but set on joystick since the former isn't emulated yet - PORT_DIPSETTING( 0x0080, DEF_STR( Joystick ) ) - PORT_DIPSETTING( 0x0000, "Keyboard" ) + PORT_DIPNAME( 0x0080, 0x0000, "Controls" ) PORT_DIPLOCATION("DSW1:8") + PORT_DIPSETTING( 0x0000, "Mahjong" ) + PORT_DIPSETTING( 0x0080, DEF_STR(Joystick) ) PORT_DIPNAME( 0x0100, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW4:1") PORT_DIPSETTING( 0x0100, DEF_STR( Off ) ) PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) @@ -759,11 +824,10 @@ static INPUT_PORTS_START( ssanguoj ) PORT_DIPSETTING( 0x8000, DEF_STR( Off ) ) PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - - PORT_START("DSW2") // 16bit, in test mode first 8 are recognized as dsw2, second 8 as dsw5 - PORT_DIPNAME( 0x0001, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW2:1") - PORT_DIPSETTING( 0x0001, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) + PORT_START("DSW2") // 16bit, in test mode first 8 are recognized as DSW2, second 8 as DSW5 + PORT_DIPNAME( 0x0001, 0x0000, DEF_STR(Demo_Sounds) ) PORT_DIPLOCATION("DSW2:1") + PORT_DIPSETTING( 0x0001, DEF_STR(Off) ) + PORT_DIPSETTING( 0x0000, DEF_STR(On) ) PORT_DIPNAME( 0x0002, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW2:2") PORT_DIPSETTING( 0x0002, DEF_STR( Off ) ) PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) @@ -782,9 +846,9 @@ static INPUT_PORTS_START( ssanguoj ) PORT_DIPNAME( 0x0040, 0x0000, DEF_STR( Version ) ) PORT_DIPLOCATION("DSW2:7") PORT_DIPSETTING( 0x0040, "8.9" ) PORT_DIPSETTING( 0x0000, "8.9-" ) - PORT_DIPNAME( 0x0080, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW2:8") - PORT_DIPSETTING( 0x0080, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) + PORT_DIPNAME( 0x0080, 0x0000, "Score Display Mode" ) PORT_DIPLOCATION("DSW2:8") // sets how points, credits, bets, etc. are displayed + PORT_DIPSETTING( 0x0080, "Numbers" ) // Arabic numerals + PORT_DIPSETTING( 0x0000, "Circle Tiles" ) // tong mahjong tiles representing digits PORT_DIPNAME( 0x0100, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW5:1") PORT_DIPSETTING( 0x0100, DEF_STR( Off ) ) PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) @@ -810,7 +874,7 @@ static INPUT_PORTS_START( ssanguoj ) PORT_DIPSETTING( 0x8000, DEF_STR( Off ) ) PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_START("DSW3") // 16bit, in test mode first 8 are recognized as dsw3, second 8 as dsw6 + PORT_START("DSW3") // 16bit, in test mode first 8 are recognized as DSW3, second 8 as DSW6 PORT_DIPNAME( 0x0001, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW3:1") PORT_DIPSETTING( 0x0001, DEF_STR( Off ) ) PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) @@ -820,9 +884,9 @@ static INPUT_PORTS_START( ssanguoj ) PORT_DIPNAME( 0x0004, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW3:3") PORT_DIPSETTING( 0x0004, DEF_STR( Off ) ) PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0008, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW3:4") - PORT_DIPSETTING( 0x0008, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) + PORT_DIPNAME( 0x0008, 0x0000, "Odds Rate" ) PORT_DIPLOCATION("DSW3:4") + PORT_DIPSETTING( 0x0000, DEF_STR(Low) ) // 1 1 1 1 10 10 / 10 10 10 10 10 10) + PORT_DIPSETTING( 0x0008, DEF_STR(High) ) // 2 2 3 3 20 60 / 20 30 30 40 40 40) PORT_DIPNAME( 0x0010, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW3:5") PORT_DIPSETTING( 0x0010, DEF_STR( Off ) ) PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) @@ -1361,90 +1425,24 @@ static INPUT_PORTS_START( baile ) INPUT_PORTS_END static INPUT_PORTS_START( yyhm ) - // TODO: missing flip flop and payout/keyout inputs in mahjong mode - // TODO: missing payout/keyout input in joystick mode - PORT_START("IN1") - PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_MEMORY_RESET ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) + GMS_MAHJONG_COMMON("DSW1", 0x0080, 0x0080) + + PORT_MODIFY("IN1") PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - PORT_SERVICE_NO_TOGGLE(0x02, IP_ACTIVE_LOW) - PORT_BIT( 0x00fc, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_COIN1 ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_GAMBLE_KEYIN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x0c00, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0xf000, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) PORT_CUSTOM_MEMBER(FUNC(gms_3layers_state::keyboard_r<0>)) - PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_COIN1 ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_START1 ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) PORT_BIT( 0xf800, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - PORT_START("IN2") - PORT_BIT( 0x0003, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) PORT_CUSTOM_MEMBER(FUNC(gms_3layers_state::keyboard_r<4>)) - PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_GAMBLE_BOOK ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_GAMBLE_BOOK ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_MEMORY_RESET ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_GAMBLE_KEYIN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) + PORT_MODIFY("IN2") PORT_BIT( 0xfff8, IP_ACTIVE_LOW, IPT_UNKNOWN ) //PORT_BIT( 0x8000, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("eeprom", FUNC(eeprom_serial_93cxx_device::do_read)) // TODO: verify - PORT_START("KEY0") - PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_START1 ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_KAN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_M ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_I ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_E ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_A ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x3f, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - - PORT_START("KEY1") - PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_BET ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_REACH ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_N ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_J ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_F ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_B ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x3f, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - - PORT_START("KEY2") - PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_RON ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_CHI ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_K ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_G ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_C ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x3f, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - - PORT_START("KEY3") - PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_PON ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_L ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_H ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_D ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x3f, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - - PORT_START("KEY4") - PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_BIG ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_SCORE ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_DOUBLE_UP ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_SMALL ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_LAST_CHANCE ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0080) - PORT_BIT( 0x3f, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_CONDITION("DSW1", 0x0080, EQUALS, 0x0000) - // Only 1 8-DIP bank on PCB. DIPs' effects as per test mode. PORT_START("DSW1") PORT_DIPNAME( 0x0001, 0x0001, DEF_STR(Service_Mode) ) PORT_DIPLOCATION("SW1:1") // 遊戲設定 PORT_DIPSETTING( 0x0001, DEF_STR(Off) ) // 正常 PORT_DIPSETTING( 0x0000, DEF_STR(On) ) // 開機進入 - PORT_DIPNAME( 0x0002, 0x0002, "Voice Announcements" ) PORT_DIPLOCATION("SW1:2") // 語音報牌 + PORT_DIPNAME( 0x0002, 0x0002, "Gal Voice" ) PORT_DIPLOCATION("SW1:2") // 語音報牌 PORT_DIPSETTING( 0x0000, DEF_STR(Off) ) // 無 - PORT_DIPSETTING( 0x0002, DEF_STR(On) ) // 有 + PORT_DIPSETTING( 0x0002, DEF_STR(On) ) // 有 (calls discarded tiles) PORT_DIPNAME( 0x0004, 0x0004, DEF_STR(Demo_Sounds) ) PORT_DIPLOCATION("SW1:3") // 示範音樂 PORT_DIPSETTING( 0x0000, DEF_STR(Off) ) // 無 PORT_DIPSETTING( 0x0004, DEF_STR(On) ) // 有 @@ -1791,29 +1789,18 @@ static INPUT_PORTS_START( sball2k1 ) // default password for accessing game sett PORT_DIPUNKNOWN_DIPLOC( 0x0080, 0x0080, "SW3:8" ) INPUT_PORTS_END -static INPUT_PORTS_START( cjdlz ) // TODO - PORT_START("IN1") // 16bit - PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_SERVICE1 ) - PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_COIN1 ) - PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_START1 ) - PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_MAHJONG_DOUBLE_UP ) - PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) - PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) - PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_BUTTON1 ) - PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_MAHJONG_BET ) - PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_BUTTON2 ) - PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x1000, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x2000, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_UNKNOWN ) +static INPUT_PORTS_START( cjdlz ) + GMS_MAHJONG_COMMON("DSW2", 0x0080, 0x0000) - PORT_START("IN2") // 16bit - PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_GAMBLE_BOOK ) PORT_TOGGLE - PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_MEMORY_RESET ) PORT_TOGGLE - PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_COIN2 ) + PORT_MODIFY("IN1") // 16bit + PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x1000, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x2000, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_CONDITION("DSW2", 0x0080, EQUALS, 0x0080) + + PORT_MODIFY("IN2") // 16bit PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_UNKNOWN ) @@ -1829,152 +1816,107 @@ static INPUT_PORTS_START( cjdlz ) // TODO PORT_BIT( 0x8000, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("eeprom", FUNC(eeprom_serial_93cxx_device::do_read)) // Only 4 DIP banks are actually populated on PCBs, but test mode reads all 6. - // TODO: dips - PORT_START("DSW1") // 16bit, in test mode first 8 are recognized as dsw1, second 8 as dsw4. - PORT_DIPNAME( 0x0007, 0x0000, "Pay Out Rate" ) PORT_DIPLOCATION("DSW1:1,2,3") - PORT_DIPSETTING( 0x0000, "72" ) - PORT_DIPSETTING( 0x0001, "75" ) - PORT_DIPSETTING( 0x0002, "78" ) - PORT_DIPSETTING( 0x0003, "80" ) - PORT_DIPSETTING( 0x0004, "82" ) - PORT_DIPSETTING( 0x0005, "85" ) - PORT_DIPSETTING( 0x0006, "88" ) - PORT_DIPSETTING( 0x0007, "90" ) - PORT_DIPNAME( 0x0008, 0x0000, "Odd Rate" ) PORT_DIPLOCATION("DSW1:4") - PORT_DIPSETTING( 0x0008, DEF_STR( High ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( Low ) ) - PORT_DIPNAME( 0x0010, 0x0000, "Double Up Direct" ) PORT_DIPLOCATION("DSW1:5") - PORT_DIPSETTING( 0x0010, DEF_STR( No ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( Yes ) ) - PORT_DIPNAME( 0x0020, 0x0000, "Double Up" ) PORT_DIPLOCATION("DSW1:6") - PORT_DIPSETTING( 0x0020, DEF_STR( No ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( Yes ) ) - PORT_DIPNAME( 0x00c0, 0x0000, "Double Up Rate" ) PORT_DIPLOCATION("DSW1:7,8") - PORT_DIPSETTING( 0x0000, "70" ) - PORT_DIPSETTING( 0x0040, "75" ) - PORT_DIPSETTING( 0x0080, "80" ) - PORT_DIPSETTING( 0x00c0, "85" ) - PORT_DIPNAME( 0x0100, 0x0000, DEF_STR( Demo_Sounds ) ) PORT_DIPLOCATION("DSW4:1") - PORT_DIPSETTING( 0x0100, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0e00, 0x0000, "Break Max" ) PORT_DIPLOCATION("DSW4:2,3,4") - PORT_DIPSETTING( 0x0000, "1000" ) - PORT_DIPSETTING( 0x0200, "2000" ) - PORT_DIPSETTING( 0x0400, "3000" ) - PORT_DIPSETTING( 0x0600, "5000" ) - PORT_DIPSETTING( 0x0800, "10000" ) - PORT_DIPSETTING( 0x0a00, "20000" ) - PORT_DIPSETTING( 0x0c00, "30000" ) - PORT_DIPSETTING( 0x0e00, "50000" ) - PORT_DIPNAME( 0x3000, 0x0000, "Credits Max" ) PORT_DIPLOCATION("DSW4:5,6") + PORT_START("DSW1") // 16bit, in test mode first 8 are recognized as DSW1, second 8 as DSW4. + PORT_DIPNAME( 0x0007, 0x0000, "Payout Rate" ) PORT_DIPLOCATION("DSW1:1,2,3") // 出牌率 + PORT_DIPSETTING( 0x0000, "72%" ) + PORT_DIPSETTING( 0x0001, "75%" ) + PORT_DIPSETTING( 0x0002, "78%" ) + PORT_DIPSETTING( 0x0003, "80%" ) + PORT_DIPSETTING( 0x0004, "82%" ) + PORT_DIPSETTING( 0x0005, "85%" ) + PORT_DIPSETTING( 0x0006, "88%" ) + PORT_DIPSETTING( 0x0007, "90%" ) + PORT_DIPNAME( 0x0008, 0x0000, "Odds Rate" ) PORT_DIPLOCATION("DSW1:4") // 役牌倍率 + PORT_DIPSETTING( 0x0000, DEF_STR(Low) ) // 低倍率 (1 2 3 3 5 20 / 5 8 10 10 10 10) + PORT_DIPSETTING( 0x0008, DEF_STR(High) ) // 高倍率 (2 3 5 5 10 50 / 10 20 30 40 40 40) + PORT_DIPNAME( 0x0010, 0x0000, "Direct Double Up" ) PORT_DIPLOCATION("DSW1:5") // 直接比倍 + PORT_DIPSETTING( 0x0000, DEF_STR(No) ) // 無 + PORT_DIPSETTING( 0x0010, DEF_STR(Yes) ) // 有 + PORT_DIPNAME( 0x0020, 0x0000, "Double Up Game" ) PORT_DIPLOCATION("DSW1:6") // 比倍有無 + PORT_DIPSETTING( 0x0020, DEF_STR(Off) ) // 無 + PORT_DIPSETTING( 0x0000, DEF_STR(On) ) // 有 + PORT_DIPNAME( 0x00c0, 0x0000, "Double Up Game Payout Rate" ) PORT_DIPLOCATION("DSW1:7,8") // 比倍機率 + PORT_DIPSETTING( 0x0000, "70%" ) + PORT_DIPSETTING( 0x0040, "75%" ) + PORT_DIPSETTING( 0x0080, "80%" ) + PORT_DIPSETTING( 0x00c0, "85%" ) + PORT_DIPNAME( 0x0100, 0x0000, DEF_STR(Demo_Sounds) ) PORT_DIPLOCATION("DSW4:1") // 示範音樂 + PORT_DIPSETTING( 0x0100, DEF_STR(Off) ) // 無 + PORT_DIPSETTING( 0x0000, DEF_STR(On) ) // 有 + PORT_DIPNAME( 0x0e00, 0x0000, "Score Limit" ) PORT_DIPLOCATION("DSW4:2,3,4") // 破台限制 (presumably limits winnings) + PORT_DIPSETTING( 0x0000, "1,000" ) + PORT_DIPSETTING( 0x0200, "2,000" ) + PORT_DIPSETTING( 0x0400, "3,000" ) + PORT_DIPSETTING( 0x0600, "5,000" ) + PORT_DIPSETTING( 0x0800, "10,000" ) + PORT_DIPSETTING( 0x0a00, "20,000" ) + PORT_DIPSETTING( 0x0c00, "30,000" ) + PORT_DIPSETTING( 0x0e00, "50,000" ) + PORT_DIPNAME( 0x3000, 0x0000, "Credit Limit" ) PORT_DIPLOCATION("DSW4:5,6") // 進分上限 (presumably limits credits purchased) PORT_DIPSETTING( 0x0000, "500" ) PORT_DIPSETTING( 0x1000, "1000" ) PORT_DIPSETTING( 0x2000, "2000" ) PORT_DIPSETTING( 0x3000, "5000" ) - PORT_DIPNAME( 0x4000, 0x0000, "Golden Rush" ) PORT_DIPLOCATION("DSW4:7") - PORT_DIPSETTING( 0x4000, "Less" ) - PORT_DIPSETTING( 0x0000, "More" ) - PORT_DIPNAME( 0x8000, 0x0000, "Number Type" ) PORT_DIPLOCATION("DSW4:8") - PORT_DIPSETTING( 0x8000, "Dice" ) - PORT_DIPSETTING( 0x0000, "Number" ) - - - PORT_START("DSW2") // 16bit, in test mode first 8 are recognized as dsw2, second 8 as dsw5 - PORT_DIPNAME( 0x0007, 0x0000, DEF_STR( Coinage ) ) PORT_DIPLOCATION("DSW2:1,2,3") - PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C ) ) - PORT_DIPSETTING( 0x0001, DEF_STR( 1C_2C ) ) - PORT_DIPSETTING( 0x0002, DEF_STR( 1C_3C ) ) - PORT_DIPSETTING( 0x0003, DEF_STR( 1C_5C ) ) - PORT_DIPSETTING( 0x0004, "1 Coin/10 Credits" ) - PORT_DIPSETTING( 0x0005, "1 Coin/20 Credits" ) - PORT_DIPSETTING( 0x0006, "1 Coin/50 Credits" ) - PORT_DIPSETTING( 0x0007, "1 Coin/100 Credits" ) - PORT_DIPNAME( 0x0018, 0x0000, "Credits per Note" ) PORT_DIPLOCATION("DSW2:4,5,") - PORT_DIPSETTING( 0x0018, "1 Note/5 Credits" ) - PORT_DIPSETTING( 0x0000, "1 Note/10 Credits" ) - PORT_DIPSETTING( 0x0008, "1 Note/20 Credits" ) - PORT_DIPSETTING( 0x0010, "1 Note/50 Credits" ) - PORT_DIPNAME( 0x0020, 0x0000, "Show Credits" ) PORT_DIPLOCATION("DSW2:6") - PORT_DIPSETTING( 0x0020, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0040, 0x0000, "Pay Out Type" ) PORT_DIPLOCATION("DSW2:7") - PORT_DIPSETTING( 0x0040, "Credits" ) - PORT_DIPSETTING( 0x0000, "Coins" ) - PORT_DIPNAME( 0x0080, 0x0080, "Controls" ) PORT_DIPLOCATION("DSW2:8") // should default to keyboard, but set on joystick since the former isn't emulated yet - PORT_DIPSETTING( 0x0080, DEF_STR( Joystick ) ) - PORT_DIPSETTING( 0x0000, "Keyboard" ) - PORT_DIPNAME( 0x0100, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW5:1") - PORT_DIPSETTING( 0x0100, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0200, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW5:2") - PORT_DIPSETTING( 0x0200, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0400, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW5:3") - PORT_DIPSETTING( 0x0400, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0800, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW5:4") - PORT_DIPSETTING( 0x0800, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x1000, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW5:5") - PORT_DIPSETTING( 0x1000, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x2000, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW5:6") - PORT_DIPSETTING( 0x2000, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x4000, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW5:7") - PORT_DIPSETTING( 0x4000, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x8000, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW5:8") - PORT_DIPSETTING( 0x8000, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - - PORT_START("DSW3") // 16bit, in test mode first 8 are recognized as dsw3, second 8 as dsw6 - PORT_DIPNAME( 0x0003, 0x0000, "Min Bet" ) PORT_DIPLOCATION("DSW3:1,2") + PORT_DIPNAME( 0x4000, 0x0000, "Dapai Frequency" ) PORT_DIPLOCATION("DSW4:7") // 大牌出現 + PORT_DIPSETTING( 0x4000, DEF_STR(Low) ) // 少 + PORT_DIPSETTING( 0x0000, DEF_STR(High) ) // 多 + PORT_DIPNAME( 0x8000, 0x0000, "Score Display Mode" ) PORT_DIPLOCATION("DSW4:8") // 計分方式 (sets how points, credits, bets, etc. are displayed) + PORT_DIPSETTING( 0x0000, "Numbers" ) // 數字計分 (Arabic numerals) + PORT_DIPSETTING( 0x8000, "Circle Tiles" ) // 筒子計分 (tong mahjong tiles representing digits) + + PORT_START("DSW2") // 16bit, in test mode first 8 are recognized as DSW2, second 8 as DSW5 + GMS_MAHJONG_COINAGE("DSW2", "DSW2") + PORT_DIPNAME( 0x0020, 0x0000, "Hide Credits" ) PORT_DIPLOCATION("DSW2:6") // 遊戲分數 + PORT_DIPSETTING( 0x0000, DEF_STR(Off) ) // 顯示 + PORT_DIPSETTING( 0x0020, DEF_STR(On) ) // 不顯示 + PORT_DIPNAME( 0x0040, 0x0000, "Payout Mode" ) PORT_DIPLOCATION("DSW2:7") // 退幣退票方式 + PORT_DIPSETTING( 0x0000, "Return Coins" ) // 以投幣計 + PORT_DIPSETTING( 0x0040, "Key-Out" ) // 以開分計 + PORT_DIPNAME( 0x0080, 0x0000, DEF_STR(Controls) ) PORT_DIPLOCATION("DSW2:8") // 操作方式 + PORT_DIPSETTING( 0x0000, "Mahjong" ) // 鍵盤 + PORT_DIPSETTING( 0x0080, DEF_STR(Joystick) ) // 搖桿 + PORT_BIT( 0xff00, IP_ACTIVE_LOW, IPT_UNUSED ) // DSW5 shown in input test but not physically present + //PORT_DIPUNUSED_DIPLOC( 0x0100, 0x0000, "DSW5:1") + //PORT_DIPUNUSED_DIPLOC( 0x0200, 0x0000, "DSW5:2") + //PORT_DIPUNUSED_DIPLOC( 0x0400, 0x0000, "DSW5:3") + //PORT_DIPUNUSED_DIPLOC( 0x0800, 0x0000, "DSW5:4") + //PORT_DIPUNUSED_DIPLOC( 0x1000, 0x0000, "DSW5:5") + //PORT_DIPUNUSED_DIPLOC( 0x2000, 0x0000, "DSW5:6") + //PORT_DIPUNUSED_DIPLOC( 0x4000, 0x0000, "DSW5:7") + //PORT_DIPUNUSED_DIPLOC( 0x8000, 0x0000, "DSW5:8") + + PORT_START("DSW3") // 16bit, in test mode first 8 are recognized as DSW3, second 8 as DSW6 + PORT_DIPNAME( 0x0003, 0x0000, "Minimum Bet" ) PORT_DIPLOCATION("DSW3:1,2") // 最小押分 PORT_DIPSETTING( 0x0000, "1" ) PORT_DIPSETTING( 0x0001, "2" ) PORT_DIPSETTING( 0x0002, "5" ) PORT_DIPSETTING( 0x0003, "10" ) - PORT_DIPNAME( 0x000c, 0x0000, "Max Bet" ) PORT_DIPLOCATION("DSW3:3,4") + PORT_DIPNAME( 0x000c, 0x0000, "Maximum Bet" ) PORT_DIPLOCATION("DSW3:3,4") // 最大押分 PORT_DIPSETTING( 0x0000, "10" ) PORT_DIPSETTING( 0x0004, "20" ) PORT_DIPSETTING( 0x0008, "30" ) PORT_DIPSETTING( 0x000c, "50" ) - PORT_DIPNAME( 0x0010, 0x0000, "Main Credits Game" ) PORT_DIPLOCATION("DSW3:5") - PORT_DIPSETTING( 0x0010, "Introduction" ) - PORT_DIPSETTING( 0x0000, "Lucky Door" ) - PORT_DIPNAME( 0x0020, 0x0000, "Insert Coin Continue" ) PORT_DIPLOCATION("DSW3:6") - PORT_DIPSETTING( 0x0000, "30 Seconds" ) - PORT_DIPSETTING( 0x0020, "Unlimited" ) - PORT_DIPNAME( 0x0040, 0x0000, "Introduction" ) PORT_DIPLOCATION("DSW3:7") + PORT_DIPNAME( 0x0010, 0x0000, "Main Credits Game" ) PORT_DIPLOCATION("DSW3:5") // 餘分遊戲 + PORT_DIPSETTING( 0x0010, "Introduction" ) // 入門篇 + PORT_DIPSETTING( 0x0000, "Lucky Door" ) // 幸運門 + PORT_DIPNAME( 0x0020, 0x0000, "Credit Timer" ) PORT_DIPLOCATION("DSW3:6") // 等待投幣時間 + PORT_DIPSETTING( 0x0020, DEF_STR(Off) ) // 無限 + PORT_DIPSETTING( 0x0000, DEF_STR(On) ) // 30 + PORT_DIPNAME( 0x0040, 0x0000, "Introduction" ) PORT_DIPLOCATION("DSW3:7") // 入門篇 PORT_DIPSETTING( 0x0040, "1" ) PORT_DIPSETTING( 0x0000, "2" ) - PORT_DIPNAME( 0x0080, 0x0000, "Tiles Sound" ) PORT_DIPLOCATION("DSW3:8") - PORT_DIPSETTING( 0x0080, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0100, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW6:1") - PORT_DIPSETTING( 0x0100, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0200, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW6:2") - PORT_DIPSETTING( 0x0200, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0400, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW6:3") - PORT_DIPSETTING( 0x0400, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x0800, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW6:4") - PORT_DIPSETTING( 0x0800, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x1000, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW6:5") - PORT_DIPSETTING( 0x1000, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x2000, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW6:6") - PORT_DIPSETTING( 0x2000, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x4000, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW6:7") - PORT_DIPSETTING( 0x4000, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) - PORT_DIPNAME( 0x8000, 0x0000, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW6:8") - PORT_DIPSETTING( 0x8000, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) + PORT_DIPNAME( 0x0080, 0x0000, "Gal Voice" ) PORT_DIPLOCATION("DSW3:8") // 語音報牌 + PORT_DIPSETTING( 0x0080, DEF_STR(Off) ) // 無 + PORT_DIPSETTING( 0x0000, DEF_STR(On) ) // 有 (calls discarded tiles) + PORT_BIT( 0xff00, IP_ACTIVE_LOW, IPT_UNUSED ) // DSW6 shown in input test but not physically present + //PORT_DIPUNUSED_DIPLOC( 0x0100, 0x0000, "DSW6:1") + //PORT_DIPUNUSED_DIPLOC( 0x0200, 0x0000, "DSW6:2") + //PORT_DIPUNUSED_DIPLOC( 0x0400, 0x0000, "DSW6:3") + //PORT_DIPUNUSED_DIPLOC( 0x0800, 0x0000, "DSW6:4") + //PORT_DIPUNUSED_DIPLOC( 0x1000, 0x0000, "DSW6:5") + //PORT_DIPUNUSED_DIPLOC( 0x2000, 0x0000, "DSW6:6") + //PORT_DIPUNUSED_DIPLOC( 0x4000, 0x0000, "DSW6:7") + //PORT_DIPUNUSED_DIPLOC( 0x8000, 0x0000, "DSW6:8") INPUT_PORTS_END static INPUT_PORTS_START( hgly ) @@ -2377,13 +2319,13 @@ void gms_2layers_state::ssanguoj(machine_config &config) config.device_remove("ymsnd"); ym3812_device &ym(YM3812(config, "ym3812", 22_MHz_XTAL / 8)); - ym.add_route(0, "speaker", 0.60, 0); - ym.add_route(1, "speaker", 0.60, 1); + ym.add_route(ALL_OUTPUTS, "speaker", 0.60); } void gms_2layers_state::super555(machine_config &config) { rbmk(config); + m_maincpu->set_addrmap(AS_PROGRAM, &gms_2layers_state::super555_mem); config.device_remove("mcu"); diff --git a/src/mame/misc/xtom3d.cpp b/src/mame/misc/xtom3d.cpp index d714f134d9b..e479ac7a535 100644 --- a/src/mame/misc/xtom3d.cpp +++ b/src/mame/misc/xtom3d.cpp @@ -661,8 +661,8 @@ void xtom3d_state::romdisk_config(device_t *device) void xtom3d_state::piu10_config(device_t *device) { isa16_piu10 &piu10 = *downcast<isa16_piu10 *>(device); - piu10.add_route(0, ":lmicrophone", 0.25); - piu10.add_route(1, ":rmicrophone", 0.25); + piu10.add_route(0, ":microphone", 0.25, 0); + piu10.add_route(1, ":microphone", 0.25, 1); } // TODO: unverified PCI config space @@ -728,16 +728,15 @@ void xtom3d_state::xtom3d(machine_config &config) // TODO: stub for drive options (speed/drive type etc.) static void cdrom_config(device_t *device) { - device->subdevice<cdda_device>("cdda")->add_route(0, ":lmicrophone", 0.25); - device->subdevice<cdda_device>("cdda")->add_route(1, ":rmicrophone", 0.25); + device->subdevice<cdda_device>("cdda")->add_route(0, ":microphone", 0.25, 0); + device->subdevice<cdda_device>("cdda")->add_route(1, ":microphone", 0.25, 1); } void xtom3d_state::pumpitup(machine_config &config) { xtom3d(config); - SPEAKER(config, "lmicrophone").front_left(); - SPEAKER(config, "rmicrophone").front_right(); + SPEAKER(config, "microphone", 2).front(); m_pci_ide->subdevice<bus_master_ide_controller_device>("ide1")->slot(0).set_default_option("cdrom"); m_pci_ide->subdevice<bus_master_ide_controller_device>("ide1")->slot(0).set_option_machine_config("cdrom", cdrom_config); diff --git a/src/mame/nec/pc9801.cpp b/src/mame/nec/pc9801.cpp index c9e7bcb0211..641d6426563 100644 --- a/src/mame/nec/pc9801.cpp +++ b/src/mame/nec/pc9801.cpp @@ -2343,14 +2343,13 @@ void pc9801_state::pc9801_sasi(machine_config &config) void pc9801vm_state::cdrom_headphones(device_t *device) { cdda_device *cdda = device->subdevice<cdda_device>("cdda"); - cdda->add_route(0, "^^lheadphone", 1.0); - cdda->add_route(1, "^^rheadphone", 1.0); + cdda->add_route(0, "^^headphone", 1.0, 0); + cdda->add_route(1, "^^headphone", 1.0, 1); } void pc9801vm_state::pc9801_ide(machine_config &config) { - SPEAKER(config, "lheadphone").front_left(); - SPEAKER(config, "rheadphone").front_right(); + SPEAKER(config, "headphone", 2).front(); ATA_INTERFACE(config, m_ide[0]).options(ata_devices, "hdd", nullptr, false); m_ide[0]->irq_handler().set("ideirq", FUNC(input_merger_device::in_w<0>)); ATA_INTERFACE(config, m_ide[1]).options(pc9801_atapi_devices, "pc98_cd", nullptr, false); diff --git a/src/mame/pinball/macp.cpp b/src/mame/pinball/macp.cpp index 9ae7e1ae167..3805fa57246 100644 --- a/src/mame/pinball/macp.cpp +++ b/src/mame/pinball/macp.cpp @@ -363,20 +363,20 @@ void macp_state::mac16k(machine_config &config) genpin_audio(config); //2x AY8910 - SPEAKER(config, "lspkr").front_left(); + SPEAKER(config, "speaker", 2).front(); + AY8910(config, m_ay8910[0], 3'800'000/2); m_ay8910[0]->set_resistors_load(10e3,10e3,10e3); m_ay8910[0]->port_a_write_callback().set(FUNC(macp_state::ay0_a_w)); m_ay8910[0]->port_b_write_callback().set(FUNC(macp_state::ay0_b_w)); - m_ay8910[0]->add_route(ALL_OUTPUTS, "lspkr", 0.50); + m_ay8910[0]->add_route(ALL_OUTPUTS, "speaker", 0.50, 0); - SPEAKER(config, "rspkr").front_right(); AY8910(config, m_ay8910[1], 3'800'000/2); m_ay8910[1]->set_resistors_load(10e3,10e3,10e3); m_ay8910[1]->port_a_write_callback().set(FUNC(macp_state::ay1_a_w)); m_ay8910[1]->port_b_write_callback().set(FUNC(macp_state::ay1_b_w)); m_ay8910[1]->port_b_read_callback().set(FUNC(macp_state::ay1_b_r)); - m_ay8910[1]->add_route(ALL_OUTPUTS, "rspkr", 0.50); + m_ay8910[1]->add_route(ALL_OUTPUTS, "speaker", 0.50, 1); } void macp_state::mac32k(machine_config &config) diff --git a/src/mame/skeleton/alesis_qs.cpp b/src/mame/skeleton/alesis_qs.cpp index af28367e06e..73fe9aa2683 100644 --- a/src/mame/skeleton/alesis_qs.cpp +++ b/src/mame/skeleton/alesis_qs.cpp @@ -71,11 +71,10 @@ void qs_state::qs7(machine_config &config) //TODO: add LCD display controller here /* sound hardware */ - //SPEAKER(config, "left").front_left(); - //SPEAKER(config, "right").front_right(); + //SPEAKER(config, "speaker", 2).front(); //alesis_qs_series_device &sound(ALESIS_QS_SERIES(config, "sound", SND_CLOCK)); - //sound.add_route(0, "left", 1.0); - //sound.add_route(1, "right", 1.0); + //sound.add_route(0, "speaker", 1.0, 0); + //sound.add_route(1, "speaker", 1.0, 1); /* Interfaces */ //PCMCIA diff --git a/src/mame/tvgames/generalplus_gp327902.cpp b/src/mame/tvgames/generalplus_gp327902.cpp index 6b142d7c26a..b9ca53e121e 100644 --- a/src/mame/tvgames/generalplus_gp327902.cpp +++ b/src/mame/tvgames/generalplus_gp327902.cpp @@ -133,8 +133,7 @@ void generalplus_gp327902_game_state::gp327902(machine_config &config) m_screen->set_visarea(0, 320-1, 0, 240-1); m_screen->set_screen_update(FUNC(generalplus_gp327902_game_state::screen_update_gp327902)); - SPEAKER(config, "lspeaker").front_left(); - SPEAKER(config, "rspeaker").front_right(); + SPEAKER(config, "speaker", 2).front(); TIMER(config, "timer").configure_periodic(FUNC(generalplus_gp327902_game_state::timer), attotime::from_hz(1000)); } diff --git a/src/mame/tvgames/generalplus_gpm453x_nand.cpp b/src/mame/tvgames/generalplus_gpm453x_nand.cpp index 124e4825bda..90daafa1b53 100644 --- a/src/mame/tvgames/generalplus_gpm453x_nand.cpp +++ b/src/mame/tvgames/generalplus_gpm453x_nand.cpp @@ -91,8 +91,7 @@ void generalplus_gpm453x_game_state::gpm453x(machine_config &config) m_screen->set_visarea(0, 320-1, 0, 240-1); m_screen->set_screen_update(FUNC(generalplus_gpm453x_game_state::screen_update)); - SPEAKER(config, "lspeaker").front_left(); - SPEAKER(config, "rspeaker").front_right(); + SPEAKER(config, "speaker", 2).front(); } ROM_START( leapland ) |