mirror of
https://github.com/holub/mame
synced 2025-04-23 00:39:36 +03:00
Unbreak magic10.cpp (nw)
magic10.cpp: fixed longstanding regression with Magic's 10 gameplay not behaving properly [Angelo Salese]
This commit is contained in:
parent
19d652fad9
commit
ff328ff732
@ -355,8 +355,8 @@ static ADDRESS_MAP_START( magic102_map, AS_PROGRAM, 16, magic10_state )
|
||||
AM_RANGE(0x500006, 0x500007) AM_READNOP // gives credits
|
||||
AM_RANGE(0x50001a, 0x50001b) AM_READ_PORT("IN0")
|
||||
AM_RANGE(0x50001c, 0x50001d) AM_READ_PORT("IN1")
|
||||
AM_RANGE(0x500002, 0x50001f) AM_READNOP
|
||||
AM_RANGE(0x500002, 0x50001f) AM_WRITENOP
|
||||
// AM_RANGE(0x500002, 0x50001f) AM_READNOP
|
||||
// AM_RANGE(0x500002, 0x50001f) AM_WRITENOP
|
||||
AM_RANGE(0x600000, 0x603fff) AM_RAM
|
||||
AM_RANGE(0x700000, 0x700001) AM_DEVREADWRITE8("oki", okim6295_device, read, write, 0x00ff)
|
||||
AM_RANGE(0x700080, 0x700087) AM_RAM AM_SHARE("vregs") // video registers?
|
||||
@ -498,64 +498,6 @@ static INPUT_PORTS_START( magic102 )
|
||||
PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_GAMBLE_BET )
|
||||
PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_GAMBLE_PAYOUT ) PORT_NAME("Collect")
|
||||
PORT_BIT( 0xff00, IP_ACTIVE_LOW, IPT_UNUSED )
|
||||
|
||||
/*
|
||||
credits inputs
|
||||
|
||||
PORT_START("CRED1")
|
||||
PORT_DIPNAME( 0x01, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x01, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x02, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x04, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x08, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x10, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x20, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x40, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x80, DEF_STR( On ) )
|
||||
PORT_BIT( 0xff00, IP_ACTIVE_HIGH, IPT_UNUSED )
|
||||
|
||||
PORT_START("CRED2")
|
||||
PORT_DIPNAME( 0x01, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x01, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x02, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x04, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x08, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x10, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x20, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x40, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x80, DEF_STR( On ) )
|
||||
PORT_BIT( 0xff00, IP_ACTIVE_HIGH, IPT_UNUSED )
|
||||
*/
|
||||
INPUT_PORTS_END
|
||||
|
||||
static INPUT_PORTS_START( musicsrt )
|
||||
@ -674,6 +616,7 @@ static INPUT_PORTS_START( sgsafari )
|
||||
PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_GAMBLE_PAYOUT ) PORT_NAME("Payout / Super Game")
|
||||
|
||||
PORT_START("DSW1")
|
||||
// TODO: defaults are hardwired with aforementioned startup code, is it intentional?
|
||||
PORT_BIT( 0x00ff, IP_ACTIVE_HIGH, IPT_UNUSED )
|
||||
PORT_DIPNAME( 0x0300, 0x0000, DEF_STR( Difficulty ) ) PORT_DIPLOCATION("SW1:1,2")
|
||||
PORT_DIPSETTING( 0x0300, DEF_STR( Easy ) )
|
||||
@ -748,7 +691,8 @@ MACHINE_CONFIG_START(magic10_state::magic10)
|
||||
MCFG_CPU_PROGRAM_MAP(magic10_map)
|
||||
MCFG_CPU_VBLANK_INT_DRIVER("screen", magic10_state, irq1_line_hold)
|
||||
|
||||
MCFG_NVRAM_ADD_0FILL("nvram")
|
||||
// 1FILL is required by vanilla magic10 at least (otherwise gameplay won't work properly)
|
||||
MCFG_NVRAM_ADD_1FILL("nvram")
|
||||
|
||||
MCFG_SCREEN_ADD("screen", RASTER)
|
||||
MCFG_SCREEN_REFRESH_RATE(60)
|
||||
@ -806,7 +750,7 @@ MACHINE_CONFIG_DERIVED(magic10_state::sgsafari, magic10)
|
||||
MCFG_CPU_MODIFY("maincpu")
|
||||
MCFG_CPU_PROGRAM_MAP(sgsafari_map)
|
||||
MCFG_CPU_VBLANK_INT_DRIVER("screen", magic10_state, irq2_line_hold) /* L1 interrupts */
|
||||
|
||||
|
||||
MCFG_SCREEN_MODIFY("screen")
|
||||
MCFG_SCREEN_VISIBLE_AREA(0*8, 44*8-1, 0*8, 30*8-1)
|
||||
MACHINE_CONFIG_END
|
||||
|
Loading…
Reference in New Issue
Block a user