SA1 analog drift fix, release of Dreamcast Image Builder, Autodemo research and more

It’s been an eventful couple of months, so there are several things I’d like to talk about today.

New version of the SA1 analog fix

You may have heard of the analog deadzone fix for SA2 DC by OnVar. I was looking at input code in SA1 and found many similarities, so I made a request to woofmute, who successfully ported OnVar’s fix to SA1. The fix is available for the US version (1.005) and the Autodemo. I’m not sure whether the issue is addressed completely or if the fix has any side effects, but it appears to work and it’s definitely better than my old hack, so I suggest you give it a try.

The fix injects custom code into 1ST_READ.BIN. The patched bytes for the US version are as follows. With some patience you could turn it into a very long CodeBreaker code…

;Input function hijack
411e2=0ce0f6f3f5f34c8925c708f235f2488908a10ce0

;Input Patch block 1
41284=20e0f6f304c708f2f5f3b28935f2b08920e0b6aff7ff

;Input Patch Orig code reposition
41406=f7ff20e0f4aef6f3

;float for block 1
4129c=000040c5

There are two ways to get the patch:

  1. If you have the TOSEC GDI of SA1 US 1.005, you can apply an xdelta patch to track03.bin. It works the same way as the SA2 patch in the description of the video linked at the top of this post, so you can use the video for reference.
  2. To apply this fix and more, you can use the new Dreamcast Image Builder that I will talk about in the next section. The Autodemo version of the fix is also available for Dreamcast Image Builder.

Release of Dreamcast Image Builder

This is an update to SA1-DC-HD, a project that originally started as a helper tool to add various enhancements to SA1 DC for playing on the flycast emulator. The project has grown to become a universal patcher for Dreamcast games.

As you can see, it’s heavily inspired by the SADX Mod Loader/Mod Manager and uses the same concept of “mods” to add hacks to games. Of course it’s a lot more limited than the actual Mod Loader, but you can do neat things with it. For example, to test its capabilities I made a mod that replaces Deer with Sheep from SA2:

(Chao body parts not implemented yet)

You can check it out here. All mods from SA1-DC-HD are built-in, so you can use it right away. The wiki explains how to use the tool and develop mods for it.

New Autodemo research

You may have seen new videos uploaded by Speeps and woofmute which demonstrate various debug features of the Autodemo and levels that didn’t work before, such as Casinopolis. This was made possible thanks to the research done by Speeps, woofmute and other members of x-hax, as well as previous research by evilhamwizard, ItsEasyActually, supercoolsonic and others.

As you may know, parts of the Autodemo come from different builds of the game that were at different stages of development. When the Autodemo was put together, only the levels that were meant to be shown in the demo were recompiled, and the other levels were left over from older builds (for most of these, textures and lighting files were also missing). We can tell which binaries were recompiled by looking at file dates on the Autodemo GD-ROM:

15.10.1998 - binaries that boot without hacking

STG01 (Emerald Coast)
STG04 (Speed Highway)
STG05 (Red Mountain)
STG08 (Ice Cap)
STG10 (Final Egg)
ADV00 (Station Square)
ADV00OBJ (Station Square objects)
ADV0100 (Egg Carrier Outside)
ADV0130 (Egg Carries Inside)
ADV01OBJ (Egg Carrier objects)
AL_GARDEN00 (Station Square Chao Garden)
AL_MAIN (Chao)
B_CHAOS2 (Chaos 2)

07.10.1998 - binaries that don't boot without hacking

AL_GARDEN01 (Egg Carrier/Beta Windy Valley Chao Garden)
AL_GARDEN02 (Mystic Ruins Chao Garden)
AL_RACE (Chao Race)

24.09.1998 - binaries that don't boot without hacking

STG00 (Test stages)
STG02 (Windy Valley)
STG03 (Twinkle Park)
STG06 (Sky Deck)
STG07 (Lost World)
STG09 (Casinopolis)
ADV02 (Mystic Ruins)
ADV02OBJ (Mystic Ruins objects)
SHOOTING (Sky Chase)
MINICART (Twinkle Circuit)
B_E101_R (E-101 MK2)
B_ROBO (ZERO)
B_EGM1 (Egg Hornet)
B_EGM3 (Egg Viper)
SBOARD (Sand Hill)
B_CHAOS0 (Chaos 0)
B_CHAOS4 (Chaos 4)
B_CHAOS6 (Chaos 6)
B_CHAOS7 (Perfect Chaos)

You can see that there are three “sets” of files sorted by last modified date. The files that don’t boot were compiled against an earlier version of the game’s main binary (1ST_READ.BIN), so the pointers to functions and data in the main binary are all invalid in these files. However, it’s possible to find the functions and data they were meant to point to by comparing the pointers to known functions and data between these files and the files that boot.

Earlier work on this, which demonstrated partially functional Windy Valley and Sky Deck, was posted by evilhamwizard on Sonic Retro. More recently this was picked up by Speeps, who started putting together a list of known broken pointers and their correct counterparts. As the pointer list grew, more levels became functional when known pointers were replaced. To facilitate mass pointer replacement and game testing, I added Autodemo support to my SA1-DC-HD project (now Dreamcast Image Builder). As we were experimenting with the Autodemo, I adjusted the image builder’s mods system to be more flexible and easier to use and converted (together with woofmute) Speeps’ modifications into mods for it. I also repurposed some of my previous work to find missing textures by matching the names in the Autodemo’s texture lists against textures in the final version, the E3 build, the Autodemo Windy Valley mod for the PC version (where missing textures were recreated by its developers) and Dreamcast SDKs (which surprisingly have some early SA1 textures).

As a result of this combined effort, we got the game to show stuff that was never seen before. For example, here’s a preview of the old version of Chao Race restored by Exant:

Or a very early version of the Mystic Ruins:

Or woofmute’s restoration of the debug object placement editor:

Or a super early version of Twinkle Circuit:

