Jump to content
IGNORED

Mame Debugging - Trying to fix Dig Dug 2 Score Issue - M6809 assembly


negative1

Recommended Posts

Has anyone tried to debug games in MAME and fix the code.

 

I've looked at Don Hodges fixes for : Pac-Man, Ms. Pac-Man, Galaga, etc

 

http://www.donhodges.com/how_high_can_you_get2.htm

 

[i've contacted him also, but no one has worked on this]

 

 

 

I'll document my findings here in case anyone can assist.

 

===============================================

 

Dig Dug 2

 

----------------------------

 

Issue - Dig Dug score works until 999,990

 

then goes to 1,000,000 which shows properly.

 

 

 

At that point game score stops incrementing,

 

but gameplay continues properly.

 

 

 




Scoring checks

----------------------------

If Current Score > High Score,

then High Score = Current Score;



Default = 20000

==================================

When game is over, score is checked

against high score table.



5 scores in table compared.



Initials entered.





Game scoring checks

------------------------------------

Score is checked in 2 locations.



Comparison is made to High Score.





Example:

----------------

26 60 0 - 26600



Writing high score

==================================

0x1000 - 0 A B C D E F

00 00 26 60 00 00



Player 1 score

===================================

1700 1701 1702 1703

0x1700- 0 1 2 3

00 26 60 00

==========================================





At 999,990 the internal high score does not

change:

A B C D E F

0x1000 - 01 09 99 90 00 00



However, Player 1 is stuck at 1,000,000



0 1 2 3

0x1700 - 10 00 00 01



0x1703 - 2nd digit is men

0x1704 - 2nd digit is round number



The highscore shows 1,000,000 points correctly.



Next game:

1,000,000 is at 0x1004 - 01 00 00 00



Player 2 score is temporarily stored at 0x1700,

and then swapped to

0x1740 - 1 2 3 4

10 00 00 00

1

mil,hundred thousands



2

ten thousands, thousands



3

hundreds, tens

Player 2

 

===================================

 

When player 2 scores 1,000,000 the same behavior

 

happens. Score does not track anymore, and stays

 

at 1,000,000.

 

 

 

You can poke scores over 1,000,000 but the game

 

does not track either, although the high scores

 

changes to reflect 1.1 million, etc.

 

 

 

Poked scores over a million show up in the

 

high score table, like 7.1 million, and

 

also show up as the high score or player score

 

once the game is over.

 

 

 

Post 1,000,000

 

==================

 

After getting to the 1 million point mark,

 

resetting the score to 0, does not fix

 

the code. The score stays at 1,000,000 and

 

nothing gets reset, although the registers

 

show 0.

 

Ru63I3y.png

zfAbPdy.png

 

 

Videos of gameplay to 1 million:

 

 

At this point I'm trying to debug the assembly code for the Motorola 6809.

 

[it was used in Mappy, and Super Pac-Man also]

 

 

 

The reference manual is here : https://www.maddes.net/m6809pm/sections.htm

 

later

-1

Edited by negative1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...