Viewing Issue Advanced Details
ID Category [?] Severity [?] Reproducibility Date Submitted Last Update
02160 DIP/Input Critical (emulation) Always Aug 24, 2008, 22:37 Jan 5, 2015, 11:44
Tester rittwage View Status Public Platform MAME (Official Binary)
Assigned To Resolution Open OS
Status [?] Confirmed Driver
Version 0.127 Fixed in Version Build Normal
Fixed in Git Commit Github Pull Request #
Summary 02160: mk2r14: Pressing P2 button six causes the game to hang
Description MAME crashes when playing mk2r14 when pressing anything mapped as button 6.
Steps To Reproduce Map P2 button 6 to anything (it's not mapped by default) in general config, not game config, because technically MK2 has no button 6. Press it at any time and MAME crashes with
--------------------------------------------------------------------
Exception at EIP=00B83719: ACCESS VIOLATION
While attempting to read memory at EC3B00A0
Additional Information
Github Commit
Flags
Regression Version
Affected Sets / Systems mk2r14
Attached Files
png file icon mk2.png (288,392 bytes) May 21, 2009, 00:41
png file icon mk3.png (349,645 bytes) May 21, 2009, 00:42
Relationships
There are no relationship linked to this issue.
Notes
8
User avatar
No.02210
rittwage
Tester
Aug 24, 2008, 23:03
Note this only happens with that specific ROM version (1.4).

Other MK2 rom revisions do not crash this way, nor do the other MK drivers (that I could find).
User avatar
No.03037
Luigi30
Tester
Nov 13, 2008, 01:04
If you press the button in the switch test, it doesn't crash until you exit switch test.
User avatar
No.03650
etabeta
Developer
Jan 26, 2009, 09:32
edited on: Jan 26, 2009, 09:33
in this set, when you press P2 button 6, game code jumps to FF9D04E0 and it remains there (in gdb it doesn't even crash, it simply stays there forever)

other sets do not reach that location (neither when you press P2 button 6 or elsewhere)

could it be an original bug or a bad dump?
User avatar
No.03694
Luigi30
Tester
Jan 29, 2009, 20:08
There's also a JA FF9D04E0 at FF9CF620 but it doesn't get triggered by pressing P2 button 6.
User avatar
No.04406
Tafoid
Administrator
May 21, 2009, 00:40
edited on: May 21, 2009, 00:44
Perhaps I'm missing the obvious, but in my research and recollection of this game, there were only 5 action per side for Mortal Kombat II. The buttons for MK II were Low Punch, High Punch, Low Kick, High Kick and Block and of course, start. A wired up #6 button makes no sense and it's no wonder there is not code to handle it. The Diagnostics also, only outlay 5 player buttons per side, not 6. In short, the #6 button on MK II should not exist in the emulation.

Mortal Kombat 3, on the other hand, had 6 buttons. It included the concept of a 'RUN' button.. added to the other buttons would give 6 a side.

Control Panel pictures attached to illustrate. I did notice one of the control panel pictures for MK II was actually a MK III panel (for mk2r14 to be precise), which had a MK II label on the face of the panel, but clearly shows MK III on the top of the panel in multiple places.
User avatar
No.04786
hap
Developer
Aug 8, 2009, 21:10
note about button 6 in source code:

/* Note-the real MK2 board has a special cable designed for SF2 cab conversions that has the 2 SF2 Medium punch/kick buttons as block buttons for MK2. The secondary block button registers in test mode, but does not have an indicator light show up. During gameplay, the second block only functions temporarily. You can hold the button, but the character will only take a block position for 1 second. This is correct behavior. */

----

I assume this lockup would happen on a real mk2r14 board too if connected to a 6-button cab, rev 1.4 was not a wide release according to history.dat.
User avatar
No.11356
Firewave
Senior Tester
Jan 4, 2015, 19:40
I cannot get MAME to crash. It also doesn't cause any problem to just map the button. The game just freezes when I press it in-game or freezes after leaving the switch test.
User avatar
No.11357
Haze
Senior Tester
Jan 4, 2015, 22:30
yeah, we're generally a lot safer these days when CPUs end up in the weeds, at least on non-recompiler cores.

chances are this is an original game bug, the code to support that button (which is optional) is broken, and simply causes the game to freeze / watchdog reset because it crashes the code.