Of course, you also have Speeps’ near-complete restorations of Twinkle Park, Lost World and Sky Deck. The biggest restoration so far is the early Windy Valley, the holy grail of the Autodemo for many SA1 fans. It’s based on Speeps’ and evilhamwizard’s pointer fixes and uses textures from the 2018 PC mod by supercoolsonic & ItsEasyActually.

There’s a lot more stuff released and in progress. We now have a public repository with some Autodemo mods, which you can apply with Dreamcast Image Builder to get the restored functionality and content ingame.

Note: Not all of the mods work on hardware at the moment. flycast is recommended.

The fascinating Korean version of SADX PC and release of the Korean mod

TLDR version: There was a Korean version of SADX PC released back in 2004. I ported the Korean translation to the Mod Loader, so you can now play SADX in Korean if you install this mod. The mod is compatible with Dreamcast Conversion and Dreamcast DLC but incompatible with HD GUI.

Four years ago I got my hands on a somewhat rare version of SADX PC. I was completely unaware of its existence until I accidentally ran into a listing on an auction, so I got it right away. I’ve mentioned it before in a previous post, and today’s mod release brings the occasion to finally talk about it again.

Introduction and game package

This version was released in July 2004 in Korea by a game and toy company called Sonokong. It’s a complete Korean translation of the game with English voices. The game comes in a box with a fully translated manual, which is also in color! It looks a lot better than black-and-white Japanese and US manuals I’ve seen until now. Here are some pictures of the box, the discs and the manual. Please excuse the poor picture quality, maybe someday I’ll get to scanning these properly.

Installation and initial testing

Just like the US version, the game comes on two CDs. The simple CD check is also the same, so you can install and run the game on Windows 10 and above, unlike the Japanese version which no longer works because of SafeDisc. With the Korean version, you can pass the CD check even with the US version’s CD 2.

The autorun and the installer are also fully translated.

I can’t comment on the quality of the localization since I don’t read Korean, but I can say for sure a lot of work was put into it. Unlike French, Spanish and German translations that come with the US and Japanese versions, this one translates not only all textual data, but also all menu textures, the title screen and the main menu background. But the most impressive part is the Korean font used for subtitles and Chao Garden messages. To my knowledge, this is the only official release of SADX that introduces both asset and programming changes to accommodate a language that wasn’t in the original game. It’s also executed in an interesting way, which we will get to a bit later.

As amazing as this version is, it’s still the 2004 PC port of SADX at its core, so the game has terrible graphics with no mipmaps, broken windowed mode at non-4:3 resolutions, poor music quality etc. It’s pretty hard on the eyes, especially in motion.

(From now on, I’ll be using screenshots from the US version with the Mod Loader and the Korean mod)

Korean localization and option menu differences

Korean text replaces Japanese in this version. English text is also available, although the title screen and the main menu background will always use the Korean versions of the textures. The game doesn’t let you pick Japanese voice language, so only English voices can be used. Interestingly enough, Japanese voices are still included with the game: it just doesn’t show the voice language setting in the options menu and overrides the voice language variable with English as soon as a save file is loaded. However, before a save file is loaded the game still plays the “Select a file” voice from the Japanese voices folder. To work around it, the developers replaced that voice with its English counterpart. The rest of the Japanese voices are untouched.

I’m not entirely sure, but I think such elaborate workarounds to make sure no Japanese is heard in the game may have had something to do with Korean laws regarding Japanese media, which were stricter when the game came out.

Funnily enough the texture for the option was still translated, so when you use the mod on the US version with the Mod Loader, you can select Japanese voices as if the option was intended to be there originally (although it says “Korean” instead of “Japanese”). You can also select other languages for text (not sure if you’d really need to if you’re playing this!), which the Korean version doesn’t let you do.

The localization has everything you’d expect, including character tutorials, Mini Game Collection etc.:

Reverse engineering the Korean font

The implementation of the font used in the last two screenshots is intriguing. What caught my attention initially was the large size of the FONTDATA0.BIN file, which is used for Japanese characters in the original version (1.72MB vs 759KB in the original). My first guess was that they either replaced Japanese characters with Korean ones, or added them to the end of the file with the IDs matching the Korean codepage 949.

I started inspecting the file in SADXFontEdit in SA Tools. As expected, this file contains Hangul characters used to display Korean subtitles and Chao texts. However, apart from those, the file also has some characters from other languages, including Greek, Russian, Chinese and Japanese, which amounts to a total of 20609 characters (for comparison, the original file used for Japanese has only 8836, and almost all of those are Kanji, although Cyrillic and some other characters are present as part of the Japanese codepage). On top of that, soon I realized that character IDs stored in the file matched those of the codepage 1200 (UTF-16).

Yes, you read that right. In the Korean version of the game the subtitle font is an actual Unicode font. Although it only supplies specific blocks of the Basic Multilingual Plane, in theory you could add back the other blocks to implement any language included in the plane. Back in 2020 when I first discovered this, I updated SADXFontEdit with some new functionality, including support for the Unicode layout, so when you select the correct codepage you can see the matching character next to its ID.

As we know, the US and JP versions don’t support Unicode, so how does this work? The game’s dialog texts, menu prompts etc. were compiled into the game as strings encoded with the Korean codepage 949, not Unicode. However, when the game processes text data to create a subtitle texture, it parses the characters and assigns them Unicode IDs to be used to pick graphics from the font data you see in the screenshots above.

This was where I ran into an issue I didn’t understand at first. When I first ran the game, it would either display garbage text in place of subtitles, or just crash. That was how I found out that the Korean version required the system locale (language for non-Unicode programs) to be set to Korean for subtitles to render properly.

If the game already knows it’s converting Korean to Unicode, why does it need that? Eventually I found the answer when I was looking at the game’s font related functions in the disassembly that I quickly cobbled together. The Korean version uses the function MultiByteToWideChar to convert “C strings” (in this case Korean strings in the local codepage) to UTF-16 “wide strings”. It’s an interesting solution considering that other versions have a custom function to parse characters and assign font IDs to them.

