Saturn Country Code

segasonic

New Member
Hey guys!

I was just wondering if it is possible to patch a Saturn iso with the country code 'JUE', thus enabling it to run on any territory Saturn. I've got a PAL and a Jap Saturn and it's a pain burning a different copy for use on each. SatConv doesn't seem to have the option to patch more than one code into the header, so I'm wondering if it can be done with a hex editor?

Any help greatly appreciated.

Thanks in advance.
 

antime

Extra Hard Mid Boss
Yes, it is possible, but not automatically. To play in all regions, you need the area codes "JTUE". After that, you have to add the area strings, "For JAPAN." etc.

These strings have the following format:

$a00e, $0009, "For REGION.". Together this must make 32 bytes, pad the string with spaces as necessary. (Those hex words in front of the text strings actually SH2 instructions to jump over the text string.)

Now, to insert additional area strings, you must write over some data. Fortunately, most games have a piece of standard initialisation code that immediately follows the strings. The length of this code is just enough to insert the new strings and add a short stub.

The beautiful part of this standard piece of code (SYS_INIT.O, if you have the SGL kit) is that it is completely position-independent! So what you do, is find an empty area after the main IP, insert the SYS_INIT code there and append a jump back to the game's own IP code. So after the region strings you have this:

Code:
mov.l =$relocated_code, r0

jmp @r0

nop

At some suitable place later on, you have

Code:
incbin "sysinit.bin"

mov.l =$6002ea0, r0

jmp @r0

nop

$6002ea0 is the address of the start of the game's own IP.

Provided the game uses the standard init code, the main problem becomes finding a spot with enough free space (140 bytes). To help with the offset calculations, remember that the whole first 32(?) sectors are loaded into memory beginning from $6002000.

Note that these calculations are for a game with only one region originally!
 

segasonic

New Member
I've got a friend who is a coder, so we should be able to do this.


Sort of related, did you know that the USA version of Virtua Racing will run on any territory Saturn? I discovered this by accident when I forgot to put my convertor cart into the Saturn one day.

Thanks for your help!
 

Curtis

Member
Yes, at least some versions of Virtua Racing are already setup with no (or every) country code restriction.
 

antime

Extra Hard Mid Boss
Just to clarify: it should be possible to patch any game, just not as effortlessly. SH code is by nature pretty position-independent, but there's the possibility that you would have to manually fix/recode a portion of the game's IP. The worst case would be a game that checks its headers in some way which would mean you'd have to find and disable that protection. Are there any such games?
 
Top