summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author hap <happppp@users.noreply.github.com>2025-01-08 13:35:24 +0100
committer hap <happppp@users.noreply.github.com>2025-01-08 13:35:24 +0100
commit50046f5e168d7cb787df2970c67bf8c459ef5624 (patch)
treed77ae9feec80b970f9ab25e6838dcebf23b401a1
parent77bee91892ea0884b4c1953bcd9dcd99bc323e43 (diff)
undrfire: remove fake dipswitch
-rw-r--r--src/mame/konami/xexex.cpp16
-rw-r--r--src/mame/taito/undrfire.cpp13
-rw-r--r--src/mame/taito/undrfire.h2
-rw-r--r--src/mame/taito/undrfire_v.cpp8
4 files changed, 9 insertions, 30 deletions
diff --git a/src/mame/konami/xexex.cpp b/src/mame/konami/xexex.cpp
index 61ba829fcdd..12e6960e163 100644
--- a/src/mame/konami/xexex.cpp
+++ b/src/mame/konami/xexex.cpp
@@ -196,6 +196,12 @@ public:
void xexex(machine_config &config);
+protected:
+ virtual void machine_start() override ATTR_COLD;
+ virtual void machine_reset() override ATTR_COLD;
+ virtual void video_start() override ATTR_COLD;
+ virtual void device_post_load() override { parse_control2(); }
+
private:
/* memory pointers */
required_shared_ptr<uint16_t> m_workram;
@@ -242,13 +248,9 @@ private:
void sound_irq_w(uint16_t data);
void sound_bankswitch_w(uint8_t data);
- virtual void machine_start() override ATTR_COLD;
- virtual void machine_reset() override ATTR_COLD;
- virtual void video_start() override ATTR_COLD;
uint32_t screen_update_xexex(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
TIMER_CALLBACK_MEMBER(dmaend_callback);
TIMER_DEVICE_CALLBACK_MEMBER(xexex_interrupt);
- void xexex_postload();
void xexex_objdma(int limiter);
void parse_control2();
K056832_CB_MEMBER(tile_callback);
@@ -650,11 +652,6 @@ INPUT_PORTS_END
-void xexex_state::xexex_postload()
-{
- parse_control2();
-}
-
void xexex_state::machine_start()
{
m_z80bank->configure_entries(0, 8, memregion("audiocpu")->base(), 0x4000);
@@ -669,7 +666,6 @@ void xexex_state::machine_start()
save_item(NAME(m_frame));
save_item(NAME(m_cur_control2));
- machine().save().register_postload(save_prepost_delegate(FUNC(xexex_state::xexex_postload), this));
m_dmadelay_timer = timer_alloc(FUNC(xexex_state::dmaend_callback), this);
}
diff --git a/src/mame/taito/undrfire.cpp b/src/mame/taito/undrfire.cpp
index 92a9ba05059..3215d33cd38 100644
--- a/src/mame/taito/undrfire.cpp
+++ b/src/mame/taito/undrfire.cpp
@@ -244,8 +244,6 @@ void undrfire_state::shared_ram_w(offs_t offset, u16 data, u16 mem_mask)
u32 undrfire_state::undrfire_lightgun_r(offs_t offset)
{
- int x,y;
-
switch (offset)
{
/* NB we are raising the raw inputs by an arbitrary amount,
@@ -256,8 +254,8 @@ u32 undrfire_state::undrfire_lightgun_r(offs_t offset)
case 0x00: /* P1 */
case 0x01: /* P2 */
{
- x = m_in_gunx[offset & 1]->read() << 6;
- y = m_in_guny[offset & 1]->read() << 6;
+ int x = m_in_gunx[offset & 1]->read() << 6;
+ int y = m_in_guny[offset & 1]->read() << 6;
return ((x << 24) &0xff000000) | ((x << 8) &0xff0000)
| ((y << 8) &0xff00) | ((y >> 8) &0xff) ;
@@ -421,7 +419,6 @@ static INPUT_PORTS_START( undrfire )
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN )
/* Gun inputs (real range is 0-0xffff: we use standard 0-255 and shift later) */
-
PORT_START("GUNX1")
PORT_BIT( 0xff, 0x80, IPT_LIGHTGUN_X ) PORT_CROSSHAIR(X, -1.0, 0.0, 0) PORT_SENSITIVITY(20) PORT_KEYDELTA(25) PORT_REVERSE PORT_PLAYER(1)
@@ -433,11 +430,6 @@ static INPUT_PORTS_START( undrfire )
PORT_START("GUNY2")
PORT_BIT( 0xff, 0x80, IPT_LIGHTGUN_Y ) PORT_CROSSHAIR(Y, 1.0, 0.0, 0) PORT_SENSITIVITY(20) PORT_KEYDELTA(25) PORT_PLAYER(2)
-
- PORT_START("FAKE")
- PORT_DIPNAME( 0x01, 0x00, "Show gun target" ) PORT_CODE(KEYCODE_F1) PORT_TOGGLE
- PORT_DIPSETTING( 0x00, DEF_STR( No ) )
- PORT_DIPSETTING( 0x01, DEF_STR( Yes ) )
INPUT_PORTS_END
@@ -507,6 +499,7 @@ static GFXDECODE_START( gfx_undrfire )
GFXDECODE_ENTRY( "sprites", 0x0, tile16x16_layout, 0, 512 )
GFXDECODE_END
+
/***********************************************************
MACHINE DRIVERS
***********************************************************/
diff --git a/src/mame/taito/undrfire.h b/src/mame/taito/undrfire.h
index da7c9557d6d..6cac9938cd0 100644
--- a/src/mame/taito/undrfire.h
+++ b/src/mame/taito/undrfire.h
@@ -31,7 +31,6 @@ public:
m_spritemaphi(*this, "spritemaphi"),
m_in_gunx(*this, "GUNX%u", 1U),
m_in_guny(*this, "GUNY%u", 1U),
- m_io_fake(*this, "FAKE"),
m_lamp_start(*this, "P%u_lamp_start", 1U),
m_gun_recoil(*this, "P%u_gun_recoil", 1U),
m_lamp(*this, "Lamp_%u", 1U),
@@ -80,7 +79,6 @@ private:
optional_ioport_array<2> m_in_gunx;
optional_ioport_array<2> m_in_guny;
- optional_ioport m_io_fake;
output_finder<2> m_lamp_start;
output_finder<2> m_gun_recoil;
output_finder<6> m_lamp;
diff --git a/src/mame/taito/undrfire_v.cpp b/src/mame/taito/undrfire_v.cpp
index a09c8027c0e..8058bbd2bc3 100644
--- a/src/mame/taito/undrfire_v.cpp
+++ b/src/mame/taito/undrfire_v.cpp
@@ -441,14 +441,6 @@ u32 undrfire_state::screen_update_undrfire(screen_device &screen, bitmap_ind16 &
m_tc0480scp->tilemap_draw(screen, bitmap, cliprect, layer[4], 0, 0); /* TC0480SCP text layer */
- /* See if we should draw artificial gun targets */
- /* (not yet implemented...) */
-
- if (m_io_fake->read() & 0x1) /* Fake DSW */
- {
- popmessage("Gunsights on");
- }
-
/* Enable this to see rotation (?) control words */
#if 0
{