So why does it fail when the system locale isn’t set to Korean? The developers call the function with the default first argument (0), which takes the current system locale as the source codepage. As a result, Korean text is converted to Unicode as if its original codepage is whatever you have set as the language for non-Unicode programs. If the developers of the Korean version set the first argument of MultiByteToWideChar to 949, the Korean version would display subtitles correctly on any system regardless of the locale. I think a lot of people would’ve never caught this issue because the game was meant to be sold only in Korea. Anyway, we can fix this on the mod’s side.

Implementing code differences

With such changes to the font system, simply replacing FONTDATA0.BIN in a mod wouldn’t make the game support Korean, and a bunch of hacks had to be done first. One thing to do was to introduce calls to MultiByteToWideChar before letting the game parse text data. As I didn’t know the stuff I explained in the previous paragraphs, it took me a while to realize the importance of these calls, and my initial attempt to get the game to display Korean text correctly were unsuccessful. I gave up on the mod for a while, and it was only this month that I gave it another try and figured it out. Another necessary change was in the function that maps character IDs to bitmap data in the font file. There were overrides for , and , but other than that it was pretty straightforward.

I put together a DLL mod that replaces three text-related functions, then I replaced one Japanese hint message in Emerald Coast to test it. The Mod Loader used a hardcoded codepage for strings that are normally in Japanese, so I added global codepage overrides for all languages, which can now be used by other mods.

At first I wasn’t sure how far I could go with this, but when I finally saw the Mod Loader display Korean text, making a Korean mod started looking feasible. I was also driven by the technical challenge and the uniqueness of this version of the game, support for which required several changes to our tools, which I was happy to implement.

Extracting and importing Korean text

Speaking of technical challenges, obviously I had to somehow extract all Korean text from the game and put it into the mod. Finding it all manually was out of the question, which was part of the reason I gave up on the mod last time. However, after my experience with matching assets between different versions of the game, I was tempted by the idea of automatic splitting. Since the game still has English text, it’s possible to scan the EXE to find it, and then work up the structures to get to the start of each item. There were three types of data that had the largest amount of text: cutscene text, Tikal hints and multi-language strings such as character unlock messages, menu prompts etc. I put together a program to make the task easier. Basically it created an INI file for SA Tools’ split tool to extract the text from the Korean EXE. Of course some manual tweaks were required to ensure all addresses were correct, but the program did most of the tedious work. Cutscene text in particular required almost no touch-ups because I made it verify the text in other languages to ensure it’s the same entry in both games.

Building a mod from this data in SA Tools was a challenge. I had to add custom codepage support and fix a few bugs, but mod building in the tools is more stable now and the end result was worth it.

At this point I ran into an issue many retranslation mods had to deal with. There was some text in the game that wasn’t supported by the Mod Loader and/or the SA Tools at the time. It’s still possible to replace such text in a DLL mod, but I wanted all text replacement to be done via the Mod Loader’s INI-based system, so I had to do some work on the tools again. I added support for the following data types, which can now be replaced in mods without code:

  • Tikal hints that show up after you die on a boss. These are different from the hints you see in stages, and they’re stored in different ways depending on the boss, so I had to improvise a bit to make them rippable in the tools and replaceable in the Mod Loader.
  • Mission descriptions for Mission Mode.
  • Mission Mode tutorial text.
  • Single language strings, such as unlock prompts for Game Gear games or Metal Sonic. I added them to the SA Tools a couple years ago but not to the Mod Loader.
  • Multi-language strings, such as character unlock messages or “Welcome to Twinkle Circuit!”. Same as above.

Implementing Chao texts

With all that in place, all Korean text in the game was finally transferred. There was one big obstacle remaining: Chao texts. Although it loads the same font data, the Chao text system in SADX uses completely different code from the system used by subtitles and menu prompts, probably because it was copied from SA2B and duct taped with the SADX font system. So I had to do the same thing I did for the subtitles for the Chao text functions. This was probably the most difficult part of the whole mod. The functions involved with SA2B text were all difficult to hook, and even when I managed to replace them correctly I would only get crashes. It took me a long time to get a working decompilation of the functions that convert strings for the SA2B system. I’d like to thank Kell for a decompilation of these functions in the US version, which I used for reference.

Interestingly enough, the Chao system also uses wide strings internally, but all text is stored in the Japanese codepage, or Korean in this case. The game performs conversion from C strings to wide strings just the same, but the Korean version uses MultiByteToWideChar again instead of the simple parsing function used for Japanese in the original version.

After many hours of debugging I finally figured out the error in my decompiled code that was related to finding character data. In the pseudocode I got by decompiling the Korean version, the cell ID of the character data in the font was calculated by adding 0x776A to the character ID, which made it go out of range. The sign had to be flipped to make it subtract 0x8896 instead. After I fixed that, the text started working.

Now the mod was ready for testing. Out of curiosity I tried it with Dreamcast Conversion and realized that the Dreamcast Chao Garden hints were missing. Luckily they were translated in the Korean version, so I added them to SA Tools, made some changes to DC Conversion to make it more compatible with mods that replace them, and reimported the translated hints. I was happy that even the normally unused Dreamcast hints were translated.

Mod download, compatibility and conclusion

SA Mod Manager 1-click install
Manual download

The mod is compatible with Dreamcast Conversion, but with a few quirks. Since there are no Dreamcast menu textures in Korean, Dreamcast Conversion’s replacement of some GUI textures will be undone by this mod. This is a quick fix, and I might update it with proper compatibility eventually. There may be bugs in the mod, particularly crashes. Please send me crash dumps if you run into any.

For obvious reasons HD GUI is incompatible. If you’re interested in making HD Korean textures and an HD Korean subtitle font, please let me know.

This is the first translation mod that works by replacing the Japanese font, and the first to modify font-related code. I hope this release attracts more Korean players to SADX modding and helps other translation mods. I also think it’s truly amazing that after all these years of research and reverse engineering there are still new things about this game waiting to be discovered.

The mod’s source code is located here.

Native Steam savegame support in SADX 2004

