From 55c1c18e19125ec29668bcc6ac5ef585dc7e7eff Mon Sep 17 00:00:00 2001 From: hap Date: Sat, 22 Jul 2023 23:32:11 +0200 Subject: gameplan: possible fix for piratetr lockup --- src/mame/gameplan/gameplan.cpp | 22 +++++++++++++++++++++- src/mame/gameplan/gameplan.h | 2 ++ 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/src/mame/gameplan/gameplan.cpp b/src/mame/gameplan/gameplan.cpp index a59c326d6a9..70fbe0a85f3 100644 --- a/src/mame/gameplan/gameplan.cpp +++ b/src/mame/gameplan/gameplan.cpp @@ -64,6 +64,10 @@ Notes: Megattack Pot Of Gold (Leprechaun) +- Leprechaun and Pirate Treasure were made for the Moppet Video arcade series + (Enter-Tech arcade cabs aimed at younger children). That's why the games are + so easy. + TODO: - The board has, instead of a watchdog, a timed reset that has to be disabled @@ -71,6 +75,10 @@ TODO: to that pin in the log. Missing support in machine/6522via.cpp? - Investigate and document the 8910 dip switches - Fix the input ports of Kaos +- Some of the games do unmapped reads all over the place, probably just bad + programming. One of these is piratetr, and it will lock up eventually when + reading from VIA1. It's possible to fix with a simple wire mod/pcb cut trace, + like done with piratetr_main_map. Let's assume they did something like that. ****************************************************************************/ @@ -349,6 +357,12 @@ void gameplan_state::gameplan_main_map(address_map &map) map(0x8000, 0xffff).rom(); } +void gameplan_state::piratetr_main_map(address_map &map) +{ + gameplan_main_map(map); + map(0x2010, 0x201f).mirror(0x07e0).unmaprw(); // A4, see TODO +} + /************************************* @@ -1174,6 +1188,12 @@ void gameplan_state::leprechn(machine_config &config) m_via[0]->writepb_handler().set(FUNC(gameplan_state::video_command_w)).rshift(3); } +void gameplan_state::piratetr(machine_config &config) +{ + leprechn(config); + m_maincpu->set_addrmap(AS_PROGRAM, &gameplan_state::piratetr_main_map); +} + /************************************* @@ -1336,4 +1356,4 @@ GAME( 1981, kaos, 0, gameplan, kaos, gameplan_state, empty_init GAME( 1982, leprechn, 0, leprechn, leprechn, gameplan_state, empty_init, ROT0, "Pacific Polytechnical Corp.", "Leprechaun (set 1)", MACHINE_SUPPORTS_SAVE ) GAME( 1982, leprechna, leprechn, leprechn, leprechna, gameplan_state, empty_init, ROT0, "Pacific Polytechnical Corp. (Tong Electronic license)", "Leprechaun (set 2)", MACHINE_SUPPORTS_SAVE ) GAME( 1982, potogold, leprechn, leprechn, leprechn, gameplan_state, empty_init, ROT0, "Pacific Polytechnical Corp. (Game Plan license)", "Pot of Gold", MACHINE_SUPPORTS_SAVE ) -GAME( 1982, piratetr, 0, leprechn, piratetr, gameplan_state, empty_init, ROT0, "Pacific Polytechnical Corp. (Tong Electronic license)", "Pirate Treasure", MACHINE_SUPPORTS_SAVE ) +GAME( 1982, piratetr, 0, piratetr, piratetr, gameplan_state, empty_init, ROT0, "Pacific Polytechnical Corp. (Tong Electronic license)", "Pirate Treasure", MACHINE_SUPPORTS_SAVE ) diff --git a/src/mame/gameplan/gameplan.h b/src/mame/gameplan/gameplan.h index f465ce8a4bb..bd60664d9e3 100644 --- a/src/mame/gameplan/gameplan.h +++ b/src/mame/gameplan/gameplan.h @@ -35,6 +35,7 @@ public: void gameplan(machine_config &config); void gameplan_video(machine_config &config); void leprechn(machine_config &config); + void piratetr(machine_config &config); protected: virtual void machine_start() override; @@ -91,4 +92,5 @@ private: void gameplan_main_map(address_map &map); void gameplan_audio_map(address_map &map); void leprechn_audio_map(address_map &map); + void piratetr_main_map(address_map &map); }; -- cgit v1.2.3