From 6cc80f63c0c9eff1bfd94b5890c6ab8ac620cb02 Mon Sep 17 00:00:00 2001 From: Ivan Vangelista Date: Thu, 28 Dec 2017 19:30:31 +0100 Subject: [PATCH] new working clones ------------------------------ "Super World Court (World, bootleg)" [hammy, The Dumping Union] --- src/mame/drivers/namcona1.cpp | 44 +++++++++- src/mame/includes/namcona1.h | 152 ++++++++++++++++++---------------- src/mame/mame.lst | 3 +- 3 files changed, 124 insertions(+), 75 deletions(-) diff --git a/src/mame/drivers/namcona1.cpp b/src/mame/drivers/namcona1.cpp index 617d6f880f3..52e0aa16ebb 100644 --- a/src/mame/drivers/namcona1.cpp +++ b/src/mame/drivers/namcona1.cpp @@ -284,6 +284,11 @@ READ16_MEMBER(namcona1_state::custom_key_r) if( offset==3 ) return m_count; break; + case NAMCO_SWCOURTB: // TODO: this hasn't got a real keycus, see comments above ROM definitions + if( offset==1 ) return 0x8061; + if( offset==2 ) return m_count; + break; + default: return 0; } @@ -689,8 +694,6 @@ WRITE8_MEMBER(namcona1_state::port8_w) void namcona1_state::machine_start() { - m_prgrom = (uint16_t *)memregion("maincpu")->base(); - m_maskrom = (uint16_t *)memregion("maskrom")->base(); m_mEnableInterrupts = 0; m_c140->set_base(m_workram); @@ -1006,6 +1009,7 @@ DRIVER_INIT_MEMBER(namcona1_state,knckhead) { m_gametype = NAMCO_KNCKHEAD; } DRIVER_INIT_MEMBER(namcona1_state,numanath) { m_gametype = NAMCO_NUMANATH; } DRIVER_INIT_MEMBER(namcona1_state,quiztou) { m_gametype = NAMCO_QUIZTOU; } DRIVER_INIT_MEMBER(namcona1_state,swcourt) { m_gametype = NAMCO_SWCOURT; } +DRIVER_INIT_MEMBER(namcona1_state,swcourtb) { m_gametype = NAMCO_SWCOURTB; } DRIVER_INIT_MEMBER(namcona1_state,tinklpit) { m_gametype = NAMCO_TINKLPIT; save_item(NAME(m_keyval)); } DRIVER_INIT_MEMBER(namcona1_state,xday2) { m_gametype = NAMCO_XDAY2; } @@ -1155,6 +1159,41 @@ ROM_START( swcourtj ) ROM_LOAD16_BYTE( "sc1-ma1u.bin", 0x200000, 0x100000, CRC(252dc4b7) SHA1(f1be6bd045495c7a0ecd97f01d1dc8ad341fecfd) ) ROM_END +/* +This bootleg is running on the older type rom board (Cosmo Gang etc). Super World Court normally runs on the newer type 'B' board with extra chip at 6J. +It has a small pcb replacement keycus with a 74hc4060 , LS04 and 2 chips with the ID scratched (possibly PAL chips). +Program ROMs are almost identical. They hacked the keycus routine and the copyright year (from 1992 to 1994): +sc2-ep0l.4c [2/2] 0l.0l [2/2] IDENTICAL +sc2-ep0u.4f [2/2] 0u.0u [2/2] IDENTICAL +sc2-ep0u.4f [1/2] 0u.0u [1/2] 99.997711% +sc2-ep0l.4c [1/2] 0l.0l [1/2] 99.997330% + +GFX ROMs are 27c040's double stacked with flying wires to the PAL board. They are the same as the 801 dumps, chopped in half. Pin 22 of OLH and OUH go to C pad on custom board. +Pin 22 of 1LH and 1UH go to B pad on custom board. All Lower pin '22's are tied high. + +Believed to be a Playmark bootleg because the PCB has the typical slightly blue tinge to the solder mask and the same font. +*/ + +ROM_START( swcourtb ) + ROM_REGION( 0x200000, "maincpu", 0 ) + ROM_LOAD16_BYTE( "0l.0l", 0x000001, 0x080000, CRC(669c9b10) SHA1(8c40f5331f899c458699ab856c5900c540e8471e) ) /* 0xc00000 */ + ROM_LOAD16_BYTE( "0u.0u", 0x000000, 0x080000, CRC(742f3da1) SHA1(b3df6afd9849af8dd1643991ac70c93bf9f8fcb2) ) + ROM_LOAD16_BYTE( "1l.1l", 0x100001, 0x080000, CRC(fb45cf5f) SHA1(6ded351daa9b39d0b8149100caefc4fa0c598e79) ) + ROM_LOAD16_BYTE( "1u.1u", 0x100000, 0x080000, CRC(1ce07b15) SHA1(b1b28cc480301c9ad642597c7cdd8e9cdec996a6) ) + + ROM_REGION16_BE( 0x800000, "maskrom", 0 ) + ROM_LOAD16_BYTE( "OLL.ol.2c", 0x000001, 0x80000, CRC(df0920ef) SHA1(c8d583d8967b3eb86ecfbabb906cc82d2a05d139) ) /* 0x400000 */ + ROM_LOAD16_BYTE( "OUL.ou.2f", 0x000000, 0x80000, CRC(844c6a1c) SHA1(ad186c8209688e1bc567fb5015d9d970099139bb) ) + ROM_LOAD16_BYTE( "OLH.ol.2c", 0x100001, 0x80000, CRC(0a21abea) SHA1(cf8f8ff37abdc398cbabf0f0a77aa15ccbc37257) ) + ROM_LOAD16_BYTE( "OUH.ou.2f", 0x100000, 0x80000, CRC(6b7c93f9) SHA1(2f823a2a2d8ca5cdb679dd1c1ca66803d47c6b40) ) + ROM_LOAD16_BYTE( "1LL.1l.3c", 0x200001, 0x80000, CRC(f7e30277) SHA1(65db7e07919c36011fa930976d43dd2d4fb7b8e5) ) + ROM_LOAD16_BYTE( "1UL.1u.3f", 0x200000, 0x80000, CRC(5f03c51a) SHA1(75cd042db716b6cb56f812af9ba6dca0efae8cac) ) + ROM_LOAD16_BYTE( "1LH.1l.3c", 0x300001, 0x80000, CRC(6531236e) SHA1(9270a2235b6a713d8c4e791da789d8428b461a1a) ) + ROM_LOAD16_BYTE( "1UH.1u.3f", 0x300000, 0x80000, CRC(acae6746) SHA1(fb06b544e187c71b27318c249f1e52ff86aab00c) ) + + //PALs? See comments above +ROM_END + ROM_START( tinklpit ) ROM_REGION( 0x200000, "maincpu", 0 ) ROM_LOAD16_BYTE( "tk1-ep0l.bin", 0x000001, 0x080000, CRC(fdccae42) SHA1(398384482ccb3eb08bfb9db495513272a5188d92) ) /* 0xc00000 */ @@ -1324,6 +1363,7 @@ GAME( 1992, fghtatck, 0, namcona1, namcona1_joy, namcona1_state, fa, GAME( 1992, fa, fghtatck, namcona1, namcona1_joy, namcona1_state, fa, ROT90,"Namco", "F/A (Japan)", MACHINE_SUPPORTS_SAVE ) GAME( 1992, swcourt, 0, namcona1w, namcona1_joy, namcona1_state, swcourt, ROT0, "Namco", "Super World Court (World)", MACHINE_SUPPORTS_SAVE ) GAME( 1992, swcourtj, swcourt, namcona1w, namcona1_joy, namcona1_state, swcourt, ROT0, "Namco", "Super World Court (Japan)", MACHINE_SUPPORTS_SAVE ) +GAME( 1994, swcourtb, swcourt, namcona1w, namcona1_joy, namcona1_state, swcourtb, ROT0, "bootleg (Playmark?)", "Super World Court (World, bootleg)", MACHINE_SUPPORTS_SAVE ) GAME( 1993, emeraldaj, emeralda, namcona1w, namcona1_joy, namcona1_state, emeraldj, ROT0, "Namco", "Emeraldia (Japan Version B)", MACHINE_SUPPORTS_SAVE ) /* Parent is below on NA-2 Hardware */ GAME( 1993, emeraldaja, emeralda, namcona1w, namcona1_joy, namcona1_state, emeraldj, ROT0, "Namco", "Emeraldia (Japan)", MACHINE_SUPPORTS_SAVE ) /* Parent is below on NA-2 Hardware */ GAME( 1993, tinklpit, 0, namcona1w, namcona1_joy, namcona1_state, tinklpit, ROT0, "Namco", "Tinkle Pit (Japan)", MACHINE_SUPPORTS_SAVE ) diff --git a/src/mame/includes/namcona1.h b/src/mame/includes/namcona1.h index d949d7e424d..d8558fe3fcd 100644 --- a/src/mame/includes/namcona1.h +++ b/src/mame/includes/namcona1.h @@ -11,79 +11,31 @@ #include "sound/c140.h" #include "screen.h" -enum -{ - NAMCO_CGANGPZL, - NAMCO_EMERALDA, - NAMCO_KNCKHEAD, - NAMCO_BKRTMAQ, - NAMCO_EXBANIA, - NAMCO_QUIZTOU, - NAMCO_SWCOURT, - NAMCO_TINKLPIT, - NAMCO_NUMANATH, - NAMCO_FA, - NAMCO_XDAY2 -}; - class namcona1_state : public driver_device { public: namcona1_state(const machine_config &mconfig, device_type type, const char *tag) : driver_device(mconfig, type, tag), - m_maincpu(*this,"maincpu"), - m_mcu(*this,"mcu"), + m_maincpu(*this, "maincpu"), + m_mcu(*this, "mcu"), m_gfxdecode(*this, "gfxdecode"), m_screen(*this, "screen"), m_palette(*this, "palette"), m_c140(*this, "c140"), m_muxed_inputs(*this, { { "P4", "DSW", "P1", "P2" } }), m_io_p3(*this, "P3"), - m_workram(*this,"workram"), - m_vreg(*this,"vreg"), + m_workram(*this, "workram"), + m_vreg(*this, "vreg"), m_paletteram(*this, "paletteram"), m_cgram(*this, "cgram"), - m_videoram(*this,"videoram"), - m_scroll(*this,"scroll"), - m_spriteram(*this,"spriteram") + m_videoram(*this, "videoram"), + m_scroll(*this, "scroll"), + m_spriteram(*this, "spriteram"), + m_prgrom(*this, "maincpu"), + m_maskrom(*this, "maskrom") { } - required_device m_maincpu; - required_device m_mcu; - required_device m_gfxdecode; - required_device m_screen; - required_device m_palette; - required_device m_c140; - - required_ioport_array<4> m_muxed_inputs; - required_ioport m_io_p3; - - required_shared_ptr m_workram; - required_shared_ptr m_vreg; - required_shared_ptr m_paletteram; - required_shared_ptr m_cgram; - required_shared_ptr m_videoram; - required_shared_ptr m_scroll; - required_shared_ptr m_spriteram; - - // this has to be uint8_t to be in the right byte order for the tilemap system - std::vector m_shaperam; - - uint16_t *m_prgrom; - uint16_t *m_maskrom; - int m_mEnableInterrupts; - int m_gametype; - uint16_t m_count; - uint32_t m_keyval; - uint16_t m_mcu_mailbox[8]; - uint8_t m_mcu_port4; - uint8_t m_mcu_port5; - uint8_t m_mcu_port6; - uint8_t m_mcu_port8; - tilemap_t *m_bg_tilemap[4+1]; - int m_palette_is_dirty; - DECLARE_READ16_MEMBER(custom_key_r); DECLARE_WRITE16_MEMBER(custom_key_w); DECLARE_WRITE16_MEMBER(vreg_w); @@ -103,19 +55,10 @@ public: DECLARE_READ8_MEMBER(port8_r); DECLARE_WRITE8_MEMBER(port8_w); DECLARE_READ8_MEMBER(portana_r); - void simulate_mcu(); - void write_version_info(); - int transfer_dword(uint32_t dest, uint32_t source); - void blit(); - void UpdatePalette(int offset); DECLARE_WRITE16_MEMBER(videoram_w); DECLARE_WRITE16_MEMBER(paletteram_w); DECLARE_READ16_MEMBER(gfxram_r); DECLARE_WRITE16_MEMBER(gfxram_w); - void pdraw_tile( screen_device &screen, bitmap_ind16 &dest_bmp, const rectangle &clip, uint32_t code, int color, - int sx, int sy, int flipx, int flipy, int priority, int bShadow, int bOpaque, int gfx_region ); - void draw_sprites(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); - void draw_background(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect, int which, int primask ); DECLARE_READ16_MEMBER(snd_r); DECLARE_WRITE16_MEMBER(snd_w); @@ -131,21 +74,86 @@ public: DECLARE_DRIVER_INIT(xday2); DECLARE_DRIVER_INIT(exbania); DECLARE_DRIVER_INIT(emeraldj); + DECLARE_DRIVER_INIT(swcourtb); + + uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); + + TIMER_DEVICE_CALLBACK_MEMBER(interrupt); + +protected: virtual void machine_start() override; virtual void machine_reset() override; virtual void video_start() override; +private: + enum + { + NAMCO_CGANGPZL, + NAMCO_EMERALDA, + NAMCO_KNCKHEAD, + NAMCO_BKRTMAQ, + NAMCO_EXBANIA, + NAMCO_QUIZTOU, + NAMCO_SWCOURT, + NAMCO_TINKLPIT, + NAMCO_NUMANATH, + NAMCO_FA, + NAMCO_XDAY2, + NAMCO_SWCOURTB + }; + + required_device m_maincpu; + required_device m_mcu; + required_device m_gfxdecode; + required_device m_screen; + required_device m_palette; + required_device m_c140; + + required_ioport_array<4> m_muxed_inputs; + required_ioport m_io_p3; + + required_shared_ptr m_workram; + required_shared_ptr m_vreg; + required_shared_ptr m_paletteram; + required_shared_ptr m_cgram; + required_shared_ptr m_videoram; + required_shared_ptr m_scroll; + required_shared_ptr m_spriteram; + + required_region_ptr m_prgrom; + required_region_ptr m_maskrom; + + // this has to be uint8_t to be in the right byte order for the tilemap system + std::vector m_shaperam; + + int m_mEnableInterrupts; + int m_gametype; + uint16_t m_count; + uint32_t m_keyval; + uint16_t m_mcu_mailbox[8]; + uint8_t m_mcu_port4; + uint8_t m_mcu_port5; + uint8_t m_mcu_port6; + uint8_t m_mcu_port8; + tilemap_t *m_bg_tilemap[4+1]; + int m_palette_is_dirty; + + void simulate_mcu(); + void write_version_info(); + int transfer_dword(uint32_t dest, uint32_t source); + + void blit(); + void UpdatePalette(int offset); + void pdraw_tile( screen_device &screen, bitmap_ind16 &dest_bmp, const rectangle &clip, uint32_t code, int color, + int sx, int sy, int flipx, int flipy, int priority, int bShadow, int bOpaque, int gfx_region ); + void draw_sprites(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); + void draw_background(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect, int which, int primask ); + void tilemap_get_info(tile_data &tileinfo, int tile_index, const uint16_t *tilemap_videoram, bool use_4bpp_gfx); TILE_GET_INFO_MEMBER(tilemap_get_info0); TILE_GET_INFO_MEMBER(tilemap_get_info1); TILE_GET_INFO_MEMBER(tilemap_get_info2); TILE_GET_INFO_MEMBER(tilemap_get_info3); TILE_GET_INFO_MEMBER(roz_get_info); - uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); - - TIMER_DEVICE_CALLBACK_MEMBER(interrupt); void postload(); - -private: - void tilemap_get_info(tile_data &tileinfo, int tile_index, const uint16_t *tilemap_videoram, bool use_4bpp_gfx); }; diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 9b941f827ad..4a9bf1e1ace 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -28553,7 +28553,8 @@ knckheadjp // (c) 1992 (Japan) numanath // (c) 1993 (World) numanathj // (c) 1993 (Japan) quiztou // (c) 1993 (Japan) -swcourt // (c) 1992 (Japan) +swcourt // (c) 1992 (World) +swcourtb // bootleg (Playmark?) swcourtj // (c) 1992 (Japan) tinklpit // (c) 1993 (Japan) xday2 // (c) 1995 (Japan)