Language…
20 users online: Boosius, CloverLabyrinth, deported, Disk Poppy, Evernn, gabbibo104_beta, Joaoplays99, katun24,  Lazy, magianegra21, Metal-Yoshi94, Minish Yoshi, MMXWL, Obiwan723, OEO6,  RussianMan, spr0ches, The_Uber_Camper, Yzips, Zavok - Guests: 228 - Bots: 140
Users: 64,423 (2,479 active)
Latest user: Draco

Death Counter

Hey everyone, I just starting hacking 2 weeks ago! Now I'm trying to learn the fun stuff. I was wondering how to make a death counter similar to the one Panga used in Dram 2 for a kaizo hack. The only one Ive found replaces the score counter, which if I have to live with I will. But I'd love one that would replace your remaining lives counter. I already know how to get unlimited lives. Thanks.


If you want the one specifically from Dram 2, I've uploaded the code over here (paste it into a TXT file, change the extension to ASM, and apply it with Asar).

You'll also need to use the SRAM Plus patch for it to work correctly. Just add 5 bytes at the RAM address specified for the counter ($7F9D00 by default), and initialize them all to $00; if you've never used the patch before, the instructions included with it should be pretty clear.

Professional frame-by-frame time wizard. YouTube - Twitter - SMW Glitch List - SMW Randomizer
Oh wow. This is amazing. More than helpful, thank you Thomas! So just to clarify, to get the 5 extra bytes I just add "dl $7F9D00 : dw $0005" to the sram.table asm and leave all the sram.defaults at $00?


Pretty much. Make sure to add five more $00s to the list already in sram.defaults too, in case you didn't.

Professional frame-by-frame time wizard. YouTube - Twitter - SMW Glitch List - SMW Randomizer
Thanks alot, it works perfectly as far as I can tell.
The Code works fine for me. But there is one twist:
Instead of starting at "Deaths: 0" it starts at "Deaths: (Jank)"
After one death its 0 and after that normal.
So the code has to start at -1. But how do I change it so that it doesn't?
Originally posted by FragOnCrack
The Code works fine for me. But there is one twist:
Instead of starting at "Deaths: 0" it starts at "Deaths: (Jank)"
After one death its 0 and after that normal.
So the code has to start at -1. But how do I change it so that it doesn't?



i have the same problem !!!! can anyone help??? :(


Y'all probably shouldn't bump half-a-year-old threads. Make new threads to ask questions, please, or ask in a general thread like this one.
(that said, welcome to the site!)

Anyway, that would most likely be an issue with the SRAM Plus patch. That's responsible for initializing the death count when you make a new file, so either:
A) You didn't apply SRAM Plus correctly (make sure you add both the "dl $7F9D00 : dw $0005" AND the five $00 bytes).
B) You didn't make a new file after applying (otherwise SRAM Plus will not initialize those values).
C) There's another patch interfering with the same RAM somehow, in which case try changing the addresss to a slightly different value. Most of $7F9C7B through $7FC800 is untouched so you just need to play around with a few locations there; see here for a list of places used by various well-known tools, but it's not a complete list.

Professional frame-by-frame time wizard. YouTube - Twitter - SMW Glitch List - SMW Randomizer
Hello Thomas,
I know this topic is old, but I wanted to know if it can still solve some problems. I added the bytes, SRAM and did everything right the counter is working normally, but the game does not save the progress and shows the number of exits incorrect, can you help me?

I know it is very late and I dont want to bring back an old thread.

But how do I reset the counter? Do I have to patch it again or is there a possiblity to do it on the console?

Thank you for your answer


Generally, it is recommended that you do not bump old threads for any reason, particularly if you're not the creator of said thread (the creator may have the thread watched, in which case new posts will send them an unnecessary alert). Just create a new thread instead.

Anyway though, assuming you've used the SRAM Plus patch with the counter, the counter will be reset by creating a new file. If you want to clear the counter in an existing file, you can just write code to zero out the RAM used for the counter (by default, in the five bytes at $7F9D00).

Professional frame-by-frame time wizard. YouTube - Twitter - SMW Glitch List - SMW Randomizer