Jump to content
NostAlgae37

Hardcoded zero in Dig Dug score

Recommended Posts

Hi, where do I find the location of the last digit of the Dig Dug score? I was using Hack-O-Matic to change the score font to match the arcade version of the game, but I noticed after doing so that the final digit of the score remains the same (see screenshot below), so it must be stored some other way than as graphics. And if so, is it even possible to alter it? Thanks.

 

post-44939-0-74777800-1553156080_thumb.png

Share this post


Link to post
Share on other sites

icon_idea.gif The '0' graphics are not stored as data. Instead the code loads the immediate values, pushes them onto the stack and pulls them for drawing.

L9194
    ldx     #$cd                    ;2  stack pointer, do NOT touch this value!
    txs                             ;2        
    lda     #$6c                    ;2  2nd line
    pha                             ;3        
    lda     #$c6                    ;2  middle line, repeated 3x      
    pha                             ;3        
    pha                             ;3        
    pha                             ;3        
    lda     #$6c                    ;2  last but one line      
    pha                             ;3        
    lda     #$38                    ;2  first AND and last line!      
    pha                             ;3  first line at bottom of stack (pulled first)      
    sta     ram_CE                  ;3  last line at top of stack (pulled last)
  • Like 1

Share this post


Link to post
Share on other sites

OK, but after I altered all of the graphics for the score digits (including the zero), why does the last digit (which is always a zero) continue to look like the old font instead of the new font (the first 2 zeros in the screenshot above)? Is there another zero graphic located somewhere else in the rom that I missed (I thought that all of the score numerals were stored in a row in one place)?

Edited by NostAlgae37

Share this post


Link to post
Share on other sites

You got me wrong. The last zero exists only as code, not as data/graphic. So you have to change the code to change the last zero.

Share this post


Link to post
Share on other sites

Change the 2 #$6C values shown in the code snippet to be #$4C and #$64.

 

You'll see them at $0198 and $01A0 when using a bithacker.

Edited by Nukey Shay

Share this post


Link to post
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.

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...