From 6a0aba5c9fc476d616580915e07c09ce9a445db6 Mon Sep 17 00:00:00 2001 From: Angelo Salese Date: Tue, 23 Sep 2014 22:45:41 +0000 Subject: [PATCH] Moved protection vectors from hachamfb to hachamf, making the latter to work properly too [Angelo Salese] --- src/mame/drivers/nmk16.c | 58 ++++++++++++++++++++-------------------- 1 file changed, 29 insertions(+), 29 deletions(-) diff --git a/src/mame/drivers/nmk16.c b/src/mame/drivers/nmk16.c index 41c70465678..419c405c0ec 100644 --- a/src/mame/drivers/nmk16.c +++ b/src/mame/drivers/nmk16.c @@ -515,12 +515,7 @@ the job to give the vectors of where the inputs are to be read & to calculate th settings,the latter is in a TIMER_DEVICE_CALLBACK to avoid sync problems. To make a long story short,this MCU is an alternative version of the same protection used by the MJ-8956 games (there are even the same kind of error codes!(i.e the number -printed on the up-left corner of the screen)... - -Note: I'm 100% sure of the Thunder Dragon vectors because I've compared it with the -bootleg sets,I'm *not* 100% sure of the Hacha Mecha Fighter vectors because I don't have -anything to compare and I don't know if for example an option should be there if you lose a -life,but the game looks pretty much hard without it. +printed on the up-left corner of the screen). ******************************************************************************************/ @@ -550,6 +545,8 @@ READ16_MEMBER(nmk16_state::mcu_shared_r) //td - hmf //008D9E - 00796e /* +(Old notes, for reference) + 007B9E: bra 7b9c 007BA0: move.w #$10, $f907a.l 007BA8: bsr 8106 @@ -614,7 +611,8 @@ f0 - player bombs (8c36) WRITE16_MEMBER(nmk16_state::hachamf_mainram_w) { COMBINE_DATA(&m_mainram[offset]); - +#define DUMMYA 0x7b9c +// 7960 switch(offset) { case 0xe058/2: PROT_INPUT(0xe058/2,0xc71f,0xe000/2,0x00080000); break; @@ -622,37 +620,37 @@ WRITE16_MEMBER(nmk16_state::hachamf_mainram_w) case 0xe51e/2: PROT_INPUT(0xe51e/2,0x0f82,0xe008/2,0x00080008); break; case 0xe6b4/2: PROT_INPUT(0xe6b4/2,0x79be,0xe00c/2,0x0008000a); break; case 0xe10e/2: PROT_JSR(0xe10e,0x8007,0x870a);//870a not 9d66 - PROT_JSR(0xe10e,0x8000,0xd9c6); break; - case 0xe11e/2: PROT_JSR(0xe11e,0x8038,0x972a);//972a - PROT_JSR(0xe11e,0x8031,0xd1f8); break; + PROT_JSR(0xe10e,0x8000,0xd9c6); break; + case 0xe11e/2: PROT_JSR(0xe11e,0x8038,DUMMYA);//972a - (unused) + PROT_JSR(0xe11e,0x8031,0x7a54); break; case 0xe12e/2: PROT_JSR(0xe12e,0x8019,0x9642);//OK-9642 - PROT_JSR(0xe12e,0x8022,0xda06); break; + PROT_JSR(0xe12e,0x8022,0xda06); break; case 0xe13e/2: PROT_JSR(0xe13e,0x802a,0x9d66);//9d66 not 9400 - OK - PROT_JSR(0xe13e,0x8013,0x81aa); break; + PROT_JSR(0xe13e,0x8013,0x81aa); break; case 0xe14e/2: PROT_JSR(0xe14e,0x800b,0xb3f2);//b3f2 - OK - PROT_JSR(0xe14e,0x8004,0x8994); break; + PROT_JSR(0xe14e,0x8004,0x8994); break; case 0xe15e/2: PROT_JSR(0xe15e,0x803c,0xb59e);//b59e - OK - PROT_JSR(0xe15e,0x8035,0x8d0c); break; + PROT_JSR(0xe15e,0x8035,0x8c36); break; case 0xe16e/2: PROT_JSR(0xe16e,0x801d,0x9ac2);//9ac2 - OK - PROT_JSR(0xe16e,0x8026,0x8c36); break; + PROT_JSR(0xe16e,0x8026,0x8d0c); break; case 0xe17e/2: PROT_JSR(0xe17e,0x802e,0xc366);//c366 - OK - PROT_JSR(0xe17e,0x8017,0x870a); break; - case 0xe18e/2: PROT_JSR(0xe18e,0x8004,0xd620); //unused - PROT_JSR(0xe18e,0x8008,0x972a); break; //unused + PROT_JSR(0xe17e,0x8017,0x870a); break; + case 0xe18e/2: PROT_JSR(0xe18e,0x8004,DUMMYA); //unused + PROT_JSR(0xe18e,0x8008,DUMMYA); break; //unused case 0xe19e/2: PROT_JSR(0xe19e,0x8030,0xd9c6);//OK-d9c6 - PROT_JSR(0xe19e,0x8039,0x9642); break; - case 0xe1ae/2: PROT_JSR(0xe1ae,0x8011,0xd1f8);//d1f8 not c67e - PROT_JSR(0xe1ae,0x802a,0x9d66); break; + PROT_JSR(0xe19e,0x8039,0x9642); break; + case 0xe1ae/2: PROT_JSR(0xe1ae,0x8011,0x7a54);//d1f8 not c67e + PROT_JSR(0xe1ae,0x802a,0x9d66); break; case 0xe1be/2: PROT_JSR(0xe1be,0x8022,0xda06);//da06 - PROT_JSR(0xe1be,0x801b,0xb3f2); break; + PROT_JSR(0xe1be,0x801b,0xb3f2); break; case 0xe1ce/2: PROT_JSR(0xe1ce,0x8003,0x81aa);//81aa - PROT_JSR(0xe1ce,0x800c,0xb59e); break; + PROT_JSR(0xe1ce,0x800c,0xb59e); break; case 0xe1de/2: PROT_JSR(0xe1de,0x8034,0x8994);//8994 - OK - PROT_JSR(0xe1de,0x803d,0x9ac2); break; - case 0xe1ee/2: PROT_JSR(0xe1ee,0x8015,0x8d0c);//8d0c not 82f6 - PROT_JSR(0xe1ee,0x802e,0xc366); break; - case 0xe1fe/2: PROT_JSR(0xe1fe,0x8026,0x8c36);//8c36 - PROT_JSR(0xe1fe,0x8016,0xd620); break; //unused + PROT_JSR(0xe1de,0x803d,0x9ac2); break; + case 0xe1ee/2: PROT_JSR(0xe1ee,0x8015,0x8c36);//8d0c not 82f6 + PROT_JSR(0xe1ee,0x802e,0xc366); break; + case 0xe1fe/2: PROT_JSR(0xe1fe,0x8026,0x8d0c);//8c36 + PROT_JSR(0xe1fe,0x8016,DUMMYA); break; //unused case 0xef00/2: if(m_mainram[0xef00/2] == 0x60fe) { @@ -664,8 +662,10 @@ WRITE16_MEMBER(nmk16_state::hachamf_mainram_w) } break; } +#undef DUMMYA } + static ADDRESS_MAP_START( hachamf_map, AS_PROGRAM, 16, nmk16_state ) AM_RANGE(0x000000, 0x03ffff) AM_ROM /* I/O Region */ @@ -7725,7 +7725,7 @@ GAME( 1992, strahla, strahl, strahl, strahl, driver_device, 0, ROT GAME( 1991, tdragon, 0, tdragon, tdragon, driver_device, 0, ROT270, "NMK (Tecmo license)","Thunder Dragon (8th Jan. 1992, unprotected)", 0 ) GAME( 1991, tdragon1, tdragon, tdragon_prot, tdragon_prot, nmk16_state, tdragon_prot, ROT270, "NMK (Tecmo license)","Thunder Dragon (4th Jun. 1991, protected)", GAME_UNEMULATED_PROTECTION | GAME_NO_SOUND ) -GAME( 1991, hachamf, 0, hachamf_prot, hachamf_prot, nmk16_state, hachamf_prot, ROT0, "NMK", "Hacha Mecha Fighter (19th Sep. 1991, protected)", GAME_UNEMULATED_PROTECTION | GAME_NO_SOUND | GAME_NOT_WORKING ) // lots of things wrong due to protection +GAME( 1991, hachamf, 0, hachamf_prot, hachamf_prot, nmk16_state, hachamf_prot, ROT0, "NMK", "Hacha Mecha Fighter (19th Sep. 1991, protected)", GAME_UNEMULATED_PROTECTION | GAME_NO_SOUND ) // lots of things wrong due to protection GAME( 1991, hachamfb, hachamf,hachamf, hachamfb, driver_device, 0, ROT0, "bootleg", "Hacha Mecha Fighter (19th Sep. 1991, unprotected, bootleg Thunder Dragon conversion)", 0 ) // appears to be a Thunder Dragon conversion, could be bootleg? GAME( 1992, macross, 0, macross, macross, nmk16_state, nmk, ROT270, "Banpresto", "Super Spacefortress Macross / Chou-Jikuu Yousai Macross", 0 )