Glitch City Laboratories Archives

Glitch City Laboratories closed on 1 September 2020 (announcement). This is an archived copy of a thread from Glitch City Laboratories Forums.

You can join Glitch City Research Institute to ask questions or discuss current developments.

You may also download the archive of this forum in .tar.gz, .sql.gz, or .sqlite.gz formats.

Generation I Glitch Discussion

Cause of completely corrupted Pokemon Red cartridge? - Page 1

Cause of completely corrupted Pokemon Red cartridge?

Posted by: pikminmovie
Date: 2019-11-13 16:34:00
I had made a reddit post (https://www.reddit.com/r/pokemon/comments/dvl995/help_with_original_pokemon_red_copy/) and couldn't get any extraordinarily helpful answers, so I thought I'd make an account and come here.

I have given more information in the reddit post, but long story short, I picked up a cartridge of red for my Gameboy SP at a local game store. Upon bringing it home and trying it, I quickly figured out that there were some serious issues with the cartridge. A very long, eventually repeating until soft lock, chain of Pokemon cry's and altered town music plays when trying to make a new save file and speak to professor Oak, and resetting save data produces similar effects, with a text box eventually appearing that says "TRAINER9". I have determined that this is not a hardware issue by crosschecking on a different device; still same issue. Here's a link to a video I posted documenting it (unprofessional, sorry, if anyone is interested I can record both Oak and attempting to reset save data fully): https://www.youtube.com/watch?v=ojWdX0sKC-g

Does anyone here have any idea what may be causing this to happen, or if there anything else that I might be able to try/document? Thank you for your patience.

Re: Cause of completely corrupted Pokemon Red cartridge?

Posted by: Parzival
Date: 2019-11-14 00:30:13
Sounds like an MBC fail, as this sounds similar to what happens when you truncate the game to like 512k.

Re: Cause of completely corrupted Pokemon Red cartridge?

Posted by: Sherkel
Date: 2019-11-14 00:52:34
I honestly didn't have a clue, but yes, it sounds like that: https://gbdev.gg8.se/wiki/articles/Memory_Bank_Controllers

You'll notice that while DisplayTextBoxID isn't banked, everything else you're accessing is: https://github.com/pret/pokered/blob/master/main.asm#L17 (the "clear all saved data" function is way down here)

Pretty bizarre to come across on a physical cartridge. Is there any chance you can dump the ROM and post an IPS?

Oh, uhh, Isso gave a much more informative response, by the way.

Re: Cause of completely corrupted Pokemon Red cartridge?

Posted by: Torchickens
Date: 2020-03-06 12:27:56

I had made a reddit post (https://www.reddit.com/r/pokemon/comments/dvl995/help_with_original_pokemon_red_copy/) and couldn't get any extraordinarily helpful answers, so I thought I'd make an account and come here.

I have given more information in the reddit post, but long story short, I picked up a cartridge of red for my Gameboy SP at a local game store. Upon bringing it home and trying it, I quickly figured out that there were some serious issues with the cartridge. A very long, eventually repeating until soft lock, chain of Pokemon cry's and altered town music plays when trying to make a new save file and speak to professor Oak, and resetting save data produces similar effects, with a text box eventually appearing that says "TRAINER9". I have determined that this is not a hardware issue by crosschecking on a different device; still same issue. Here's a link to a video I posted documenting it (unprofessional, sorry, if anyone is interested I can record both Oak and attempting to reset save data fully): https://www.youtube.com/watch?v=ojWdX0sKC-g

Does anyone here have any idea what may be causing this to happen, or if there anything else that I might be able to try/document? Thank you for your patience.


Yes, it might be a cart fault (such as memory bank controller/MBC fail) that's speculated to be why Oak turns into Gastly; because  the game is stuck on the bankless memory region and the Oak intro is meant to use the banks; so it runs the wrong code causing the seemingly random glitch (because the game cannot differentiate code and data automatically). You're not alone too https://www.youtube.com/watch?v=FyXVd_lpjRQ

Long answer, the Game Boy uses the MBC for Pokémon Red, and only 0000 to 0:4000-0:7FFF can be accessed from the ROM at a time. What the MBC does allows the game to grab data from other parts of the ROM, such as 1:4000, 2:4000, and others. In order to convert a pointer into an offset, we follow the guide here https://datacrystal.romhacking.net/wiki/Pointer Each three byte pointer (Y:XXXX) represents what is referred to as an offset, and is the exact location in a hex editor; but for the most part not the game while it is running.