Previously you had to use BetterSADX or the SADX Mod Installer to transfer savegames to the 2004 version, but soon it will be possible to load the Steam version’s saved games in the Mod Loader. You will be able to load files directly from their original location, so no transfer is required whatsoever. If you play a Steam saved game in the modded 2004 version, the original Steam version will also be able to load it, so you can play the same file on both versions. The Chao Garden save is also supported: if you load a saved game located in the Steam folder, it will use the Steam version’s garden file. As you can see in the screenshot, custom filenames (ANSI/English only) are also possible, so your saved games no longer have to be named “SonicDX??” for the game to recognize them.

The format used for saved games is almost identical between the two versions, but there are a couple differences that make them incompatible. You can load 2004 saves in the Steam version if you rename them, but not the other way around. The files created by the Steam version are 16 bytes bigger (1408 bytes vs 1392 in the old port), and 12 of these extra bytes are used to store the file creation date and time. At the beginning of the file there is a checksum, and both versions use the same algorithm which calculates the checksum value based on the contents of the whole file. The reason the 2004 version won’t load Steam saved games is because the game only accounts for 1392 bytes when reading the file and calculating the checksum, which doesn’t match because it doesn’t include those extra 16 bytes in the calculation. The Steam version removes the checksum check on the file select screen so it recognizes saved games from the 2004 version, although the date and time might look wrong. When progress is saved in a file that originally came from the Steam version, the Mod Loader writes the current date and time into the file so it should display correctly in the Steam version as well.

Dreamcastify is back

Dreamcastify, a website that documents SADX downgrades, was having some technical issues throughout the last two years. Some video comparisons that were hosted on Youtube were taken down, and after a WordPress update the pages didn’t load properly and many images were missing. I reworked all pages so that they load again and made the following changes:

  • All video comparisons are now hosted on the site itself.
  • The pages display smaller JPG images by default, and a full-size PNG version of each image can be seen if you click on the preview. This made the site much more responsive.
  • There were some minor text edits (mostly wording) and some info updates regarding mods and emulation.
  • The feedback section was removed. Sorry, I don’t have the resources to read all of the comments. I haven’t looked at the newly arrived 850+ comments for about 3 years now, and from a quick glance they seem to be just spam anyway.

This is likely the last update to the site for the observable future. I was originally going to take it down because I didn’t have interest in updating it anymore, but then I thought it should be left online as a source of information, so I took a weekend to sit down and fix it for good, as well as rewrite some things.

I’d like to thank KGL for getting the initial editing and format updates done.

List of available Sonic Adventure (+DX) builds (update 2023/09/14)

This is a list of all distinct Sonic Adventure (+DX) versions that can be obtained today as far as I know. Originally I wanted to make a branching timeline of SA1 builds, but I couldn’t find a good way to put it on a blog, and I also realized some builds, like the Autodemo, don’t necessarily fit in a single timeline, so here’s a list instead. There is also a lot of information on SA1 development on TCRF, which I recommend if you want a timeline of SA1 development with screenshots and other details.

Dreamcast builds

Let’s start with the original game on the Dreamcast. Note that I’m not including builds that we don’t have, such as the Tokyo Game Show demo and the version used for the Tokyo International Forum unveiling video (assuming the footage comes from a single version of the game).

TitleVersion codeRelease dateDate in IP.BINComments
Sonic Adventure (Autodemo)1.000None1998.10.16Contains a mix of binaries and assets in various states of development. Some stage files were built for an older version of the main executable.
There’s a lot of stuff written already about this version, so I won’t go into details. I have two copies of the actual disc, which looks orange in real life unlike the scan on Hidden Palace which looks more red, but that’s probably just a scanner difference. I dumped it, and the contents were completely identical to the Hidden Palace version.
Sonic Adventure (Japan)1.0071998.12.231998.12.10The earliest official release of SA1 on the Dreamcast. Japanese language only. Some cutscenes have different camera angles compared to later releases. Some SET objects and camera setups are different in levels. This version has running “motion blur” effect for Sonic and Knuckles and the cowgirl billboard in Casinopolis, which were removed in later releases. This version also has some programming differences, such as collision for the burger shop man and different Lost World spikes behavior.
Sonic Adventure Taikenban1.0021999.??.??1999.03.02Demo version for the Japanese market. Mostly similar to the original JP version. The only version that introduces programming and SET layout changes to make the game easier.
Sonic Adventure – Trial Version for E31.000None1999.06.08A version of the game with an in-progress localization. Contains an early version of the English script and different voice acting. Some character sounds are also unique to this build. The title screen has a completely different design, and the level select menu has difficulty ratings. Starting with this version the running blur effect is missing. Cowgirl is replaced with another billboard starting with this build. Some SET layouts have been updated to reduce Z fighting. Some cutscene camera angles were also updated starting with this version.
The date in IP.BIN is interesting because it’s later than Limited Edition despite being an earlier version of the game. The actual game was likely compiled in spring 1999 (not earlier than March 12, as indicated by the strings present in 1ST_READ.BIN).
Sonic Adventure Limited Edition1.001 and 1.0021999.07.??1999.06.03 and 1999.06.04This version was available in the US for a short time before the final US release. Unlike previous versions, the level list in Trial Mode no longer matches the game’s internal level list. Internet features are replaced with a short demo. The Internet demo is also present (although not accessible normally) in all versions of the game after this one. This build has incomplete localization in languages other than English, and the menu to change the language of messages and voices isn’t functional yet. There are at least two variations of this build, however the only differences are between IP.BIN files, which have different dates, region codes and version IDs.
Sonic Adventure – Trial VersionGenerator Vol. 1: 1.002

Dream On Vol. 2: 1.000
Generator Vol. 1: 1999.09.09

Dream On Vol. 2: 1999.09.30
Generator Vol. 1: 1999.07.08

