diff options
author | AJR <ajrhacker@users.noreply.github.com> | 2017-01-18 22:25:52 -0500 |
---|---|---|
committer | AJR <ajrhacker@users.noreply.github.com> | 2017-01-18 22:25:52 -0500 |
commit | ce9e5c8f3474697ecd7e66da457972f9afee3642 (patch) | |
tree | e0320554ce9eb19ba055385c1825eb46cba56d7c | |
parent | 14ce81377d690c84ec6ec7b9f73e8d8d7f96c2f3 (diff) |
bagmanf: Fix inputs and shuffle PROMs for better colors (game still tends to crash)
-rw-r--r-- | src/mame/drivers/cclimber.cpp | 46 | ||||
-rw-r--r-- | src/mame/includes/cclimber.h | 1 |
2 files changed, 18 insertions, 29 deletions
diff --git a/src/mame/drivers/cclimber.cpp b/src/mame/drivers/cclimber.cpp index 79d17c18954..9783e78dad8 100644 --- a/src/mame/drivers/cclimber.cpp +++ b/src/mame/drivers/cclimber.cpp @@ -308,6 +308,13 @@ WRITE8_MEMBER(cclimber_state::nmi_mask_w) } +READ8_MEMBER(cclimber_state::bagmanf_a000_r) +{ + // Should this actually use the same PAL16R6 as the parent set? + return 0x3f; +} + + /* Note that River Patrol reads/writes to a000-a4f0. This is a bug in the code. The instruction at 0x0593 should say LD DE,$8000 */ @@ -436,22 +443,23 @@ ADDRESS_MAP_END static ADDRESS_MAP_START( bagmanf_map, AS_PROGRAM, 8, cclimber_state ) AM_RANGE(0x0000, 0x5fff) AM_ROM AM_RANGE(0x6000, 0x6bff) AM_RAM /* Crazy Kong only */ - AM_RANGE(0x8000, 0x83ff) AM_RAM - AM_RANGE(0x8800, 0x88ff) AM_RAM AM_SHARE("bigspriteram") + AM_RANGE(0x8000, 0x8000) AM_READ_PORT("P1") + AM_RANGE(0x8800, 0x8800) AM_READ_PORT("P2") + AM_RANGE(0x8800, 0x88ff) AM_RAM AM_SHARE("bigspriteram") // wrong AM_RANGE(0x8900, 0x8bff) AM_RAM /* not used, but initialized */ AM_RANGE(0x9000, 0x93ff) AM_RAM AM_SHARE("videoram") AM_RANGE(0xffe0, 0xffff) AM_RAM AM_SHARE("column_scroll") // wrong, is this area even connected? + AM_RANGE(0x9800, 0x9800) AM_READ_PORT("SYSTEM") AM_RANGE(0x9800, 0x981f) AM_RAM AM_SHARE("spriteram") AM_RANGE(0x98dc, 0x98df) AM_RAM AM_SHARE("bigspritectrl") // wrong AM_RANGE(0x9800, 0x9bff) AM_RAM AM_SHARE("colorram") AM_RANGE(0x9c00, 0x9fff) AM_RAM /* not used, but initialized */ - AM_RANGE(0xa000, 0xa000) AM_READ_PORT("P1") AM_WRITE(nmi_mask_w) + AM_RANGE(0xa000, 0xa000) AM_READ(bagmanf_a000_r) AM_WRITE(nmi_mask_w) AM_RANGE(0xa001, 0xa002) AM_WRITEONLY AM_SHARE("flip_screen") AM_RANGE(0xa004, 0xa004) AM_DEVWRITE("cclimber_audio", cclimber_audio_device, sample_trigger_w) - AM_RANGE(0xa800, 0xa800) AM_READ_PORT("P2") AM_DEVWRITE("cclimber_audio", cclimber_audio_device, sample_rate_w) AM_RANGE(0xb000, 0xb000) AM_READ_PORT("DSW") AM_DEVWRITE("cclimber_audio", cclimber_audio_device, sample_volume_w) - AM_RANGE(0xb800, 0xb800) AM_READ_PORT("SYSTEM") + AM_RANGE(0xb800, 0xb800) AM_READNOP ADDRESS_MAP_END static ADDRESS_MAP_START( toprollr_decrypted_opcodes_map, AS_DECRYPTED_OPCODES, 8, cclimber_state ) @@ -613,27 +621,9 @@ static INPUT_PORTS_START( ckong ) INPUT_PORTS_END static INPUT_PORTS_START( bagmanf ) - PORT_START("P1") - PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 ) - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 ) - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_START1 ) - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY - PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY - PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY - PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_BUTTON1 ) - - PORT_START("P2") - PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN3 ) - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN4 ) - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_START2 ) - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY PORT_COCKTAIL - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_COCKTAIL - PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_COCKTAIL - PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY PORT_COCKTAIL - PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_COCKTAIL + PORT_INCLUDE( ckong ) - PORT_START("DSW") + PORT_MODIFY("DSW") PORT_DIPNAME( 0x03, 0x02, DEF_STR( Lives ) ) PORT_DIPLOCATION("SW1:1,2") PORT_DIPSETTING( 0x03, "2" ) PORT_DIPSETTING( 0x02, "3" ) @@ -656,8 +646,6 @@ static INPUT_PORTS_START( bagmanf ) PORT_DIPNAME( 0x80, 0x80, DEF_STR( Cabinet ) ) /* Cabinet type set through edge connector, not dip switch (verified on real pcb) */ PORT_DIPSETTING( 0x80, DEF_STR( Upright ) ) PORT_DIPSETTING( 0x00, DEF_STR( Cocktail ) ) - - PORT_START("SYSTEM") INPUT_PORTS_END /* Similar to normal Crazy Kong except for the lives per game */ @@ -2297,8 +2285,8 @@ ROM_START( bagmanf ) ROM_REGION( 0x2000, "gfx2", ROMREGION_ERASE00 ) ROM_REGION( 0x0060, "proms", 0 ) - ROM_LOAD( "v6", 0x0000, 0x0020, CRC(b3fc1505) SHA1(5b94adde0428a26b815c7eb9b3f3716470d349c7) ) - ROM_LOAD( "u6", 0x0020, 0x0020, CRC(26aada9e) SHA1(f59645e606ea4f0dd0fc4ea47dd03f526c534941) ) + ROM_LOAD( "v6", 0x0020, 0x0020, CRC(b3fc1505) SHA1(5b94adde0428a26b815c7eb9b3f3716470d349c7) ) + ROM_LOAD( "u6", 0x0000, 0x0020, CRC(26aada9e) SHA1(f59645e606ea4f0dd0fc4ea47dd03f526c534941) ) ROM_LOAD( "t6", 0x0040, 0x0020, CRC(676b3166) SHA1(29b9434cd34d43ea5664e436e2a24b54f8d88aac) ) /* as well as one of the program roms, the daughterboard contains the speech hardware + roms */ diff --git a/src/mame/includes/cclimber.h b/src/mame/includes/cclimber.h index 30cf4b45d85..2b1ec8a32b6 100644 --- a/src/mame/includes/cclimber.h +++ b/src/mame/includes/cclimber.h @@ -63,6 +63,7 @@ public: DECLARE_READ8_MEMBER(yamato_p1_r); DECLARE_WRITE8_MEMBER(toprollr_rombank_w); DECLARE_WRITE8_MEMBER(nmi_mask_w); + DECLARE_READ8_MEMBER(bagmanf_a000_r); DECLARE_WRITE8_MEMBER(cclimber_colorram_w); DECLARE_WRITE8_MEMBER(cannonb_flip_screen_w); |