What to Do before the Sega Genesis Mini Hack

This guide will cover techniques for hacking games on the Sega Genesis Mini console. Hacking games from other platforms can differ significantly, so it is not recommended to use what is written here as a template unless you understand what you are doing. The guide is aimed at beginners. And the author is not a professional programmer in general, so some definitions and names can and will be different. Hacking means learning and changing the game itself, not replacing graphics or sounds.

Open ROM

To start the Sega Genesis mini hack, let’s open the ROM with WINHEX. You can download it on the official website.

A window will open where some information about the file is displayed on the left. And on the right, there will be the ASCII representation. Usually, at the beginning of the cartridge, there is information (title) about the game, which can be read in text form.

You can scroll the slider throughout the ROM to look for such text elsewhere. If there is, it can usually be changed without any problems. Don’t try to change other numbers in the hopes of getting a good result.

Important Information to Remember

If you click on the offset column with the mouse, the address column will appear in the 10-digit system. This is a very common mistake when you accidentally press this. We will only use the hex system. If you clicked, you need to press again to return it back. This will become noticeable by the presence of letters in addresses.

How to Make Hacking More Comfortable

Now it is recommended to turn on the text view at the beginning. Otherwise, when scrolling, graphs will start to pop up. Each line represents a command for the processor, where on the left is the command itself.

Now if you select any command with the mouse, and then go to the second tab, you will see its display in ROM in hexadecimal form and its location. The command will be highlighted in green and can be of different lengths (from 2 to 10 bytes or more). This feature will allow us in the future to easily find and change them if needed.

Unfortunately, IDA cannot determine the location of all parts of the program itself (that is, separate all the game code from everything else), so we have to finish it.

What to Do Next

The option in IDA, Options-General-Kernel Options 1- Make final analysis pass, should be checked (in the box). And then click Reanalyze Program. This will allow you to separate more code than usual. But this also causes surplus when pieces of non-code are also defined as code.

This is not a big deal because in IDA you can always convert data to code and back. Use this option (you can also press it a few times) if IDA has separated too little code. The large bar at the top of the tab determines the number.