Dream On Vol. 2:
1999.08.06
Demo version based on the US release. Unlike Taikenban, this demo doesn’t play cutscenes except those played after waiting on the title screen.
Sonic Adventure: Tournament Disk1.0001999.08.101999.08.10A demo version used in an event called “Sega Dreamcast Mobile Assault Tour”. In terms of completion, this version is somewhere between Limited and final 1.004. Almost all binaries have the same content as 1.004 except different pointers to accommodate the recompiled 1ST_READ.BIN. There is no browser but there are references to the Internet demo like in Trial. Files for other European languages are not finished yet. Other differences are leftovers from the Japanese version or have to do with the game being a demo. More details on TCRF.
Sonic Adventure (US)1.0041999.09.091999.08.12First American release. Mostly the same as Limited but with finished support for other languages. From this version onwards the game includes the TV Settings menu to select between 50 and 60 hz modes.
Sonic Adventure (Europe)1.0031999.10.141999.09.09The first version that introduces an animated title screen. Some SET layouts were updated from US 1.004 with minor fixes.
Sonic Adventure International (Japan)1.0031999.10.141999.09.20Mostly the same as the European release. Both Japanese and American SA1 websites can be accessed via the built-in browser.
Sonic Adventure International (Dreamcast Express Extra)1.0011999.??.??1999.11.19Included on the demo disc “Dreamcast Express Extra”. Unlike the other demos, this one comes with an animated title screen. Pressing Start takes you directly to Sonic’s Emerald Coast, which drops you back on the title screen after you beat the stage. Although only Emerald Coast is playable, the game includes all cutscenes and gameplay demos that play after waiting on the title screen, so you can see several Action Stages and Adventure Fields ingame. This demo lacks English HUD and menu textures, so the game will have visual glitches if the console’s language setting is not Japanese.
Sonic Adventure (US) – Sega All Stars version1.0052000.08.221999.10.05Second American release based on European or International.

Gamecube builds

On the Gamecube we have two very interesting prototypes which fueled a lot of SA1/SADX research. Much of the knowledge on the game’s internal workings came from the first Preview prototype years before we got the X360 version with debug symbols. Apart from the prototypes, the builds on this platform haven’t been studied as thoroughly as the Dreamcast version. It is notable that the Gamecube ports have sequenced sound effects, which use a Gamecube adaptation of the MLT file format that was originally introduced in Dreamcast SDKs. Interestingly some character grunts are similar to the ones found in the E3 1999 version of SA1 DC, and some changes to assets are similar to the Autodemo and early prototype screenshots of SA1, but that’s a topic for another post. There is no doubt that SADX code is based on a later version of SA1, most likely 1.005 or International. Also, all versions of SADX have a leftover texture archive with title screen textures from SA International.

TitleRelease dateDate in apploader.imgComments
Sonic Adventure DX – PreviewNone2002.04.10This version appears to be based on SA International and contains work-in-progress “DX” changes. Some features that were disabled in later builds are partially functional in this build. This version has a lot of debug functionality. The original game’s palette lighting system can also be activated in this version, although it doesn’t look correct. The Chao system hasn’t been reworked yet and is mostly functional and similar to SA1 DC. Although other languages are present, the game only works correctly in Japanese. This build has leftover binaries from an even earlier version of the port that hadn’t introduced the “DX” changes yet. Unfortunately we haven’t been able to boot the earlier build due to version differences between the REL files.
Sonic Adventure DX – ReviewNone2002.09.05Most “DX” features and redesigns have been finalized. The Chao system is a work in progress. There is also a Chao debug menu. Languages other than Japanese are functional. Like Preview, this version has leftover binaries from an older version of the port without the “DX” changes.
Sonic Adventure DX (Japan)2003.06.192002.09.05The first official release of SADX on the Gamecube.
Sonic Adventure DX (Europe)2003.06.272002.09.05Although the binaries were recompiled, there are no known differences from the JP release other than default language.
Sonic Adventure DX (US)2003.06.172002.09.05Although the binaries were recompiled, there are no known differences from the JP release other than default language.
Sonic Adventure DX (Gamecube Preview Disc)2003.05.202002.09.05A demo version included on the Gamecube Preview disc. Functions similar to the Trial version on the Dreamcast. This release and the Challenge Version are the only two versions of the game that use colored banners in the character select screen. The Start button is disabled during gameplay. No cutscenes are included, however the intro movie plays after waiting on the title screen. The music loops 3 times before the intro movie plays.
Sonic Adventure DX Challenge Version (Gamecube Interactive Disc Catalog Summer 2003)2003.??.??Catalog ISO:
2003.04.17
DX ISO: 2002.09.05
Japanese language only. The title screen has a subtitle that reads “Challenge version”. No cutscenes are included, however the intro movie plays after waiting on the title screen. This version has time restrictions, and the timer counts down instead of up. Otherwise this demo seems similar to the GC Preview Disc version except Sonic’s level is Speed Highway instead of Emerald Coast.

PC builds of Sonic Adventure DX (2004)

There are two distinct “base” versions of SADX PC – the original 2004 port and the “Dreamcast Collection” 2010 port. The 2004 port is where it gets really complicated as there were releases in different countries and the details on the actual differences are fuzzy. There are versions released in the UK, Germany, France, Spain, Italy, Hungary, Sweden, Australia, Israel, Brazil and Singapore, which may have minor differences. I know for sure the EXE in the Hungarian version is different from the “regular” European version. However, I must also say that the differences between these versions are so minor that almost all assets in sonic.exe are placed at the exact same addresses as the US version. One notable exception is the Korean version, which I have included as a separate entry in the table.

All versions of the 2004 port share the same features and downgrades. The 2004 PC port is based on the Gamecube port as it contains strings mentioning REL files. One interesting thing about the 2004 and later ports is that they use the blue water texture in Emerald Coast, which was used in prototypes but replaced with a green one in the final version on the Gamecube. The 2004 version uses WMA files for music and voices unlike the versions before and after it that use ADX. This port also abandons sequenced sound effects and switches to a different soundbank format containing raw PCM WAV files.

