summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--.github/workflows/includeguards.yml25
-rwxr-xr-xscripts/build/check_include_guards.py47
-rw-r--r--src/devices/machine/dp8573a.h6
-rw-r--r--src/devices/sound/iopspu.h6
-rw-r--r--src/devices/sound/meg.h6
-rw-r--r--src/devices/sound/nes_apu_vt.h6
-rw-r--r--src/devices/sound/nn71003f.h6
-rw-r--r--src/devices/sound/rp2c33_snd.h13
-rw-r--r--src/devices/sound/segapcm.h6
-rw-r--r--src/devices/sound/swp00.h6
-rw-r--r--src/devices/sound/swp20.h6
-rw-r--r--src/devices/sound/swp30.h6
-rw-r--r--src/devices/sound/swp30d.h6
-rw-r--r--src/devices/sound/swx00.h6
-rw-r--r--src/devices/sound/vgm_visualizer.h6
-rw-r--r--src/devices/video/ati_mach32.h6
-rw-r--r--src/devices/video/ati_mach8.h6
-rw-r--r--src/devices/video/imagetek_i4100.h13
-rw-r--r--src/devices/video/mb90082.h6
-rw-r--r--src/devices/video/pc_vga_alliance.h6
-rw-r--r--src/devices/video/ppu2c0x_sh6578.h6
-rw-r--r--src/devices/video/ppu2c0x_vt.h8
-rw-r--r--src/devices/video/wd90c26.h6
-rw-r--r--src/devices/video/zr36110.h7
-rw-r--r--src/mame/dynax/dynax.cpp566
-rw-r--r--src/mame/dynax/dynax.h5
26 files changed, 340 insertions, 452 deletions
diff --git a/.github/workflows/includeguards.yml b/.github/workflows/includeguards.yml
new file mode 100644
index 00000000000..c2a6e2936d6
--- /dev/null
+++ b/.github/workflows/includeguards.yml
@@ -0,0 +1,25 @@
+name: 'Check #incude guargs'
+
+on:
+ push:
+ paths:
+ - '.github/workflows/**'
+ - 'src/devices/**.h'
+ - 'src/mame/**.h'
+ pull_request:
+ - '.github/workflows/**'
+ - 'src/devices/**.h'
+ - 'src/mame/**.h'
+
+permissions:
+ contents: read
+
+jobs:
+ validate:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@main
+ with:
+ fetch-depth: 0
+ - name: Validate
+ run: python3 scripts/build/check_include_guards.py src/devices src/mame
diff --git a/scripts/build/check_include_guards.py b/scripts/build/check_include_guards.py
new file mode 100755
index 00000000000..f294cc6412f
--- /dev/null
+++ b/scripts/build/check_include_guards.py
@@ -0,0 +1,47 @@
+#!/usr/bin/python3
+##
+## icense:BSD-3-Clause
+## copyright-holders:Vas Crabb
+
+import io
+import os
+import os.path
+import re
+import sys
+
+
+def pathsplit(p):
+ result = [ ]
+ while p:
+ d, n = os.path.split(p)
+ if not n:
+ result.insert(0, d)
+ break
+ else:
+ result.insert(0, n)
+ p = d
+ return result
+
+
+if __name__ == '__main__':
+ extpat = re.compile('.+\\.(h|hpp)$')
+ substpat = re.compile('[-.]')
+ guardpat = re.compile('^ *# *ifndef +([^\s]+)(\s+.*)?')
+ bad = False
+ for root in sys.argv[1:]:
+ for path, subdirs, files in os.walk(root):
+ prefix = 'MAME_' + '_'.join([n.upper() for n in pathsplit(os.path.relpath(path, root))]) + '_'
+ for f in files:
+ if extpat.match(f):
+ expected = prefix + substpat.sub('_', f.upper())
+ fp = os.path.join(path, f)
+ with io.open(fp, 'r', encoding='utf-8') as fd:
+ for l in fd:
+ m = guardpat.match(l)
+ if m:
+ if m.group(1) != expected:
+ sys.stderr.write('%s: #include guard does not appear to match expected %s\n' % (fp, expected))
+ bad = True
+ break
+ if bad:
+ sys.exit(1)
diff --git a/src/devices/machine/dp8573a.h b/src/devices/machine/dp8573a.h
index 87b2eb5c314..8bf564bab66 100644
--- a/src/devices/machine/dp8573a.h
+++ b/src/devices/machine/dp8573a.h
@@ -1,8 +1,8 @@
// license:BSD-3-Clause
// copyright-holders:Ryan Holtz
-#ifndef MAME_MACHINE_DP8573_H
-#define MAME_MACHINE_DP8573_H
+#ifndef MAME_MACHINE_DP8573A_H
+#define MAME_MACHINE_DP8573A_H
#pragma once
@@ -70,4 +70,4 @@ protected:
DECLARE_DEVICE_TYPE(DP8572A, dp8572a_device)
DECLARE_DEVICE_TYPE(DP8573A, dp8573a_device)
-#endif // MAME_MACHINE_DP8573_H
+#endif // MAME_MACHINE_DP8573A_H
diff --git a/src/devices/sound/iopspu.h b/src/devices/sound/iopspu.h
index e771746c0ca..d52d3f2d4a4 100644
--- a/src/devices/sound/iopspu.h
+++ b/src/devices/sound/iopspu.h
@@ -9,8 +9,8 @@
*
*/
-#ifndef MAME_MACHINE_IOPSPU_H
-#define MAME_MACHINE_IOPSPU_H
+#ifndef MAME_SOUND_IOPSPU_H
+#define MAME_SOUND_IOPSPU_H
#pragma once
@@ -98,4 +98,4 @@ protected:
DECLARE_DEVICE_TYPE(SONYIOP_SPU, iop_spu_device)
-#endif // MAME_MACHINE_IOPSPU_H
+#endif // MAME_SOUND_IOPSPU_H
diff --git a/src/devices/sound/meg.h b/src/devices/sound/meg.h
index 53dad3a2616..046aca47ad5 100644
--- a/src/devices/sound/meg.h
+++ b/src/devices/sound/meg.h
@@ -5,8 +5,8 @@
//
// Audio dsp dedicated to effects generation, part of the SWP20 lineup
-#ifndef DEVICES_SOUND_MEG_H
-#define DEVICES_SOUND_MEG_H
+#ifndef MAME_SOUND_MEG_H
+#define MAME_SOUND_MEG_H
#pragma once
@@ -68,4 +68,4 @@ private:
DECLARE_DEVICE_TYPE(MEG, meg_device)
-#endif
+#endif // MAME_SOUND_MEG_H
diff --git a/src/devices/sound/nes_apu_vt.h b/src/devices/sound/nes_apu_vt.h
index 20336c13a78..f53d5b6ca7c 100644
--- a/src/devices/sound/nes_apu_vt.h
+++ b/src/devices/sound/nes_apu_vt.h
@@ -1,8 +1,8 @@
// license:BSD-3-Clause
// copyright-holders:David Haywood
-#ifndef MAME_AUDIO_NES_VT_APU_H
-#define MAME_AUDIO_NES_VT_APU_H
+#ifndef MAME_SOUND_NES_APU_VT_H
+#define MAME_SOUND_NES_APU_VT_H
#pragma once
@@ -23,4 +23,4 @@ protected:
private:
};
-#endif // MAME_AUDIO_NES_VT_APU_H
+#endif // MAME_SOUND_NES_APU_VT_H
diff --git a/src/devices/sound/nn71003f.h b/src/devices/sound/nn71003f.h
index 8471bbb6d13..bdf1803cf54 100644
--- a/src/devices/sound/nn71003f.h
+++ b/src/devices/sound/nn71003f.h
@@ -3,8 +3,8 @@
// Nippon Steel Corp NN71003F mpeg audio decoder
-#ifndef DEVICES_SOUND_NN71003F_H
-#define DEVICES_SOUND_NN71003F_H
+#ifndef MAME_SOUND_NN71003F_H
+#define MAME_SOUND_NN71003F_H
#pragma once
@@ -39,4 +39,4 @@ private:
DECLARE_DEVICE_TYPE(NN71003F, nn71003f_device)
-#endif
+#endif // MAME_SOUND_NN71003F_H
diff --git a/src/devices/sound/rp2c33_snd.h b/src/devices/sound/rp2c33_snd.h
index e60c036da8e..fb125b56747 100644
--- a/src/devices/sound/rp2c33_snd.h
+++ b/src/devices/sound/rp2c33_snd.h
@@ -6,8 +6,8 @@
***************************************************************************/
-#ifndef MAME_MACHINE_RP2C33_SND_H
-#define MAME_MACHINE_RP2C33_SND_H
+#ifndef MAME_SOUND_RP2C33_SND_H
+#define MAME_SOUND_RP2C33_SND_H
#pragma once
@@ -95,11 +95,4 @@ private:
// device type definition
DECLARE_DEVICE_TYPE(RP2C33_SOUND, rp2c33_sound_device)
-
-
-//**************************************************************************
-// GLOBAL VARIABLES
-//**************************************************************************
-
-
-#endif // MAME_MACHINE_RP2C33_SND_H
+#endif // MAME_SOUND_RP2C33_SND_H
diff --git a/src/devices/sound/segapcm.h b/src/devices/sound/segapcm.h
index a51c03f78b0..c89ab3e1859 100644
--- a/src/devices/sound/segapcm.h
+++ b/src/devices/sound/segapcm.h
@@ -4,8 +4,8 @@
/* SEGA 8bit PCM */
/*********************************************************/
-#ifndef MAMESOUND_SEGAPCM_H
-#define MAMESOUND_SEGAPCM_H
+#ifndef MAME_SOUND_SEGAPCM_H
+#define MAME_SOUND_SEGAPCM_H
#pragma once
@@ -56,4 +56,4 @@ private:
DECLARE_DEVICE_TYPE(SEGAPCM, segapcm_device)
-#endif // MAMESOUND_SEGAPCM_H
+#endif // MAME_SOUND_SEGAPCM_H
diff --git a/src/devices/sound/swp00.h b/src/devices/sound/swp00.h
index cdb56fb158f..22d8bc60db4 100644
--- a/src/devices/sound/swp00.h
+++ b/src/devices/sound/swp00.h
@@ -3,8 +3,8 @@
// Yamaha SWP00, rompler/dsp combo
-#ifndef DEVICES_SOUND_SWP00_H
-#define DEVICES_SOUND_SWP00_H
+#ifndef MAME_SOUND_SWP00_H
+#define MAME_SOUND_SWP00_H
#pragma once
@@ -247,4 +247,4 @@ private:
DECLARE_DEVICE_TYPE(SWP00, swp00_device)
-#endif
+#endif // MAME_SOUND_SWP00_H
diff --git a/src/devices/sound/swp20.h b/src/devices/sound/swp20.h
index df644bdad26..5d02a24f8cf 100644
--- a/src/devices/sound/swp20.h
+++ b/src/devices/sound/swp20.h
@@ -3,8 +3,8 @@
// Yamaha SWP20, rompler
-#ifndef DEVICES_SOUND_SWP20_H
-#define DEVICES_SOUND_SWP20_H
+#ifndef MAME_SOUND_SWP20_H
+#define MAME_SOUND_SWP20_H
#pragma once
@@ -72,4 +72,4 @@ private:
DECLARE_DEVICE_TYPE(SWP20, swp20_device)
-#endif
+#endif // MAME_SOUND_SWP20_H
diff --git a/src/devices/sound/swp30.h b/src/devices/sound/swp30.h
index 0ee30f4d264..e6b9d8be03e 100644
--- a/src/devices/sound/swp30.h
+++ b/src/devices/sound/swp30.h
@@ -3,8 +3,8 @@
// Yamaha SWP30/30B, rompler/dsp combo
-#ifndef DEVICES_SOUND_SWP30_H
-#define DEVICES_SOUND_SWP30_H
+#ifndef MAME_SOUND_SWP30_H
+#define MAME_SOUND_SWP30_H
#pragma once
@@ -239,4 +239,4 @@ private:
DECLARE_DEVICE_TYPE(SWP30, swp30_device)
-#endif
+#endif // MAME_SOUND_SWP30_H
diff --git a/src/devices/sound/swp30d.h b/src/devices/sound/swp30d.h
index d993f9f03f6..d6e13bb4c8d 100644
--- a/src/devices/sound/swp30d.h
+++ b/src/devices/sound/swp30d.h
@@ -7,8 +7,8 @@
//
// Disassembler
-#ifndef DEVICES_SOUND_SWP30D_H
-#define DEVICES_SOUND_SWP30D_H
+#ifndef MAME_SOUND_SWP30D_H
+#define MAME_SOUND_SWP30D_H
#pragma once
@@ -36,4 +36,4 @@ private:
static inline void append(std::string &r, const std::string &e);
};
-#endif
+#endif // MAME_SOUND_SWP30D_H
diff --git a/src/devices/sound/swx00.h b/src/devices/sound/swx00.h
index 0dc99c1b809..e35ddd0a63a 100644
--- a/src/devices/sound/swx00.h
+++ b/src/devices/sound/swx00.h
@@ -3,8 +3,8 @@
// Yamaha SWX00, rompler/dsp/cpu combo, audio support
-#ifndef DEVICES_SOUND_SWX00_H
-#define DEVICES_SOUND_SWX00_H
+#ifndef MAME_SOUND_SWX00_H
+#define MAME_SOUND_SWX00_H
#pragma once
@@ -123,4 +123,4 @@ private:
DECLARE_DEVICE_TYPE(SWX00_SOUND, swx00_sound_device)
-#endif
+#endif // MAME_SOUND_SWX00_H
diff --git a/src/devices/sound/vgm_visualizer.h b/src/devices/sound/vgm_visualizer.h
index 9f88bd90b0d..f201b117461 100644
--- a/src/devices/sound/vgm_visualizer.h
+++ b/src/devices/sound/vgm_visualizer.h
@@ -10,8 +10,8 @@
***************************************************************************/
-#ifndef MAME_SOUND_VGMVIZ_H
-#define MAME_SOUND_VGMVIZ_H
+#ifndef MAME_SOUND_VGM_VISUALIZER_H
+#define MAME_SOUND_VGM_VISUALIZER_H
#pragma once
@@ -137,4 +137,4 @@ protected:
static const bool NEEDS_FFT[VIZ_COUNT];
};
-#endif // MAME_SOUND_VGMVIZ_H
+#endif // MAME_SOUND_VGM_VISUALIZER_H
diff --git a/src/devices/video/ati_mach32.h b/src/devices/video/ati_mach32.h
index 90cff137afe..4afd4696421 100644
--- a/src/devices/video/ati_mach32.h
+++ b/src/devices/video/ati_mach32.h
@@ -6,8 +6,8 @@
* Created on: 16/05/2014
*/
-#ifndef MAME_BUS_ISA_MACH32_H
-#define MAME_BUS_ISA_MACH32_H
+#ifndef MAME_VIDEO_ATI_MACH32_H
+#define MAME_VIDEO_ATI_MACH32_H
#pragma once
@@ -240,4 +240,4 @@ DECLARE_DEVICE_TYPE(ATIMACH32_8514A, mach32_8514a_device)
DECLARE_DEVICE_TYPE(ATIMACH64, mach64_device)
DECLARE_DEVICE_TYPE(ATIMACH64_8514A, mach64_8514a_device)
-#endif // MAME_BUS_ISA_MACH32_H
+#endif // MAME_VIDEO_ATI_MACH32_H
diff --git a/src/devices/video/ati_mach8.h b/src/devices/video/ati_mach8.h
index b36037897fe..6daaa535c33 100644
--- a/src/devices/video/ati_mach8.h
+++ b/src/devices/video/ati_mach8.h
@@ -1,8 +1,8 @@
// license:BSD-3-Clause
// copyright-holders:Barry Rodewald
-#ifndef MAME_VIDEO_MACH8_H
-#define MAME_VIDEO_MACH8_H
+#ifndef MAME_VIDEO_ATI_MACH8_H
+#define MAME_VIDEO_ATI_MACH8_H
#pragma once
@@ -82,4 +82,4 @@ private:
// device type definition
DECLARE_DEVICE_TYPE(MACH8, mach8_device)
-#endif // MAME_VIDEO_MACH8_H
+#endif // MAME_VIDEO_ATI_MACH8_H
diff --git a/src/devices/video/imagetek_i4100.h b/src/devices/video/imagetek_i4100.h
index 47a906a3f74..07ebd6f3d5c 100644
--- a/src/devices/video/imagetek_i4100.h
+++ b/src/devices/video/imagetek_i4100.h
@@ -6,8 +6,8 @@
***************************************************************************/
-#ifndef MAME_VIDEO_I4100_H
-#define MAME_VIDEO_I4100_H
+#ifndef MAME_VIDEO_IMAGETEK_I4100_H
+#define MAME_VIDEO_IMAGETEK_I4100_H
#pragma once
@@ -266,11 +266,4 @@ DECLARE_DEVICE_TYPE(I4100, imagetek_i4100_device)
DECLARE_DEVICE_TYPE(I4220, imagetek_i4220_device)
DECLARE_DEVICE_TYPE(I4300, imagetek_i4300_device)
-
-
-//**************************************************************************
-// GLOBAL VARIABLES
-//**************************************************************************
-
-
-#endif // MAME_VIDEO_I4100_H
+#endif // MAME_VIDEO_IMAGETEK_I4100_H
diff --git a/src/devices/video/mb90082.h b/src/devices/video/mb90082.h
index 391036b987d..705bc530558 100644
--- a/src/devices/video/mb90082.h
+++ b/src/devices/video/mb90082.h
@@ -6,8 +6,8 @@
***************************************************************************/
-#ifndef MAME_VIDEO_MB90082DEV_H
-#define MAME_VIDEO_MB90082DEV_H
+#ifndef MAME_VIDEO_MB90082_H
+#define MAME_VIDEO_MB90082_H
#pragma once
@@ -68,4 +68,4 @@ private:
// device type definition
DECLARE_DEVICE_TYPE(MB90082, mb90082_device)
-#endif // MAME_VIDEO_MB90082DEV_H
+#endif // MAME_VIDEO_MB90082_H
diff --git a/src/devices/video/pc_vga_alliance.h b/src/devices/video/pc_vga_alliance.h
index 7220e4e8a49..85cfb15e493 100644
--- a/src/devices/video/pc_vga_alliance.h
+++ b/src/devices/video/pc_vga_alliance.h
@@ -1,8 +1,8 @@
// license:BSD-3-Clause
// copyright-holders:
-#ifndef MAME_VIDEO_PC_VGA_PROMOTION_H
-#define MAME_VIDEO_PC_VGA_PROMOTION_H
+#ifndef MAME_VIDEO_PC_VGA_ALLIANCE_H
+#define MAME_VIDEO_PC_VGA_ALLIANCE_H
#pragma once
@@ -37,4 +37,4 @@ private:
DECLARE_DEVICE_TYPE(PROMOTION_VGA, promotion_vga_device)
-#endif // MAME_VIDEO_PC_VGA_PROMOTION_H
+#endif // MAME_VIDEO_PC_VGA_ALLIANCE_H
diff --git a/src/devices/video/ppu2c0x_sh6578.h b/src/devices/video/ppu2c0x_sh6578.h
index 25648b2accf..8a673280b2a 100644
--- a/src/devices/video/ppu2c0x_sh6578.h
+++ b/src/devices/video/ppu2c0x_sh6578.h
@@ -4,8 +4,8 @@
******************************************************************************/
-#ifndef MAME_VIDEO_PPU_SH6578_H
-#define MAME_VIDEO_PPU_SH6578_H
+#ifndef MAME_VIDEO_PPU2C0X_SH6578_H
+#define MAME_VIDEO_PPU2C0X_SH6578_H
#pragma once
@@ -54,4 +54,4 @@ public:
DECLARE_DEVICE_TYPE(PPU_SH6578, ppu_sh6578_device)
DECLARE_DEVICE_TYPE(PPU_SH6578PAL, ppu_sh6578pal_device)
-#endif // MAME_VIDEO_PPU_SH6578_H
+#endif // MAME_VIDEO_PPU2C0X_SH6578_H
diff --git a/src/devices/video/ppu2c0x_vt.h b/src/devices/video/ppu2c0x_vt.h
index 16fca3da45d..d83120fe7df 100644
--- a/src/devices/video/ppu2c0x_vt.h
+++ b/src/devices/video/ppu2c0x_vt.h
@@ -9,8 +9,8 @@
******************************************************************************/
-#ifndef MAME_VIDEO_PPU_VT03_H
-#define MAME_VIDEO_PPU_VT03_H
+#ifndef MAME_VIDEO_PPU2C0X_VT_H
+#define MAME_VIDEO_PPU2C0X_VT_H
#pragma once
@@ -100,6 +100,6 @@ public:
};
DECLARE_DEVICE_TYPE(PPU_VT03, ppu_vt03_device)
-DECLARE_DEVICE_TYPE(PPU_VT03PAL, ppu_vt03pal_device)
+DECLARE_DEVICE_TYPE(PPU_VT03PAL, ppu_vt03pal_device)
-#endif // MAME_VIDEO_PPU_VT03_H
+#endif // MAME_VIDEO_PPU2C0X_VT_H
diff --git a/src/devices/video/wd90c26.h b/src/devices/video/wd90c26.h
index 5a866a2c227..5066113b75e 100644
--- a/src/devices/video/wd90c26.h
+++ b/src/devices/video/wd90c26.h
@@ -1,8 +1,8 @@
// license:BSD-3-Clause
// copyright-holders:Angelo Salese
-#ifndef MAME_VIDEO_WD902C26_H
-#define MAME_VIDEO_WD902C26_H
+#ifndef MAME_VIDEO_WD90C26_H
+#define MAME_VIDEO_WD90C26_H
#pragma once
@@ -21,4 +21,4 @@ protected:
DECLARE_DEVICE_TYPE(WD90C26, wd90c26_vga_device)
-#endif // MAME_VIDEO_WD902C26_H
+#endif // MAME_VIDEO_WD90C26_H
diff --git a/src/devices/video/zr36110.h b/src/devices/video/zr36110.h
index 8cc376ba7a3..c554d871bfd 100644
--- a/src/devices/video/zr36110.h
+++ b/src/devices/video/zr36110.h
@@ -3,8 +3,8 @@
// Zoran ZR36110 mpeg video decoder
-#ifndef MAME_VIDEO_ZR36110
-#define MAME_VIDEO_ZR36110
+#ifndef MAME_VIDEO_ZR36110_H
+#define MAME_VIDEO_ZR36110_H
#pragma once
@@ -95,5 +95,4 @@ private:
DECLARE_DEVICE_TYPE(ZR36110, zr36110_device)
-#endif
-
+#endif // MAME_VIDEO_ZR36110_H
diff --git a/src/mame/dynax/dynax.cpp b/src/mame/dynax/dynax.cpp
index 0e5e947329e..88f8986e11f 100644
--- a/src/mame/dynax/dynax.cpp
+++ b/src/mame/dynax/dynax.cpp
@@ -553,19 +553,9 @@ void dynax_adpcm_state::hjingi_lockout_w(int state)
machine().bookkeeping().coin_lockout_w(0, !state);
}
-void dynax_adpcm_state::hjingi_hopper_w(int state)
-{
- m_hopper = state;
-}
-
-uint8_t dynax_adpcm_state::hjingi_hopper_bit()
-{
- return (m_hopper && !(m_screen->frame_number() % 10)) ? 0 : (1 << 6);
-}
-
uint8_t dynax_adpcm_state::hjingi_keyboard_0_r()
{
- return hanamai_keyboard_0_r() | hjingi_hopper_bit();
+ return hanamai_keyboard_0_r() | (m_hopper->line_r() ? 0 : (1 << 6));
}
uint8_t dynax_adpcm_state::hjingi_keyboard_1_r()
@@ -999,7 +989,7 @@ void dynax_adpcm_state::mjembase_io_map(address_map &map)
map(0x20, 0x20).w(FUNC(dynax_adpcm_state::hanamai_keyboard_w)); // keyboard row select
map(0x21, 0x21).portr("COINS"); // Coins
map(0x22, 0x22).r(FUNC(dynax_adpcm_state::mjelctrn_keyboard_1_r)); // P2
- map(0x23, 0x23).r(FUNC(dynax_adpcm_state::hanamai_keyboard_0_r)); // P1
+ map(0x23, 0x23).r(FUNC(dynax_adpcm_state::hjingi_keyboard_0_r)); // P1
map(0x24, 0x24).portr("DSW3");
// map(0x40, 0x40).nopw(); // CRT Controller
// map(0x41, 0x41).nopw(); // CRT Controller
@@ -1520,83 +1510,23 @@ static INPUT_PORTS_START( MAHJONG_KEYS )
INPUT_PORTS_END
static INPUT_PORTS_START( MAHJONG_KEYS_BET )
- PORT_START("KEY0")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_A ) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_E ) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_I ) PORT_PLAYER(1)
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_M ) PORT_PLAYER(1)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_KAN ) PORT_PLAYER(1)
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_START1 )
+ PORT_INCLUDE( MAHJONG_KEYS )
- PORT_START("KEY1")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_B ) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_F ) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_J ) PORT_PLAYER(1)
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_N ) PORT_PLAYER(1)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_REACH ) PORT_PLAYER(1)
+ PORT_MODIFY("KEY1")
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_BET ) PORT_PLAYER(1)
- PORT_START("KEY2")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_C ) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_G ) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_K ) PORT_PLAYER(1)
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_CHI ) PORT_PLAYER(1)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_RON ) PORT_PLAYER(1)
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY3")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_D ) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_H ) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_L ) PORT_PLAYER(1)
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_PON ) PORT_PLAYER(1)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY4")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_LAST_CHANCE ) PORT_PLAYER(1) // "l"
+ PORT_MODIFY("KEY4")
PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_SCORE ) PORT_PLAYER(1) // "t"
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_DOUBLE_UP ) PORT_PLAYER(1) // "w"
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_FLIP_FLOP ) PORT_PLAYER(1) // "f"
PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_BIG ) PORT_PLAYER(1) // "b"
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_SMALL ) PORT_PLAYER(1) // "s"
- PORT_START("KEY5")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_A ) PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_E ) PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_I ) PORT_PLAYER(2)
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_M ) PORT_PLAYER(2)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_KAN ) PORT_PLAYER(2)
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_START2 )
-
- PORT_START("KEY6")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_B ) PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_F ) PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_J ) PORT_PLAYER(2)
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_N ) PORT_PLAYER(2)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_REACH ) PORT_PLAYER(2)
+ PORT_MODIFY("KEY6")
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_BET ) PORT_PLAYER(2)
- PORT_START("KEY7")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_C ) PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_G ) PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_K ) PORT_PLAYER(2)
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_CHI ) PORT_PLAYER(2)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_RON ) PORT_PLAYER(2)
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY8")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_D ) PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_H ) PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_L ) PORT_PLAYER(2)
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_PON ) PORT_PLAYER(2)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY9")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_LAST_CHANCE ) PORT_PLAYER(2) // "l"
+ PORT_MODIFY("KEY9")
PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_SCORE ) PORT_PLAYER(2) // "t"
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_DOUBLE_UP ) PORT_PLAYER(2) // "w"
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_FLIP_FLOP ) PORT_PLAYER(2) // "f"
PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_BIG ) PORT_PLAYER(2) // "b"
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_SMALL ) PORT_PLAYER(2) // "s"
INPUT_PORTS_END
@@ -1684,173 +1614,63 @@ static INPUT_PORTS_START( HANAFUDA_KEYS )
INPUT_PORTS_END
INPUT_PORTS_START( HANAFUDA_KEYS_BET )
- PORT_START("KEY0")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_A ) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_E ) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_HANAFUDA_YES ) PORT_PLAYER(1)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_START1 )
+ PORT_INCLUDE( HANAFUDA_KEYS )
- PORT_START("KEY1")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_B ) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_F ) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_HANAFUDA_NO ) PORT_PLAYER(1)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
+ PORT_MODIFY("KEY1")
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_BET ) PORT_PLAYER(1)
- PORT_START("KEY2")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_C ) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_G ) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY3")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_D ) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_H ) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY4")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_LAST_CHANCE ) // "l"
+ PORT_MODIFY("KEY4")
PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_SCORE ) // "t"
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_DOUBLE_UP ) // "w"
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_FLIP_FLOP ) // "f"
PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_BIG ) // "b"
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_SMALL ) // "s"
- PORT_START("KEY5")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_A ) PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_E ) PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_HANAFUDA_YES ) PORT_PLAYER(2)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_START2 )
-
- PORT_START("KEY6")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_B ) PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_F ) PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_HANAFUDA_NO ) PORT_PLAYER(2)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
+ PORT_MODIFY("KEY6")
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_BET ) PORT_PLAYER(2)
- PORT_START("KEY7")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_C ) PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_G ) PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY8")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_D ) PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_H ) PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY9")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_LAST_CHANCE ) PORT_PLAYER(2) // "l"
+ PORT_MODIFY("KEY9")
PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_MAHJONG_SCORE ) PORT_PLAYER(2) // "t"
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_MAHJONG_DOUBLE_UP ) PORT_PLAYER(2) // "w"
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_FLIP_FLOP ) PORT_PLAYER(2) // "f"
PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_BIG ) PORT_PLAYER(2) // "b"
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_MAHJONG_SMALL ) PORT_PLAYER(2) // "s"
INPUT_PORTS_END
-/*
+
+#if 0
[[maybe_unused]] static INPUT_PORTS_START( HANAFUDA_KEYS_BET_ALT )
- PORT_START("KEY0")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_A ) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_E ) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_HANAFUDA_YES ) PORT_PLAYER(1)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_SCORE ) // "t"
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_START1 )
-
- PORT_START("KEY1")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_B ) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_F ) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_HANAFUDA_NO ) PORT_PLAYER(1)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_SMALL ) // "s"
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY2")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_C ) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_G ) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_BIG ) // "b"
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY3")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_D ) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_H ) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_DOUBLE_UP ) // "w"
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY4")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY5")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_A ) PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_E ) PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_HANAFUDA_YES ) PORT_PLAYER(2)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_SCORE ) PORT_PLAYER(2) // "t"
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_START2 )
-
- PORT_START("KEY6")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_B ) PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_F ) PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_HANAFUDA_NO ) PORT_PLAYER(2)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_SMALL ) PORT_PLAYER(2) // "s"
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY7")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_C ) PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_G ) PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_BIG ) PORT_PLAYER(2) // "b"
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY8")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_HANAFUDA_D ) PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_HANAFUDA_H ) PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_DOUBLE_UP ) PORT_PLAYER(2) // "w"
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
-
- PORT_START("KEY9")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN )
+ PORT_INCLUDE( HANAFUDA_KEYS )
+
+ PORT_MODIFY("KEY0")
+ PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_SCORE ) // "t"
+
+ PORT_MODIFY("KEY1")
+ PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_SMALL ) // "s"
+
+ PORT_MODIFY("KEY2")
+ PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_BIG ) // "b"
+
+ PORT_MODIFY("KEY3")
+ PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_DOUBLE_UP ) // "w"
+
+ PORT_MODIFY("KEY4")
+ PORT_BIT( 0xff, IP_ACTIVE_LOW, IPT_UNKNOWN )
+
+ PORT_MODIFY("KEY5")
+ PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_SCORE ) PORT_PLAYER(2) // "t"
+
+ PORT_MODIFY("KEY6")
+ PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MAHJONG_SMALL ) PORT_PLAYER(2) // "s"
+
+ PORT_MODIFY("KEY7")
+ PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_BIG ) PORT_PLAYER(2) // "b"
+
+ PORT_MODIFY("KEY8")
+ PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_MAHJONG_DOUBLE_UP ) PORT_PLAYER(2) // "w"
+
+ PORT_MODIFY("KEY9")
+ PORT_BIT( 0xff, IP_ACTIVE_LOW, IPT_UNKNOWN )
INPUT_PORTS_END
-*/
+#endif
+
static INPUT_PORTS_START( cdracula )
PORT_START("P1")
PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_PLAYER(1)
@@ -3161,124 +2981,131 @@ INPUT_PORTS_END
static INPUT_PORTS_START( mjembase )
PORT_START("DSW2") /* DIP1, 7c20 (port $1e) */
- PORT_DIPNAME( 0x0f, 0x07, "Pay Out Rate" )
- PORT_DIPSETTING( 0x00, "50" )
- PORT_DIPSETTING( 0x01, "53" )
- PORT_DIPSETTING( 0x02, "56" )
- PORT_DIPSETTING( 0x03, "59" )
- PORT_DIPSETTING( 0x04, "62" )
- PORT_DIPSETTING( 0x05, "65" )
- PORT_DIPSETTING( 0x06, "68" )
- PORT_DIPSETTING( 0x07, "71" )
- PORT_DIPSETTING( 0x08, "75" )
- PORT_DIPSETTING( 0x09, "78" )
- PORT_DIPSETTING( 0x0a, "81" )
- PORT_DIPSETTING( 0x0b, "84" )
- PORT_DIPSETTING( 0x0c, "87" )
- PORT_DIPSETTING( 0x0d, "90" )
- PORT_DIPSETTING( 0x0e, "93" )
- PORT_DIPSETTING( 0x0f, "96" )
- PORT_DIPNAME( 0x30, 0x30, "Max Bet" )
+ PORT_DIPNAME( 0x0f, 0x07, "Payout Rate" ) PORT_DIPLOCATION("SW 1:1,2,3,4")
+ PORT_DIPSETTING( 0x00, "50%" )
+ PORT_DIPSETTING( 0x01, "53%" )
+ PORT_DIPSETTING( 0x02, "56%" )
+ PORT_DIPSETTING( 0x03, "59%" )
+ PORT_DIPSETTING( 0x04, "62%" )
+ PORT_DIPSETTING( 0x05, "65%" )
+ PORT_DIPSETTING( 0x06, "68%" )
+ PORT_DIPSETTING( 0x07, "71%" )
+ PORT_DIPSETTING( 0x08, "75%" )
+ PORT_DIPSETTING( 0x09, "78%" )
+ PORT_DIPSETTING( 0x0a, "81%" )
+ PORT_DIPSETTING( 0x0b, "84%" )
+ PORT_DIPSETTING( 0x0c, "87%" )
+ PORT_DIPSETTING( 0x0d, "90%" )
+ PORT_DIPSETTING( 0x0e, "93%" )
+ PORT_DIPSETTING( 0x0f, "96%" )
+ PORT_DIPNAME( 0x30, 0x10, "Maximum Bet" ) PORT_DIPLOCATION("SW 1:5,6")
PORT_DIPSETTING( 0x30, "1" )
PORT_DIPSETTING( 0x20, "5" )
PORT_DIPSETTING( 0x10, "10" )
PORT_DIPSETTING( 0x00, "20" )
- PORT_DIPNAME( 0x40, 0x40, DEF_STR( Coin_B ) )
- PORT_DIPSETTING( 0x40, DEF_STR( 1C_5C ) )
- PORT_DIPSETTING( 0x00, "1 Coin/10 Credits" )
- PORT_DIPNAME( 0x80, 0x80, DEF_STR( Flip_Screen ) )
- PORT_DIPSETTING( 0x80, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, "Credits Per Note" ) PORT_DIPLOCATION("SW 1:7")
+ PORT_DIPSETTING( 0x40, "5" ) PORT_CONDITION("DSW1", 0x0c, EQUALS, 0x0c)
+ PORT_DIPSETTING( 0x40, "10" ) PORT_CONDITION("DSW1", 0x0c, EQUALS, 0x08)
+ PORT_DIPSETTING( 0x40, "25" ) PORT_CONDITION("DSW1", 0x0c, EQUALS, 0x04)
+ PORT_DIPSETTING( 0x40, "50" ) PORT_CONDITION("DSW1", 0x0c, EQUALS, 0x00)
+ PORT_DIPSETTING( 0x00, "10" ) PORT_CONDITION("DSW1", 0x0c, EQUALS, 0x0c)
+ PORT_DIPSETTING( 0x00, "20" ) PORT_CONDITION("DSW1", 0x0c, EQUALS, 0x08)
+ PORT_DIPSETTING( 0x00, "50" ) PORT_CONDITION("DSW1", 0x0c, EQUALS, 0x04)
+ PORT_DIPSETTING( 0x00, "100" ) PORT_CONDITION("DSW1", 0x0c, EQUALS, 0x00)
+ PORT_DIPNAME( 0x80, 0x80, DEF_STR(Flip_Screen) ) PORT_DIPLOCATION("SW 1:8")
+ PORT_DIPSETTING( 0x80, DEF_STR(Off) )
+ PORT_DIPSETTING( 0x00, DEF_STR(On) )
PORT_START("DSW1") /* DIP2, 7c21 (port $1c) */
- PORT_DIPNAME( 0x03, 0x03, "Difficulty?" )
- PORT_DIPSETTING( 0x03, "0" ) // 20
- PORT_DIPSETTING( 0x00, "1" ) // 32
- PORT_DIPSETTING( 0x01, "2" ) // 64
- PORT_DIPSETTING( 0x02, "3" ) // c8
- PORT_DIPNAME( 0x0c, 0x0c, DEF_STR( Coin_A ) )
- PORT_DIPSETTING( 0x0c, DEF_STR( 1C_1C ) )
- PORT_DIPSETTING( 0x08, DEF_STR( 1C_2C ) )
- PORT_DIPSETTING( 0x04, DEF_STR( 1C_5C ) )
+ PORT_DIPNAME( 0x03, 0x00, "Odds Rate" ) PORT_DIPLOCATION("SW 2:1,2")
+ PORT_DIPSETTING( 0x03, "1 2 4 8 12 16 24 32" )
+ PORT_DIPSETTING( 0x00, "1 2 3 5 8 15 30 50" )
+ PORT_DIPSETTING( 0x01, "1 2 3 5 10 25 50 100" )
+ PORT_DIPSETTING( 0x02, "1 2 3 5 10 50 100 200" )
+ PORT_DIPNAME( 0x0c, 0x0c, DEF_STR(Coinage) ) PORT_DIPLOCATION("SW 2:3,4")
+ PORT_DIPSETTING( 0x0c, DEF_STR(1C_1C) )
+ PORT_DIPSETTING( 0x08, DEF_STR(1C_2C) )
+ PORT_DIPSETTING( 0x04, DEF_STR(1C_5C) )
PORT_DIPSETTING( 0x00, "1 Coin/10 Credits" )
- PORT_DIPNAME( 0x30, 0x30, "Min Pay?" )
+ PORT_DIPNAME( 0x30, 0x30, "Minimum Bet" ) PORT_DIPLOCATION("SW 2:5,6")
PORT_DIPSETTING( 0x30, "1" )
PORT_DIPSETTING( 0x20, "2" )
PORT_DIPSETTING( 0x10, "3" )
PORT_DIPSETTING( 0x00, "5" )
- PORT_DIPNAME( 0x40, 0x40, "Allow Coin Out" )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x40, DEF_STR( On ) )
- PORT_DIPNAME( 0x80, 0x80, "Win A Prize?" )
- PORT_DIPSETTING( 0x80, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x40, "Payout Mode" ) PORT_DIPLOCATION("SW 2:7")
+ PORT_DIPSETTING( 0x40, "Key-out" )
+ PORT_DIPSETTING( 0x00, "Hopper" )
+ PORT_DIPNAME( 0x80, 0x80, "Hopper Polarity" ) PORT_DIPLOCATION("SW 2:8")
+ PORT_DIPSETTING( 0x80, DEF_STR(Normal) )
+ PORT_DIPSETTING( 0x00, "Inverted" )
PORT_START("DSW0") /* DIP3, 7c22 (port $06, AY) */ /* note that these are in reverse order wrt the others */
- PORT_DIPNAME( 0x01, 0x01, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x01, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x00, DEF_STR( On ) )
- PORT_DIPNAME( 0x02, 0x02, "DonDen Key" )
+ PORT_DIPNAME( 0x01, 0x01, "Disable H Pose" ) PORT_DIPLOCATION("SW 3:8")
+ PORT_DIPSETTING( 0x01, DEF_STR(No) )
+ PORT_DIPSETTING( 0x00, DEF_STR(Yes) ) // win sequences show scrolling images of gals wearing bikinis irrespective of SW 4-8 setting
+ PORT_DIPNAME( 0x02, 0x00, "Don Den Button" ) PORT_DIPLOCATION("SW 3:7")
PORT_DIPSETTING( 0x02, "A" )
PORT_DIPSETTING( 0x00, "Flip Flop" )
- PORT_DIPNAME( 0x04, 0x04, "Draw New Tile" )
- PORT_DIPSETTING( 0x00, "Automatic" )
- PORT_DIPSETTING( 0x04, "Manual" )
- PORT_DIPNAME( 0x08, 0x08, "Win Rate?" )
- PORT_DIPSETTING( 0x08, DEF_STR( High ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Low ) )
- PORT_DIPNAME( 0x10, 0x10, "YAKU times" )
+ PORT_DIPNAME( 0x04, 0x00, "Service Count" ) PORT_DIPLOCATION("SW 3:6")
+ PORT_DIPSETTING( 0x04, DEF_STR(Off) )
+ PORT_DIPSETTING( 0x00, DEF_STR(On) )
+ PORT_DIPNAME( 0x08, 0x00, "Computer Strength" ) PORT_DIPLOCATION("SW 3:5")
+ PORT_DIPSETTING( 0x00, DEF_STR(Normal) )
+ PORT_DIPSETTING( 0x08, "Strong" )
+ PORT_DIPNAME( 0x10, 0x10, "Yakuman Bonuses Per Cycle" ) PORT_DIPLOCATION("SW 3:4")
PORT_DIPSETTING( 0x10, "1" )
PORT_DIPSETTING( 0x00, "2" )
- PORT_DIPNAME( 0xe0, 0xe0, "YAKUMAN Bonus" )
- PORT_DIPSETTING( 0xe0, "Cut" )
- PORT_DIPSETTING( 0x60, "1 T" )
- PORT_DIPSETTING( 0xa0, "300" )
- PORT_DIPSETTING( 0x20, "500" )
- PORT_DIPSETTING( 0xc0, "700" )
- PORT_DIPSETTING( 0x40, "1000" )
-// PORT_DIPSETTING( 0x80, "1000" )
-// PORT_DIPSETTING( 0x00, "1000" )
+ PORT_DIPNAME( 0xe0, 0xc0, "Yakuman Bonus Cycle" ) PORT_DIPLOCATION("SW 3:3,2,1")
+ PORT_DIPSETTING( 0xe0, "None" )
+ PORT_DIPSETTING( 0x60, "First time only" )
+ PORT_DIPSETTING( 0xa0, "Every 300 coins" )
+ PORT_DIPSETTING( 0x20, "Every 500 coins" )
+ PORT_DIPSETTING( 0xc0, "Every 700 coins" )
+ PORT_DIPSETTING( 0x40, "Every 1000 coins" )
+// PORT_DIPSETTING( 0x80, "Every 1000 coins" )
+// PORT_DIPSETTING( 0x00, "Every 1000 coins" )
PORT_START("DSW3") /* DIP4, 7c23 (port $24) */
- PORT_DIPNAME( 0x01, 0x01, "Last Chance" )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x01, DEF_STR( On ) )
- PORT_DIPNAME( 0x02, 0x02, "Pay Rate?" )
- PORT_DIPSETTING( 0x02, DEF_STR( High ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Low ) )
- PORT_DIPNAME( 0x04, 0x04, "Choose Bonus" )
- PORT_DIPSETTING( 0x04, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x00, DEF_STR( On ) )
- PORT_DIPNAME( 0x08, 0x08, "In-Game Bet?" )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x08, DEF_STR( On ) )
- PORT_DIPNAME( 0x10, 0x00, DEF_STR( Demo_Sounds ) )
- PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x00, DEF_STR( On ) )
- PORT_DIPNAME( 0x20, 0x00, "In-Game Music" )
- PORT_DIPSETTING( 0x20, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x00, DEF_STR( On ) )
- PORT_DIPNAME( 0x40, 0x40, "Select Girl" )
- PORT_DIPSETTING( 0x40, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x00, DEF_STR( On ) )
- PORT_DIPNAME( 0x80, 0x00, "Nudity" )
- PORT_DIPSETTING( 0x00, DEF_STR( Yes ) )
- PORT_DIPSETTING( 0x80, DEF_STR( No ) ) // Moles On Gal's Face
+ PORT_DIPNAME( 0x01, 0x01, "Last Chance" ) PORT_DIPLOCATION("SW 4:1")
+ PORT_DIPSETTING( 0x01, "Free" )
+ PORT_DIPSETTING( 0x00, "Paid" )
+ PORT_DIPNAME( 0x02, 0x00, "Renchan Rate" ) PORT_DIPLOCATION("SW 4:2")
+ PORT_DIPSETTING( 0x02, DEF_STR(Off) )
+ PORT_DIPSETTING( 0x00, DEF_STR(On) )
+ PORT_DIPNAME( 0x04, 0x00, "Auto Tsumo" ) PORT_DIPLOCATION("SW 4:3")
+ PORT_DIPSETTING( 0x04, DEF_STR(Off) )
+ PORT_DIPSETTING( 0x00, DEF_STR(On) )
+ PORT_DIPNAME( 0x08, 0x00, "Double Up" ) PORT_DIPLOCATION("SW 4:4")
+ PORT_DIPSETTING( 0x08, DEF_STR(Off) )
+ PORT_DIPSETTING( 0x00, DEF_STR(On) ) // press Bet during game to double the bet
+ PORT_DIPNAME( 0x10, 0x00, DEF_STR(Demo_Sounds) ) PORT_DIPLOCATION("SW 4:5")
+ PORT_DIPSETTING( 0x10, DEF_STR(Off) )
+ PORT_DIPSETTING( 0x00, DEF_STR(On) )
+ PORT_DIPNAME( 0x20, 0x00, "In-Game Music" ) PORT_DIPLOCATION("SW 4:6")
+ PORT_DIPSETTING( 0x20, DEF_STR(Off) )
+ PORT_DIPSETTING( 0x00, DEF_STR(On) )
+ PORT_DIPNAME( 0x40, 0x40, "Gal Selectt" ) PORT_DIPLOCATION("SW 4:7")
+ PORT_DIPSETTING( 0x40, DEF_STR(Off) )
+ PORT_DIPSETTING( 0x00, DEF_STR(On) )
+ PORT_DIPNAME( 0x80, 0x80, "Gal H Pose" ) PORT_DIPLOCATION("SW 4:8")
+ PORT_DIPSETTING( 0x80, DEF_STR(Off) ) // shows moles on gals' faces, win sequences show scrolling images of gals wearing bikinis
+ PORT_DIPSETTING( 0x00, DEF_STR(On) ) // win sequences show "interaction" with gals if SW 3-8 is off
PORT_START("FAKE") /* IN10 - Fake DSW */
- PORT_DIPNAME( 0xff, 0xff, "Allow Bets" )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0xff, DEF_STR( On ) )
+ PORT_CONFNAME( 0xff, 0xff, "Allow Bets" )
+ PORT_CONFSETTING( 0x00, DEF_STR( Off ) )
+ PORT_CONFSETTING( 0xff, DEF_STR( On ) )
PORT_START("COINS")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_GAMBLE_PAYOUT ) PORT_CODE(KEYCODE_4) // Pay
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) // 18B
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE ) // Test
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_GAMBLE_BOOK ) // Analyzer
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MEMORY_RESET ) // Memory Reset
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN2 ) // Note
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_COIN1 ) // Coin
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SERVICE1 ) // Service
+ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_GAMBLE_PAYOUT ) PORT_CODE(KEYCODE_4) PORT_CONDITION("DSW1", 0x40, EQUALS, 0x00) // Pay
+ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_GAMBLE_KEYOUT ) PORT_CONDITION("DSW1", 0x40, EQUALS, 0x40)
+ PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) // 18B
+ PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE ) PORT_TOGGLE // Test
+ PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_GAMBLE_BOOK ) // Analyzer
+ PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MEMORY_RESET ) // Memory Reset
+ PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BILL1 ) PORT_CODE(KEYCODE_6) // Note
+ PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_COIN1 ) // Coin
+ PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SERVICE1 ) // Service
PORT_INCLUDE( MAHJONG_KEYS_BET )
INPUT_PORTS_END
@@ -3417,13 +3244,13 @@ INPUT_PORTS_END
static INPUT_PORTS_START( mjelctrn )
PORT_START("COINS")
PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_GAMBLE_PAYOUT ) PORT_CODE(KEYCODE_4) // Pay
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) // 18B
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE ) // Test
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_GAMBLE_BOOK ) // Analyzer
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MEMORY_RESET ) // Memory Reset
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN2 ) // Note
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_COIN1 ) // Coin
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SERVICE1 ) // Service
+ PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) // 18B
+ PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE ) PORT_TOGGLE // Test
+ PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_GAMBLE_BOOK ) // Analyzer
+ PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MEMORY_RESET ) // Memory Reset
+ PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BILL1 ) PORT_CODE(KEYCODE_6) // Note
+ PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_COIN1 ) // Coin
+ PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SERVICE1 ) // Service
PORT_INCLUDE( MAHJONG_KEYS_BET )
@@ -3437,12 +3264,12 @@ static INPUT_PORTS_START( mjelctrn )
PORT_DIPSETTING( 0x00, "1" ) // 32
PORT_DIPSETTING( 0x01, "2" ) // 64
PORT_DIPSETTING( 0x02, "3" ) // c8
- PORT_DIPNAME( 0x0c, 0x0c, DEF_STR( Coin_A ) ) PORT_DIPLOCATION("SW3:3,4")
+ PORT_DIPNAME( 0x0c, 0x0c, DEF_STR(Coinage) ) PORT_DIPLOCATION("SW3:3,4")
PORT_DIPSETTING( 0x0c, DEF_STR( 1C_1C ) )
PORT_DIPSETTING( 0x08, DEF_STR( 1C_2C ) )
PORT_DIPSETTING( 0x04, DEF_STR( 1C_5C ) )
PORT_DIPSETTING( 0x00, "1 Coin/10 Credits" )
- PORT_DIPNAME( 0x30, 0x30, "Min Pay?" ) PORT_DIPLOCATION("SW3:5,6")
+ PORT_DIPNAME( 0x30, 0x30, "Minimum Bet" ) PORT_DIPLOCATION("SW3:5,6")
PORT_DIPSETTING( 0x30, "1" )
PORT_DIPSETTING( 0x20, "2" )
PORT_DIPSETTING( 0x10, "3" )
@@ -3455,46 +3282,52 @@ static INPUT_PORTS_START( mjelctrn )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_START("DSW1") /* 7c20 (select = 40) */
- PORT_DIPNAME( 0x0f, 0x07, "Pay Out Rate" ) PORT_DIPLOCATION("SW4:1,2,3,4")
- PORT_DIPSETTING( 0x00, "50" )
- PORT_DIPSETTING( 0x01, "53" )
- PORT_DIPSETTING( 0x02, "56" )
- PORT_DIPSETTING( 0x03, "59" )
- PORT_DIPSETTING( 0x04, "62" )
- PORT_DIPSETTING( 0x05, "65" )
- PORT_DIPSETTING( 0x06, "68" )
- PORT_DIPSETTING( 0x07, "71" )
- PORT_DIPSETTING( 0x08, "75" )
- PORT_DIPSETTING( 0x09, "78" )
- PORT_DIPSETTING( 0x0a, "81" )
- PORT_DIPSETTING( 0x0b, "84" )
- PORT_DIPSETTING( 0x0c, "87" )
- PORT_DIPSETTING( 0x0d, "90" )
- PORT_DIPSETTING( 0x0e, "93" )
- PORT_DIPSETTING( 0x0f, "96" )
- PORT_DIPNAME( 0x30, 0x30, "Max Bet" ) PORT_DIPLOCATION("SW4:5,6")
+ PORT_DIPNAME( 0x0f, 0x07, "Payout Rate" ) PORT_DIPLOCATION("SW4:1,2,3,4")
+ PORT_DIPSETTING( 0x00, "50%" )
+ PORT_DIPSETTING( 0x01, "53%" )
+ PORT_DIPSETTING( 0x02, "56%" )
+ PORT_DIPSETTING( 0x03, "59%" )
+ PORT_DIPSETTING( 0x04, "62%" )
+ PORT_DIPSETTING( 0x05, "65%" )
+ PORT_DIPSETTING( 0x06, "68%" )
+ PORT_DIPSETTING( 0x07, "71%" )
+ PORT_DIPSETTING( 0x08, "75%" )
+ PORT_DIPSETTING( 0x09, "78%" )
+ PORT_DIPSETTING( 0x0a, "81%" )
+ PORT_DIPSETTING( 0x0b, "84%" )
+ PORT_DIPSETTING( 0x0c, "87%" )
+ PORT_DIPSETTING( 0x0d, "90%" )
+ PORT_DIPSETTING( 0x0e, "93%" )
+ PORT_DIPSETTING( 0x0f, "96%" )
+ PORT_DIPNAME( 0x30, 0x10, "Maximum Bet" ) PORT_DIPLOCATION("SW4:5,6")
PORT_DIPSETTING( 0x30, "1" )
PORT_DIPSETTING( 0x20, "5" )
PORT_DIPSETTING( 0x10, "10" )
PORT_DIPSETTING( 0x00, "20" )
- PORT_DIPNAME( 0x40, 0x40, DEF_STR( Coin_B ) ) PORT_DIPLOCATION("SW4:7")
- PORT_DIPSETTING( 0x40, DEF_STR( 1C_5C ) )
- PORT_DIPSETTING( 0x00, "1 Coin/10 Credits" )
+ PORT_DIPNAME( 0x40, 0x00, "Credits Per Note" ) PORT_DIPLOCATION("SW4:7")
+ PORT_DIPSETTING( 0x40, "5" ) PORT_CONDITION("DSW0", 0x0c, EQUALS, 0x0c)
+ PORT_DIPSETTING( 0x40, "10" ) PORT_CONDITION("DSW0", 0x0c, EQUALS, 0x08)
+ PORT_DIPSETTING( 0x40, "25" ) PORT_CONDITION("DSW0", 0x0c, EQUALS, 0x04)
+ PORT_DIPSETTING( 0x40, "50" ) PORT_CONDITION("DSW0", 0x0c, EQUALS, 0x00)
+ PORT_DIPSETTING( 0x00, "10" ) PORT_CONDITION("DSW0", 0x0c, EQUALS, 0x0c)
+ PORT_DIPSETTING( 0x00, "20" ) PORT_CONDITION("DSW0", 0x0c, EQUALS, 0x08)
+ PORT_DIPSETTING( 0x00, "50" ) PORT_CONDITION("DSW0", 0x0c, EQUALS, 0x04)
+ PORT_DIPSETTING( 0x00, "100" ) PORT_CONDITION("DSW0", 0x0c, EQUALS, 0x00)
PORT_DIPNAME( 0x80, 0x80, DEF_STR( Flip_Screen ) ) PORT_DIPLOCATION("SW4:8")
PORT_DIPSETTING( 0x80, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_START("DSW2") /* 7c22 (select = 80) */
- PORT_DIPNAME( 0x07, 0x07, "YAKUMAN Bonus" ) PORT_DIPLOCATION("SW2:1,2,3")
- PORT_DIPSETTING( 0x07, "Cut" )
- PORT_DIPSETTING( 0x06, "1 T" )
- PORT_DIPSETTING( 0x05, "300" )
- PORT_DIPSETTING( 0x04, "500" )
- PORT_DIPSETTING( 0x03, "700" )
- PORT_DIPSETTING( 0x02, "1000" )
-// PORT_DIPSETTING( 0x01, "1000" )
-// PORT_DIPSETTING( 0x00, "1000" )
- PORT_DIPNAME( 0x08, 0x08, "YAKU times" ) PORT_DIPLOCATION("SW2:4")
+ PORT_DIPNAME( 0x07, 0x04, "Yakuman Bonus Cycle" ) PORT_DIPLOCATION("SW2:1,2,3")
+ PORT_DIPSETTING( 0x07, "None" )
+ PORT_DIPSETTING( 0x06, "First time only" )
+ PORT_DIPSETTING( 0x05, "Every 300 coins" )
+ PORT_DIPSETTING( 0x04, "Every 500 coins" )
+ PORT_DIPSETTING( 0x03, "Every 700 coins" )
+ PORT_DIPSETTING( 0x02, "Every 1000 coins" )
+// PORT_DIPSETTING( 0x01, "Every 1000 coins" )
+// PORT_DIPSETTING( 0x00, "Every 1000 coins" )
+ PORT_DIPNAME( 0x08, 0x08, "Yakuman Bonuses Per Cycle" ) PORT_DIPLOCATION("SW2:4")
PORT_DIPSETTING( 0x08, "1" )
PORT_DIPSETTING( 0x00, "2" )
PORT_DIPNAME( 0x10, 0x10, "Win Rate?" ) PORT_DIPLOCATION("SW2:5")
@@ -4308,7 +4141,6 @@ void dynax_adpcm_state::machine_start()
save_item(NAME(m_msm5205next));
save_item(NAME(m_resetkludge));
- save_item(NAME(m_hopper));
save_item(NAME(m_toggle));
}
@@ -4318,7 +4150,6 @@ void dynax_adpcm_state::machine_reset()
m_msm5205next = 0;
m_resetkludge = 0;
- m_hopper = 0;
m_toggle = 0;
// start with the MSM5205 reset
@@ -4552,9 +4383,11 @@ void dynax_adpcm_state::hjingi(machine_config &config)
ls259_device &outlatch(LS259(config, "outlatch"));
outlatch.q_out_cb<0>().set(FUNC(dynax_adpcm_state::coincounter_0_w));
outlatch.q_out_cb<1>().set(FUNC(dynax_adpcm_state::coincounter_1_w));
- outlatch.q_out_cb<2>().set(FUNC(dynax_adpcm_state::hjingi_hopper_w));
+ outlatch.q_out_cb<2>().set(m_hopper, FUNC(hopper_device::motor_w));
outlatch.q_out_cb<3>().set(FUNC(dynax_adpcm_state::hjingi_lockout_w));
+ HOPPER(config, m_hopper, attotime::from_msec(50));
+
/* video hardware */
SCREEN(config, m_screen, SCREEN_TYPE_RASTER);
m_screen->set_refresh_hz(60);
@@ -4959,9 +4792,12 @@ void dynax_adpcm_state::mjembase(machine_config &config)
// 13C
m_mainlatch->q_out_cb<3>().set(FUNC(dynax_adpcm_state::coincounter_0_w));
m_mainlatch->q_out_cb<4>().set(FUNC(dynax_adpcm_state::coincounter_1_w));
+ m_mainlatch->q_out_cb<5>().set(m_hopper, FUNC(hopper_device::motor_w));
config.device_remove("outlatch");
+ HOPPER(config, m_hopper, attotime::from_msec(50));
+
MCFG_VIDEO_START_OVERRIDE(dynax_adpcm_state, mjembase)
}
diff --git a/src/mame/dynax/dynax.h b/src/mame/dynax/dynax.h
index 341f1d4f6fc..17b32bb7e6b 100644
--- a/src/mame/dynax/dynax.h
+++ b/src/mame/dynax/dynax.h
@@ -270,9 +270,6 @@ protected:
void adpcm_reset_w(uint8_t data);
private:
- // input/output
- uint8_t m_hopper = 0U; // hjingi
-
// misc
int m_toggle = 0;
@@ -285,8 +282,6 @@ private:
void nanajign_palette_hi_w(offs_t offset, uint8_t data);
void nanajign_palette_update(offs_t offset);
void hjingi_lockout_w(int state);
- void hjingi_hopper_w(int state);
- uint8_t hjingi_hopper_bit();
uint8_t hjingi_keyboard_0_r();
uint8_t hjingi_keyboard_1_r();
void yarunara_input_w(offs_t offset, uint8_t data);