Translating a Shenmue One game
"He shall appear from a far Eastern land across the sea. A young man who has yet to know his potential. This potential is a power that can either destroy him, or realize his will. His courage shall determine his fate. The path he must traverse, fraught with adversity, I await whilst praying. For this destiny predetermined since ancient times... A pitch, black night unfolds with the morning star as its only light. And thus the saga, begins..."
This first chapter of Shenmue kicks off Yu Suzuki's cinematic Dreamcast tour-de-force, an exploration-heavy adventure that has players immerse themselves in Yokosuka, Japan. Players slip into the role of a young martial artist named Ryo Hazuki, who is on the trail of his father's killer. On the way, players must talk with hundreds of characters, engage in martial arts battles, and marvel at the realistic depiction of the Japanese coastal town.
This first chapter of Ryo Hazuki's tales was only released in Dreamcast around the world, unlike Shenmue II; which only saw the light of day in Xbox in the United States.
Before starting, please check the prerequists.
Subtitles in cinematics
In the game data folder, go to the \SCENE\<DISC_NUMBER>\STREAM\ directory.
You'll see a lot of AFS and IDX files. Each AFS contains cinematics game datas, which means a SRF file (to be opened by Cinematics Subtitles Editor) and some STR files (You can listen to them with the ADPCM Streaming Toolkit included in the Shenmue Translation Pack).
Unpacking the cinematics game data
The whole example is based on the A0114.AFS file from the Disc 1 (it's the first game scene, the death of Iwao Hazuki).
- Run AFS Utils and select the File > Open files... command.
- Select the \SCENE\01\STREAM\A0114.AFS file and click OK.
- Select the A0114.AFS on the left.
- Click on the Tools > Mass extraction... menu item.
- Select the output folder and press OK! The A0114 directory'll be created in the output folder, this directory'll contains each file contained in the AFS file.
- You have succesfully unpacked the intro scene files. Great job!
If you use a pirated version of the game, you won't see the original files name in the archive. SO PLEASE DON'T USE PIRATED VERSIONS OF THIS GAME. You'll unable to recongnize SRF or STR files.
Translating SRF file
To edit SRF files it's pretty simple. Open the Cinematics Subtitles Editor tool and select the File > Open files... command. Open the SRF file you want to translate and press OK.
You can modify the in-game cinematics subtitles in the window. To help you press the F3 key to open the previewer. When you have finished, don't forget to save your work!
After hacking our SRF file, the next step is to rebuild the original AFS file.
Rebuilding our AFS file
This is based on the A0114.AFS example file again. You should have modified the SRF file which contains the cinematics subtitles. Now, we must rebuild the AFS file with the updated SRF file. To do that, do the following:
- Fire up AFS Utils and select the Tools > AFS Creator command.
- In the AFS Creator window, select the File > Import XML list... and click OK.
- Select the generated A0114_list.xml in the A0114 directory, and click OK.
- The AFS Creator window should be filled with the original A0114.AFS filenames content.
- Select the File > Save Afs... option... Done!
You can use the Tools > Mass creation... item to generate lot of AFS files.
Rebuiding the IDX file
Now we have an updated AFS, everything is ready to make the correct index file (IDX). You should keep a copy of the original AFS and IDX files in order to create the new files. To do that, it's pretty simple (A0114.AFS is again the example file):
- Launch IDX Creator.
- In the Select the game to generate the proper IDX format, select Shenmue I.
- Select the Create with template box, and then select the original A0114.IDX and A0114.AFS files.
- For the Modified AFS field, choose the updated A0114.AFS file.
- The IDX field will be automatically filled, but you can change the file location if you want.
- Press the Go! button.
You finally have an updated AFS and IDX! Just copy these in the \SCENE\01\STREAM\ directory and run the image creation for the Dreamcast.
You can use the console version of IDX Creator to generate a lot of IDX files.
You can now skip to the next step, translating subtitles in the Free Quest mode!
Subtitles in Free Quest mode
In the game data folder, go to the \SCENE\<DISC_NUMBER>\NPC\ directory and locate the HUMANS.AFS file, as well as FREE<DISC_NUMBER>.AFS and FREE<DISC_NUMBER>.IDX files.
To translate NPC characters speechs in this version of the game, you need to edit the .SRF files located inside the FREE<DISC_NUMBER>.AFS and FREE<DISC_NUMBER>.IDX, but these subtitles don't have the correct order, so the best way to translate this is using the HUMANS.AFS file. The associated index file (HUMANS.IDX) is NOT needed.
In clear, in Shenmue One Engine games, Free Quest subtitles are in duplicates places:
- FREE<DISC_NUMBER>.AFS, which are the subtitles read by the game but much difficult to translate (because without context);
- HUMANS.IDX, the subtitles contained here aren't used by the game but it most easier to translate from there because subtitles are in the correct order.
We'll see in this tutorial how to import datas from HUMANS.IDX to the proper FREE<DISC_NUMBER>.AFS file.
- <NPC_CHARID>.PKF: Contains textures data (in PVR) for the model (face and body) ;
- <NPC_CHARID>.PKS: Contains the NPC model itself, some unknow data, datas for face morphing and of course, the subtitles table for this NPC.
A Character ID is always composed by a 4 chars code (like AKMI).
The HUMANS.IDX is a special index file containing all Characters ID (CharID) and the size of each PAKF file. We don't need to modify PAKF files so you don't need to generate another HUMANS.IDX file.
Unpacking the Free Quest subtitle containers
The first thing to do is to extract all the subtitles from the Disc 1's FREE01.AFS file (Contains all the subtitle files for the NPCs on Disc 1). To do that, do the following:
- Run AFS Utils and select the File > Open files... command.
- Select the \SCENE\01\NPC\FREE01.AFS file and click OK.
- Select the FREE01.AFS on the left.
- Click on the Tools > Mass extraction... menu item.
- Select the output folder and press OK! The FREE01 directory'll be created in the output folder, this directory'll contains each file contained in the AFS file.
- You have succesfully unpacked the Disc 1 Free Quest files. Great job!
IF YOU USE A PIRATED VERSION OF THE GAME, YOU WON'T SEE THE ORIGINAL FILES NAME IN THE ARCHIVE, SO PLEASE, DON'T USE SUCH VERSION. |
Unpacking the HUMANS.AFS archive
Next, you have to extract all the NPC datas from the HUMANS.AFS file. You only need to unpack one HUMANS file from any of the discs, as it contains all the subtitles of the entire game.
- Run AFS Utils and select the File > Open files... command.
- Select the \SCENE\01\NPC\HUMANS.AFS file and click OK.
- Select the HUMANS.AFS on the left.
- Click on the Tools > Mass extraction... menu item.
- Select the output folder and press OK! The HUMANS directory'll be created in the output folder, and will contain each file packed in the HUMANS.AFS file.
- You have succesfully unpacked the HUMANS.AFS file. Well done!
If you use a pirated version of the game, you won't see the original files name in the archive. SO PLEASE DON'T USE PIRATED VERSIONS OF THIS GAME.
Translating a NPC character speech
You have successfully located the HUMANS.AFS archive? Great! So you can now translating NPC characters. To do that, you'll need Free Quest Subtitles Editor.
A lot of text is identical so to accelerate the translation you can if you want use the Global-Translation (allowing you to translate identical text in one time, using a very fast module) or the Multi-Translation (it's a little more slow but you can translate in the original context). Try them both to choose your prefered version.
You can take the INE_.PKS file for the example. This is the subtitle sheet for Ine Hayata ("Ine-san"), who is always at Hazuki Residence. After the game intro and getting the first allowance, you can find her here:
- Run the Free Quest Subtitles Editor. If a window pop ups to inform you a newer version of the hacking algorithm, you can close it (I think that you never have used old versions of this editor).
- Click on the File > Open files... command and select the INE_.PKS file in the list.
- The file will be opened on the editor. You can now edit your subtitles. Don't forget to save your file!
You can open the whole directory by clicking the File > Open directory... command. The program'll be scan every file to find valid NPC characters. With this functionnality you can edit multi files in the same time.
Copying the translated subtitles to the SRF files
After you translated the characters, you need to export all the contents to the .SRF files located at the FREE
- Run Free Quest Subtitles Editor and open all the contents inside the HUMANS folder.
- Click on the Tools > Batch Cinematics script... menu item.
- Select the target directory where the exported .XML files will be generated.
- Select the disc you are going to export (Disc 1).
- Click on the Generate button.
- After all Disc 1 .XML files are generated, click on the Done button, then close the Free Quest Subtitles Editor.
- Run Cinematics Subtitles Editor and open all the .SRF files inside the FREE01 folder.
- Click on the Tools -> Batch import... menu item.
- Select the folder where you exported all the .XML files.
- Click on the Import button.
- If the .XML files have the "_srf_discX" filename, the Import process won't work.
- If the process works correctly, you should see a window saying "119 file(s) successfully imported. 8 erronous file(s).
These eight files mentioned are subtitles that are not inside the HUMANS file, so you'll need to edit them via the Cinematics Subtitles Editor.
Repacking the FREE<DISC_NUMBER>.AFS
The last step is repacking the FREE01.AFS file with our hacked subtitle files. You can do this with AFS Utils or if you have only one file to replace, with AFS Explorer.
After creating new FREE01.AFS, don't forget to create a new .IDX file WITH TEMPLATE. Otherwise, the process won't work and you won't be able to hear the voices, plus the subtitles will be read from a different file. Copy both .AFS and .IDX files it on the \SCENE\01\STREAM\ directory and run the image creation process.
Run the game and talk to Ine-san... Good job, you made it!
You can translate every NPC from every disc now! Good luck!
Translating the graphics of the game
Right now we are going to cover the basics of editing .PVR textures. The .PVR format is the Dreamcast standard format for texturing everything. The best option to edit this textures is by using Adobe Photoshop and the PVR Photoshop plugin found on the Sega PVR Tools package. Copy the pvrtex.8bi file to your Adobe Photoshop/Plug-ins/ folder and you'll be able to open and create .PVR textures.
If you are using Windows Vista or Windows 7, it's very likely that you will have two Photoshop versions: 32-bit and 64-bit editions. In that case, the plugin will only work on the 32-bit version, so copy it to the Program Files (x86)/Adobe Photoshop/Plug-ins folder.
Keep it mind that when you save the loading texture, you must keep the original flags for the file: The Texture Type (Except the main menu and options, most of the case will be either VQ3 or VQ4), Pixel Format (Picks up a way to show alpha channels), Mipmaps (99% of the time will be NO).
All the textures are flipped, so it's a wise option to flip them in Photoshop, save the PSD, and when you export to PVR, turn on the Flip Box to re-flip the textures automatically.
Also, almost every texture has an alpha channel that you'll need to edit as well.
Almost the 99% of the .PVR textures are located inside container files. The following steps will guide you through the most important ways to do this.
Sprite files (Menus, loading areas...)
.SPR files are containers that only have .PVR files inside. Some of these files have GZIP compression so their filesize is smaller, some don't. You have to keep the final product as compressed as the original is.
For this example, we are going to edit the Main Menu screen.
These tools are needed for this menu:
In this case, because the file is compressed with .GZ, we have to decompress it before we are able to work with it.
- Decompress the TITLE4_E.SPR with WinRAR, WinZip or 7-zip.
- Run SPR Utils and open the TITLE4_E.SPR.
- Click on the Tools > Mass extraction... menu item.
- Select the output folder and press OK! The TITLE4_E directory'll be created in the output folder, and will contain each file packed in the TITLE4_E.SPR file.
- You have succesfully unpacked the TITLE4_E.SPR file. Well done!
If you want, you can open all the .SPR files inside a folder by clicking on the File -> Open directory menu item. Keep in mind that this option will not see the .GZ files. This tool will be updated later to support .GZ files properly.
Now, inside the folder, you should see plenty of .PVR files. If you have already added the PVR plugin to Photoshop, you can associate Adobe Photoshop to the .PVR files, so you only need to double click them in order to see them.
*NOTE: For Vista/7 users, the association will always load the x64 version of Photoshop so it's best to open the files using the x86 version of Adobe Photoshop.
Edit the files you need to edit. When you are done, it's time to repack them.
- Run SPR Utils and click on the File > New menu item.
- Open the .XML file that it's with the .PVR files.
- Make sure Tools > Rewrite PVR global index at creation is activated.
- FOR .GZ FILES ONLY: Activate Tools > GZip output file at creation.
- Save your new .SPR file.
Now you only need to copy the new file to your SPRITE folder and run the image creation process.
The files you need to edit are the following:
Folder | File Name | Description |
---|---|---|
/MISC | BATTLE.GZ | Has a graphic where it asks you to save the 70 Person Free Battle time. |
/MISC | BATTLE_E.GZ | Same as above - BATTLE.GZ. |
/MODEL/ITEM | WAZAHYOU.SPR | Contains three graphics from the Move Scroll/Training screen. |
/SPRITE | COMICON.SPR | Contains the HUD textures, like the HELP button, or the PRACTICE screen. |
/SPRITE | DISCCHGE.SPR | Disc change screen. |
/SPRITE | LAPTIME.SPR | Forklift races/Bike race. |
/SPRITE | LDXXXXXX.GZ | All the files that start with "LD" are Loading screens, the text of the city or the shop you are about to enter. The game will only read the .GZ versions, not the .SPR versions that are also included in each disc. |
/SPRITE | LOADNUM.SPR | The common graphics on the Loading screen, like the day of the week and the month names. |
/SPRITE | NOVM_E.SPR | No VMU inserted screen. |
/SPRITE | OPTION_E.GZ | Options/Load game screen. |
/SPRITE | RESUMEXE.SPR | All the graphics related to loading a game or loading the Resume File. |
/SPRITE | STAFF_S.GZ | Staff roll screen. |
/SPRITE | SYUGYOU.SPR | Training moves/Move Scroll screens. |
/SPRITE | TITLE4.GZ | Main menu screen. |
/SPRITE | TNPUSH_A.SPR | "Press A Button", found when you load the 70 people Free Battle Time Trial. |
/SPRITE | TVCHECK.SPR | Part 1 of the 50/60Hz selector. |
/SPRITE | TVTXT_E.SPR | Part 2 of the 50/60Hz selector. |
/SPRITE | TXT_XX_E.SPR | Contains various warnings related to the video mode. |
MT5 (Models) files (Ingame maps, items...)
Shenmue I's models are contained inside .MT5 files, which have both geometry and textures. For this purpose, you will need this:
Editing these files is easy as pie. For this example, we are going to look on the SCENE/01/D000 folder, on Disc 1.
- Run Models Textures Editor and open all the .MT5 files inside the SCENE/01/D000.
- Pick one of the models from the list on the left.
- Hit the F3 key to see a preview of the textures you are seeing.
- Check the textures on the right side to see which ones need translation, then Export them.
- When you are done editing the texture, select the one you want to change and hit the Import button. The program will ask you which is the texture you want to replace.
- Save the new model file. Easy!
The following MT5s contain graphics that need to be translated:
Of course, when you see 'SCENE/XX/SOMETHING' in the array below, XX stand for the disc number, for example, 01.
Folder | File Name |
---|---|
MODEL/ITEM | RMPS500G.MT5 |
MODEL/ITEM | WRKS511G.MT5 |
MODEL/ITEM | WRKS521G.MT5 |
MODEL/ITEM | WRKS531G.MT5 |
MODEL/ITEM | WRKS541G.MT5 |
MODEL/ITEM | WRKS551G.MT5 |
SCENE/XX/D000 | B01MP01G.MT5 |
SCENE/XX/D000 | B01MP02G.MT5 |
SCENE/XX/D000 | B01MP03G.MT5 |
SCENE/XX/D000 | B01MP04G.MT5 |
SCENE/XX/D000 | B01MP05G.MT5 |
SCENE/XX/D000 | B01MP06G.MT5 |
SCENE/XX/D000 | B01MP07G.MT5 |
SCENE/XX/D000 | BSPK3T1G.MT5 |
SCENE/XX/JD00 | B14A0M1G.MT5 |
SCENE/XX/MBQC | MAP05.MT5 |
SCENE/XX/MBQC | MAP07.MT5 |
SCENE/XX/MC5Q | MAP07.MT5 |
SCENE/XX/MFSY | BEYI201G.MT5 |
SCENE/XX/MFSY | BEYI202G.MT5 |
SCENE/XX/MFSY | BEYI203G.MT5 |
SCENE/XX/MFSY | BEYI204G.MT5 |
SCENE/XX/MFSY | BEYI205G.MT5 |
SCENE/XX/MFSY | BEYI206G.MT5 |
SCENE/XX/MFSY | BEYI501G.MT5 |
SCENE/XX/MFSY | BEYS701G.MT5 |
SCENE/XX/MFSY | BEYT102G.MT5 |
SCENE/XX/MFSY | BSPK3T2G.MT5 |
SCENE/XX/MFSY | MAP05.MT5 |
SCENE/XX/MFSY | MAP07.MT5 |
IPAC (PKS) files (Other stuff...)
There's some files that contain UI graphics and the map thumbnails, called PKS files. Inside these you will find either .SPR graphics, or .PVR ones. For this purpose we're going to split this section in both cases.
For the .SPR example, we are going to modify the "Now Loading" message at loading screen.
This operation is really easy to do. Follow the guide.
- Open IPAC Browser and select the MISC/TEXTURES.PKS file.
- In the IPAC Browser view, extract the LD_NL.SPR entry. To do that, right-click on the LD_NL.SPR, then select the Export... command.
- Run SPR Utils, then select the previous extracted LD_NL.SPR file.
- In the SPR Utils window, extract the only texture contained in this SPR package: the "loading" texture.
- You can now edit the loading.pvr file.
After doing this you must repack the loading.pvr with SPR Utils, then update the MISC/TEXTURES.PKS with IPAC Browser.
The following files are IPACs with .SPR files inside:
Folder | File Name | Description |
---|---|---|
MISC | COLD.BIN | Exists multilanguages files - check below. |
MISC | COLD_X.BIN | The 'X' stands for the BIOS language of your Dreamcast - (E)nglish, (F)rench, (G)erman or (S)panish. Default is COLD_E.BIN, but can be COLD.BIN - to be confirmed. |
MISC | TEXTURES.PKS | N/A |
For the .PVR version, right now the IPAC Browser doesn't display these .PVRs right, so we'll need to rip our way through.
The following files are IPACs with .PVR files inside:
Folder | File Name |
---|---|
SCENE/XX/D000 | MPK00.PKF |
SCENE/XX/JD00 | MPK00.PKF |
SCENE/XX/MFSY | MPK00.PKF |
SCENE/XX/MKSG | MPK00.PKF |
SCENE/03/MA00 | ALLMAP.PKF |
SCENE/03/MA00 | ASSA.PKF |
SCENE/03/MEND | BUSAUTH.PKF |
Additional resources
In bonus, you can download some documents related to Shenmue modification:
Name | Author | Version | Description | Source |
---|---|---|---|---|
Shenmue Saves Pack | IlDucci | 2012-06-03 | This saves pack allow you to translate the game more easier. It contains several checkpoints to test your translation. | - |
Shenmue Japanization Guide | Shensoul | 0.8.3 | This very complete guide was written in order to provide a complete and illustrated tutorial about how to 'japanize' the PAL version of Shenmue. | Go |
How to translate Shenmue 1 ! | Hiei- | 2008-08-01 | This (very) outdated guide can be useful on some points. | Go |
Credits
This guide was initially written by IlDucci.
Corrections done by SiZiOUS.