Title / CountryRelease dateComments
Trial Version B (Japan)2003.11.21Includes one level for Sonic, Tails and Knuckles. Unlike the Gamecube demo, this version doesn’t have colored banners in the character select screen and doesn’t play any cutscenes. The title screen plays a longer version of the main theme (normally heard in the main menu) on repeat.
Trial Version A (Japan)2004.02.??
(before 2004.02.03)
Includes a level for each of the six characters. Other than that it is the same as the B version.
Trial Version A (Global)2004.10.02Same as the Japanese demo A but in English.
Japan2003.12.18The earliest full release of SADX PC. Japanese is the default language, but all other languages are also supported. The title screen, the intro and the main menu background are always in Japanese. This version comes with SafeDisc copy protection and hasn’t been researched much.
US2004.09.14This is the version of SADX PC used for research and modding.
Europe (UK)2004.02.06
Multiple
Mostly the same as the US version except more advanced copy protection. There may be different protections (SafeDisc or SecuROM) in different releases. There was a protection-free re-release in “Sonic PC Collection” in 2009.
Korea2004.07.14A complete Korean localization of SADX PC, including all ingame dialogue, all menus and a colored manual. This version is unique in that it contains different assets translated to Korean, as well as various programming changes related to localization. It is also the only version of the 2004 PC port that has unique FONTDATA0.BIN and related structures in the EXE to support Korean. Voice language is English. Japanese voices are automatically replaced with English voices, although the actual files for Japanese are still included.

The new ports (2010 onwards)

In 2010 SEGA released a bundle for PS3 and X360 called “Dreamcast Collection”, which contains ports of several Dreamcast games including SA1/SADX. Although it is bundled as “Sonic Adventure”, the core game in these ports is based on the 2004 PC version of SADX. However, it does put back the original Dreamcast title screen with ripples. While they share almost all of the downgrades of the original 2004 PC version, for obvious reasons these ports have completely different rendering and sound systems that were developed by SEGA of China. They use shaders for character lighting and switch back to the ADX format for music and voices. Interestingly shaders and textures for water distortion are also included, which suggests that they were going to reintroduce Gamecube water effects, but there is no water distortion ingame. In addition, the soundbank format was revised, and sound effects switched from WAV to ADX.

These ports also introduce many additions wrapped around the original game’s systems, such as a texture replacement hook using DDS textures, support for achievements and online leaderboards, a different main menu system, new screens for credits, controls and tutorials, new fonts etc. Game Gear games are inaccessible (but still technically there), while Mission Mode and Metal Sonic are unlocked via a paid DLC.

This collection was also released on PC twice – in 2011 (physical) and 2016 (Steam). The 2016 version is known as “Dreamcast Collection Remastered”. Little is known about the differences between the 2011 and the 2016 versions, but on the surface they appear to be the same. The version of SADX currently available on Steam is the Remastered version. The Steam version comes with the DLC force enabled, and the Dreamcast title screen is inaccessible. If enabled via hacking, the DC title screen is a static image, although the model for the animated title screen is present in the binary.

These ports are the least researched and for the most part don’t present much interest. However…

X360 prototype builds

In 2020 several development builds of the X360 port were discovered, including a near-final build with debug symbols. The debug symbols have helped a lot in identifying assets and code in the PC version. I’m listing all known builds of the X360 version, including the final one.

Version IDBuild dateComments
362009.12.15The executable in this package is not the actual game, but some kind of X360 leaderboards and DLC test. Interestingly it does include shaders.
462009.12.28Same as above.
792009.12.30Same as above.
1042010.01.08This version is missing some features specific to the 2010 ports that would be implemented later, such as mipmaps (so in this build the game looks pretty much like the 2004 PC port), European language translations of CON_REGULAR_E.PVM and some logo screens before the game starts. The title screen is a static image, and the “Press Start” texture is from the Gamecube version.
This build has a different version of the image used for the 4:3 border.
1352010.01.22This build introduces the animated title screen, more logos and a new “Press Start Button” texture.
This version has a “Face recognizing” password screen which appears to be the developers’ attempt at a joke.
Password: Sonikudamoxi
This version is missing the 4:3 border image.
1472010.01.29
or 2010.01.30
This version introduces files SOC_FONTDATA0.BIN and SOC_FONTDATA1.BIN, although they are also referenced in Build 135 which doesn’t have them. These files are used for the subtitle font in the final version.
This version has the same 4:3 border as the final version.
Password: Sonikudamoxi
2092010.03.25 or 2010.03.26Introduces automatic mipmap generation and a new font for the file select screen, as well as French, German, Spanish and Italian translations of CON_REGULAR_E.PVM. In all previous versions of the game CON_REGULAR textures were only in English and Japanese.
Password: damoxifL
3872010.08.01No known differences from the final version. However, this build has a leftover “Test” folder that contains a PDB file with debug symbols, which makes it the most important prototype of the whole bunch.
Before this build, all assets that were originally in the DLLs in the 2004 version were compiled into the main executable. From this build onwards they are split from the main binary again.
3902010.??.??Final version.

If you own a rare version of the 2004 port, let me know! The Korean version was a big surprise and very interesting to look at. Maybe there are more unique versions out there?

Sonic Adventure DC-HD first release

Update 2024/06/29: This tool has been superseded by the Dreamcast Image Builder.

Sonic Adventure DC-HD is a new way to play the Dreamcast version of SA1 on the flycast emulator.

You can play SA1 with the following improvements:

  • The game runs at 60 FPS during gameplay without framerate-related glitches (hopefully).
  • Widescreen hack without model clipping or HUD stretching (some HUD stuff is offset though – this will be fixed eventually).
  • All videos can be skipped by pressing Start, not just the intro.
  • Cheat code to disable all cutscenes.
  • If you cannot run in a straight line with your controller/keyboard, there’s an optional patch for that.
  • Less choppy ocean in Emerald Coast (similar to Dreamcast Conversion for SADX PC).

Sonic Adventure DC-HD is distributed as a patcher program which you use on the original GDI of SA1 (US 1.005, animated title screen) to produce a patched version. It also comes with a cheat file that you need to load in flycast if you want to use the widescreen hack. Follow the instructions on the repo for more details.

