gstriker.cpp: fixed tournament logic for Tecmo World Cup '94 [Angelo Salese]

This commit is contained in:
angelosa 2017-08-29 13:07:29 +02:00
parent d3ce43f6a8
commit 94d4301f5e
2 changed files with 8 additions and 9 deletions

View File

@ -868,7 +868,7 @@ WRITE8_MEMBER(gstriker_state::twcup94_prot_reg_w)
// In "continue" screen // In "continue" screen
// if( w@FFE078 & 80) 75 // if( w@FFE078 & 80) 75
// *** after 75 beq // *** after 75 beq
case 0x75: PC(NULL_SUB); break; case 0x75: PC(0x005098); break; // match adder, and check if limit is reached for ending
// unreachable code at end of attract loop 6a->79->6f // unreachable code at end of attract loop 6a->79->6f
case 0x6a: PC(NULL_SUB); break; case 0x6a: PC(NULL_SUB); break;
@ -876,7 +876,7 @@ WRITE8_MEMBER(gstriker_state::twcup94_prot_reg_w)
case 0x6f: PC(NULL_SUB); break; case 0x6f: PC(NULL_SUB); break;
default: default:
logerror("Unknown MCU CMD %04x\n",m_mcu_data); logerror("Unknown MCU CMD %04x\n",mcu_data);
PC(NULL_SUB); PC(NULL_SUB);
break; break;
@ -886,6 +886,7 @@ WRITE8_MEMBER(gstriker_state::twcup94_prot_reg_w)
// same as above but with +0x10 displacement offsets // same as above but with +0x10 displacement offsets
case TECMO_WCUP94A_MCU: case TECMO_WCUP94A_MCU:
switch (mcu_data) switch (mcu_data)
{ {
#define NULL_SUB 0x0000829E #define NULL_SUB 0x0000829E
@ -898,13 +899,15 @@ WRITE8_MEMBER(gstriker_state::twcup94_prot_reg_w)
case 0x62: PC(NULL_SUB); break; // after lose shootout, continue ??? case 0x62: PC(NULL_SUB); break; // after lose shootout, continue ???
case 0x72: PC(0x000040AE); break; // game over case 0x72: PC(0x000040AE); break; // game over
case 0x75: PC(0x005098); break; // match adder, and check if limit is reached for ending
// attract mode // attract mode
case 0x6e: PC(0x00010E38); break; // loop case 0x6e: PC(0x00010E38); break; // loop
case 0x6b: PC(0x00010EFC); break; // attract even case 0x6b: PC(0x00010EFC); break; // attract even
case 0x69: PC(0x0001121A); break; // attract odd case 0x69: PC(0x0001121A); break; // attract odd
default: default:
logerror("Unknown MCU CMD %04x\n",m_mcu_data); logerror("Unknown MCU CMD %04x\n",mcu_data);
PC(NULL_SUB); PC(NULL_SUB);
break; break;
@ -927,7 +930,7 @@ WRITE8_MEMBER(gstriker_state::twcup94_prot_reg_w)
case 0x79: PC(0x0006072E); break; // after select, start match case 0x79: PC(0x0006072E); break; // after select, start match
default: default:
logerror("Unknown MCU CMD %04x\n",m_mcu_data); logerror("Unknown MCU CMD %04x\n",mcu_data);
PC(0x00000586); // rts PC(0x00000586); // rts
break; break;
} }
@ -987,9 +990,6 @@ WRITE16_MEMBER(gstriker_state::vbl_toggle_w)
void gstriker_state::mcu_init() void gstriker_state::mcu_init()
{ {
m_mcu_data = 0;
save_item(NAME(m_mcu_data));
save_item(NAME(m_prot_reg)); save_item(NAME(m_prot_reg));
} }

View File

@ -58,7 +58,6 @@ public:
VGOAL_SOCCER_MCU VGOAL_SOCCER_MCU
}m_mcutype; }m_mcutype;
int m_gametype; int m_gametype;
uint16_t m_mcu_data;
uint16_t m_prot_reg[2]; uint16_t m_prot_reg[2];
// common // common