This project is a work in progress. Not all features are complete and new features may be added in the future.

SA1 DC-HD has been tested on the standalone version of flycast on Windows and Android. The modified image is only meant to be used on the flycast emulator. 60 FPS and the widescreen hack will not work properly on other emulators or real hardware.

Skip All Cutscenes code for Sonic Adventure (Dreamcast)

This is a CodeBreaker code for SA1 US 1.005 that disables all cutscenes. It works exactly the same way as the “Skip All Cutscenes” code in SADX Mod Manager.

010496B4 0900

Cutscenes are removed by nopping the function call that starts the cutscene code, which makes the game assume the cutscene has finished playing. The address of the call is 0x8C0496B4.

There are a couple of small glitches when this code is used. For example at the start of Sonic’s story you can see Sonic in Station Square before the screen fades out and the fight with Chaos starts. This is how it’s actually programmed – the game loads Sonic into Station Square before initializing the cutscene. You can see it briefly when you start Sonic’s story without the code. A similar glitch happens in Station Square in Knuckles’ story.

There are some other potential applications for this code. For example, a conditional code could be made to activate cutscene skip when a certain button combination is pressed, and restore original behavior when it isn’t pressed. That way you could skip individual cutscenes by holding a button when the cutscene is about to play. It could also be made into a simple toggle. Of course it’s not as straightforward as simply pressing a button during the cutscene to skip it, but it’s still pretty good.

Sonic Adventure VMS + Chao Editor first release

Today I’m releasing a new tool based on the original SA1 DLC editor. This tool has the DLC editor integrated, but its functionality expands to cover more VMS files in SA1. Eventually I would like it to support all of the formats described here, but the highlight for today’s release is the inclusion of a new Chao editor.

Like the original DLC tool, the updated editor will be included in SA Tools, which also have a big update underway.
UPDATE: It’s been released and is now included in SA Tools.
The Chao editor is experimental and will be updated as more information on SA1 Chao data becomes available. There is no documentation for it at the moment, although the most important data should be self explanatory.

The Chao system used in SA1 is the least researched of all Chao games. There are several Chao editors for SADX and SA2, but the only Chao editor for the Dreamcast version of SA1 was Tyro’s VMU editor that requires running on an actual Dreamcast VMU or a VMU emulator, which I found inconvenient. Besides, there have been some updates regarding SA1 Chao data (for example we now have the full SA1 Chao data struct from SADX X360 symbols), and I wanted to make use of that new knowledge to help advance SA1 Chao research. Although several aspects of it are now known better, Tyro’s notes on SA1 Chao data were one of the most important sources of information for developing the editor. I would also like to thank the Chao Island member UltimaNumber, who kindly shared the bits of information I was missing and explained how SA1 Chao data works.

The tool can import all Chao VMS data. Data produced by the Japanese version is also supported:

  • SA1 Chao Garden save file
  • Download Data (Black Market Chao)
  • Chao Adventure (created when you take a Chao out for a walk)
  • Upload Data (created when you hold Y+A as the Chao goes in the transporter)

At the moment saving is only supported for Chao Adventure and Download Data, but you can export selected Chao from the garden save file as Download Data or Chao Adventure data. There’s also an option to export files with headers used by the Japanese version of SA1.

As Chao data is rather complex and the editor is experimental, there may be some bugs, especially with saving data. Also, expect UI changes in the future.

I’d like to thank Speeps for providing a screenshot of Buddy the Chao that I used as an icon for this tool.

Sonic Adventure Black Market Chao

The first Sonic Adventure on the Dreamcast had a Black Market just like the sequel. The archived version of the original website still has the pages and CGI scripts for it, as well as VMU files, which we’re going to look at today.

I didn’t access the Black Market back when it was online, but I’ve heard that the US version never worked because of some bug. The messages from Chao Doctor all the way to January 2000 mention that the Black Market was about to launch, and the comments in the CGI script used on the website suggest it was indeed broken at the time of archival:

The Japanese version was functional though, and it was possible to download several jewel Chao. The Ruby and Emerald Chao didn’t have any emblem requirement. It looks like they were given out “for free” to celebrate the Dreamcast’s US and EU launch anniversaries. However, according to this page, the Emerald Chao was released during an event “Magical Garden: Yume no (‘Dream’) Dreamcast Festival” that took place on March 27, 1999. I can’t find any other information on the event so I’ll have to leave it there for now.

The Amethyst Chao was unlocked when you had 100 emblems. The Sapphire Chao isn’t referenced in the pages or scripts but its VMU data exists. Apparently the US version was going to add a new “NiGHTS” Chao that would also cost 100 emblems. Although the NiGHTS Chao is referred to as “very special Chao”, it’s actually a regular Fly type Chao with animal parts rather than a unique character Chao, which SA1 doesn’t support anyway.

Chao downloads are stored in 8-block VMS files, and Japanese files have a different header although the data is compatible between all versions. There’s a script on the website (likely used for Chao daycare) to generate Chao VMS files, and it alternates between Japanese and US headers, which are stored as binary data on the website. The header is set up like a VMU game header, similar to Chao Adventure. Here are all the files found in the site’s archive:

DescriptionVMI fileScreenshotEmblem requirement
Emerald ChaoCHAO_EME0
Ruby ChaoCHAO_RUB0
Amethyst ChaoCHAO_AME100
Sapphire ChaoCHAO_SUF?
NiGHTS Chao (US only?)KNIGHTS100
Download all of them here

I’ve also made Chao Download data for BUDDY, the developer Chao mentioned in my previous post. Download it here to get it in your copy of SA1 DC.

List of VMU filename references in Sonic Adventure

There are a lot of mysteries about Sonic Adventure’s files on the VMU, some of which we’re going to unravel today. I’d like to also use this post to list known VMU filenames in SA1 for future research.

Let’s start with the better known stuff. The main save file is called SONICADV_SYS in the original Japanese release, and SONICADV_INT in all other versions. The newer versions contain text and voice language settings which aren’t available in the original Japanese version. Normally the Japanese version doesn’t load US/EU/International save files, and vice versa. However, the game will recognize the other version’s save file if you rename it.

Now let’s talk about Chao files. The main Chao save is called SONICADV_ALF and is compatible between all regions. When you take a Chao out for a walk using the VMU-shaped transfer machine, the game creates a file called SONICADV__VM on the VMU. This file contains the VMU game Chao Adventure with the Chao’s data written directly into the game file.

The filename SONICADV__VM was also used for Chao downloads from the website. In the Japanese version of the game you could download rare Chao (Sapphire, Ruby, Emerald) from the website if your main save file had a certain number of emblems. These are discussed in a separate post.

Upload Data

There’s also a bunch of files that are created on the VMU at certain points in the game. These files were meant to be uploaded to the official website using the game’s built-in web browser. Among such files were Chao, level clear times and results of DLC challenges. They contain an HTML page with a hidden field that contains encrypted data encoded as a Base64 string. The encryption is the same between these files and DLCs.

The Japanese version had different strings for the webpage so the embedded HTML is different from later revisions, also the Japanese version uses different filenames. Here are all of them:

Filename (JP)Filename (US/EU/INT)DescriptionHow to create
SONICADV_H00SONICADV_H07Chao Upload dataHold Y+A when a Chao is going into the transporter until you hear the ring sound
SONICADV_H01SONICADV_H04World Ranking DataHold Y+A on the file select screen until you hear the ring sound
SONICADV_H02SONICADV_H05Twinkle Circuit DataCreated automatically when you finish the DLC Twinkle Circuit course
SONICADV_H03SONICADV_H06Event Result DataCreated automatically when you finish a DLC challenge

Hidden Chao on SA1 US GD-ROM

Interestingly there are files SONICADV_H00.BIN and SONICADV_H04.BIN in the root folder of SA1 US GD-ROM. These appear to be earlier versions of the data produced normally by newer revisions of the game. Apart from using the Japanese version’s naming scheme they have some differences in HTML compared to the regular files. While it isn’t compatible with either version of the game, the interesting part is the actual data stored in these files.

The Chao file contains a baby Chao called ♥BUDDY♥ that was submitted by segaeigh@concentric.net. Yep, there’s been a Chao hidden on the game’s disc all these years. Here’s what it looks like:

Stats: Swim: 19 Run: 17 Fly: 17 Power: 27 HP: 13 Max HP: 17

Eventually you’ll be able to edit Chao upload and download data, including this file, as well as the main Chao save. I just need to get to writing a Chao editor for SA Tools.

Character Voice Packs

When one of these files is placed on the VMU, the game changes the character voicing the menu screens. The files themselves don’t have any meaningful data other than an icon, a description and a single string Team Andromeda. The game seems to set the voice mode based on the filename. Again, the Japanese version looks for different filenames, so there were actually 18 unique files for voice packs! Do we even have their Japanese versions archived?

Filename (JP)Filename (US/EU/INT)Description
SONICADV_V01SONICADV_V11Sonic’s voice
SONICADV_V02SONICADV_V12Tails’ voice
SONICADV_V03SONICADV_V13Knuckles’ voice
SONICADV_V04SONICADV_V14Amy’s voice
SONICADV_V05SONICADV_V15Gamma’s voice
SONICADV_V06SONICADV_V16Big’s voice
SONICADV_V07SONICADV_V17Dr. Eggman’s voice
SONICADV_V08SONICADV_V18Tikal’s voice
SONICADV_V09SONICADV_V19Random voice

Events and Challenges

A lot has been written about SA1 DLCs, and they are now fairly well understood, up to the point that you can make your own DLCs that will work on an actual Dreamcast without hacking the base game. So here I’m going to talk about things that are a but more obscure.

One major limitation of the DLC system in SA1 is that you can only have one custom model. While I haven’t been able to get the game to load more models, I got it to load a model that isn’t stored in the DLC file by editing the pointer in the DLC file’s model binary to make it point to a different location in memory. It’s still just one model per DLC and you have to supply its textures separately but at least you can load stuff outside of the DLC file if you really want to. Maybe it’s possible to add more pointers and make the game load them somehow? I’ll look into that sometime soon.

https://cdn.discordapp.com/attachments/446023672147345420/753894751509413910/unknown.png

The filenames for the DLCs are SONICADV_aaa, where aaa is a number from 000 to 999. IDs from 000 to 200 are reserved for DLCs that only have text in Japanese. Early events released in Japan (Famitsu challenge, QUO challenge etc.) only contain Japanese message strings, and their string table is smaller compared to later events that had text in other languages. However, these old events still work with newer versions of SA1 with Japanese text displayed correctly regardless of the game’s language setting. The game doesn’t load strings for other languages if the DLC ID is lower than 200. This is why there is a gap between Japanese and international event filenames: the last Japan-exclusive event was called SONICADV_003 and the first international event was called SONICADV_501 (though SONICADV_200 would’ve worked too).

The Weird Stuff

The game’s main binary has several filename strings that suggests some interesting functionality. Earlier this year we learned from Exant’s fascinating discovery that we can still activate the game’s built-in lighting editor that looks like this:

Image

Apparently this editor can load lighting files from the VMU, and that functionality seems to be still in the game, we just need to learn how to activate it. The palette file is supposed to be called SONICADV_P00, and the SL file is SONICADV_S00 (in the Autodemo they’re just PL_ and SL_). It’s possible that numbers other than 00 were also used. There is a function loading these files at 0x8C011D46 (US 1.005). It also seems like LANTERN_PALETTE and LANTERN_SOURCE were VMS titles, while LANTERN/パレット情報 and LANTERN/環境情報 were VMS file descriptions. I’ll experiment with custom VMS files to see if the game picks them up.

There are also some strings suggesting there was VMU to PC transfer at some point. The filenames used in that transfer were SONICADV.VMS and SONICADV.DL0. Doesn’t look like it’s used, but who knows, maybe we’ll recover it eventually.