Skip to content

About

Python-only disc extractor for Xenosaga Episode III: Also sprach Zarathustra (PS2, USA, SLUS-21389): textures to PNG, audio to WAV, movies to MP4, MIPS disassembly, data dictionary of every file type, local web GUI. Beta, testers welcome.

Topics

Resources

Security policy

Stars

3 stars

Watchers

0 watching

Forks

Latest commit

 

History

46 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Xenosaga III Python Extractor

Open up Xenosaga Episode III: Also sprach Zarathustra (PS2) on your computer. Look at the characters in Blender, listen to the soundtrack, read every line of the script, recolour a character, or translate the whole game into your own language, even one written in an alphabet the game never had.

KOS-MOS and Shion walking: the kit's .glb files, animated with clip 1 of each character's field motion, rendered in Blender A Hindi subtitle over the opening movie, drawn by the game in PCSX2 from a font the kit rebuilt Arabic in a scene dialogue box, joined and right to left, PCSX2 capture
KOS-MOS and Shion, taken out of the game
with their own animation, shown in Blender
Hindi subtitles on the opening movie
(PS2 emulator, a disc the kit made)
The game speaking Arabic, letters joined, right to left
(a disc the translation editor built)

What is this?

A free toolkit that reads your own copy of the game and turns what is inside into ordinary files: 3D models for Blender, pictures in their real colours, music and voices you can play, movies, and the game's text as plain text you can edit. When you change something, the kit writes new copies of the discs with your change in them. It checks every byte it wrote, and it never touches your originals.

Bring your own discs. The kit contains no game data. It reads the USA discs (SLUS_213.89 / SLUS_214.17), the Japanese discs (SLPS_256.40 / 256.41) and the May 2006 press prototype. Every picture and sound on this page was made by the kit from the retail discs, or captured from the game running in PCSX2 (the PS2 emulator) from a disc the kit changed. Nothing is retouched.

An AI project, made for people. This kit was built with the help of AI, and its whole purpose is to make human work possible: your own translations, mods, art, videos and research. The goal is for more people to do more things with Xenosaga, and to carry it to every corner of the world in their own languages. It is not here to replace translators with machine translation. AI projects don't have to be anti-human; this one is for the people who love the game.

This kit has two siblings, built the same way: Episode I and Episode II.

Beta: feedback wanted. Please tell us what breaks, on the issues page. Reading is tested on all five disc images. Discs written by the kit have been played in the emulator in English, Arabic, Hindi, Amharic, Georgian, Japanese, French, Spanish, Chinese, Cherokee, Korean, Russian and N'Ko, plus a recoloured character. Not played yet: Disc 2 and the disc swap, the Japanese discs, the prototype, imported pictures and the battle-screen letters. docs/UPDATES.md says exactly what was tested.

Contents: Getting started · What you can do · Models · Animation · Changing textures · Translating the game · Another alphabet · Audio samples · Movies, fonts and menus · The window · Other discs · Good to know · All the guides

Getting started

The easy way on Windows: download the app. From the latest release, download Xenosaga3-Extractor-X.Y.Z-win64.zip. Everything it needs is inside. Right-click it, choose Extract All, open the folder and double-click gui.exe. The first time, Windows may say "Windows protected your PC", because the app is not signed by a paid certificate. Click More info, then Run anyway (why it warns).

On a Mac or Linux, install Python 3 and double-click launch.command (Mac) or launch.sh (Linux); the first time you need to make it runnable with chmod +x. docs/INSTALL.md has the steps for every system, including Python on Windows.

The app opens as a page in your web browser that only your own computer can see. It finds your disc images by itself, tells the USA, Japanese and prototype discs apart, and shows one card per command (more below). A good first run: region (which version each disc is), then dump, then browse. Then open the browse folder it made.

Just want to translate? Double-click translate.command (Mac), translate.bat (Windows) or translate.sh (Linux), and the translation editor opens on its own. More in Translating the game.

From a terminal

With Python 3.9 or newer:

python -m pip install -r requirements.txt     # once: numpy, Pillow, capstone, fonttools, uharfbuzz
python cli.py region --iso "Disc 1.iso"
python cli.py dump   --iso "Disc 1.iso" --iso "Disc 2.iso" --out out/
python cli.py browse --dump out/dump --stage out/stage --out out/browse

python cli.py <command> --help explains any command, and python cli.py self-test runs every check the kit has. ffmpeg is used for sound and movies. Every command, and the kit's older 7-Zip pipeline, are in docs/MANUAL-PIPELINE.md. What browse writes, folder by folder: docs/BROWSING.md.

What you can do

What you get Read more
Open the models in Blender every model on the disc (1,609 per disc: characters, weapons, E.S., rooms) as 3D files with their textures and a posable skeleton; blend even writes a ready-made Blender file BLENDER, MODELS
Watch them move the game's own animations attached to the models: all 5,039 clips per disc read MOTION
Look at the textures every picture painted on the models, maps, effects and menus, as PNG, in the colours the game draws them BROWSING
Recolour a character change a character's colours in every copy on the disc, seen working in the emulator MODDING-CHARACTERS
Translate the game every line of both discs in one page, checked as you type, built into playable discs with one button; 382 languages to choose from TRANSLATING-GUIDE, LANGKIT
See a line in the game press ▶ In game on a line: PCSX2 starts on your patched discs at a checkpoint just before that scene (checkpoints are recorded while you play) TRANSLATION-EDITOR
Use a new alphabet Arabic, Hindi, Chinese, Korean, Amharic, Georgian… drawn into the game's own font, and Japanese on the USA discs SCRIPTS, FONT
Edit the text by hand scenes, menus, the encyclopedia, battle messages and subtitles as plain UTF-8 files, and back into both discs TRANSLATING
Read the script in order every line the scenes show, in play order, with speakers, choices and a sound file for each spoken line DIALOGUE
Hear the soundtrack the 120 music tracks (3.31 hours) as WAV, with their loop points; voices and sound effects too MUSIC
Movies and pictures the cutscenes as MP4; 1,131 menu pictures and illustrations as PNG, and back BROWSING
Replace any file swap any file on the disc for your own, in copies of one disc or both; a file that grows is moved to the end of the disc REPACK
The Japanese release read like the USA discs, and lined up with the English script side by side below

Models

Every model on every disc converts. Characters come out with their skeleton; maps keep their moving parts (ships, rubble, crystals). Each picture below is one command and a Blender render, nothing touched up.

Playable characters

KOS-MOS Shion Jr. MOMO chaos
KOS-MOS Shion Jr. MOMO chaos
Ziggy Jin Allen Canaan Miyuki
Ziggy Jin Allen Canaan Miyuki

Notable NPCs

These are captioned with the disc's own file names.

virhelm00 telos00 mary00 shelley00 marglis00
virhelm00 telos00 mary00 shelley00 marglis00
pelegri00 nephilim00 sergius00 yuriev00 albelt00
pelegri00 nephilim00 sergius00 yuriev00 albelt00

E.S.

M3asher01 M3zebulun01 M3reuben01
M3asher01 M3zebulun01 M3reuben01

Environments

E3_CIT01
E3_CIT01
E3_SYU01
E3_SYU01
E3_KYM02
E3_KYM02
E3_ELS05
E3_ELS05
E3_KYO06
E3_KYO06
E3_HOS01
E3_HOS01

The maps are seen from above at an angle, with the sky and the outside of the walls hidden so you can see into the rooms.

Try it: in the app, the models card writes every model, model writes one, and blend turns one into a Blender file that opens textured and framed.

python cli.py browse --dump out/dump --stage out/stage --out out/browse --kinds models   # all of them, with their animation
python cli.py model --iso "Disc 1.iso" --path 'mdl\chr\pc\C3kosmos00.chr' --out kosmos.glb
python cli.py blend --glb kosmos.glb --render kosmos.png

How to open them in Blender, and what to expect: docs/BLENDER.md. How the models work: docs/MODELS.md.

Animation

KOS-MOS playing battle clip 21: a leap, a crouching slash, a lunge and the recovery

The game's animations come out too. Every body and face animation on every disc becomes an action in Blender, attached to the character's skeleton, so you can press play. A character's own animations are attached automatically.

On the right, KOS-MOS plays battle animation 21: a leap, a crouching slash, a lunge and the recovery. At the top of the page, KOS-MOS and Shion play a field animation that looks like walking, and below, KOS-MOS turns once while standing ready. The game does not name its animations, so "walk", "attack" and "stance" are just what they look like.

Two things to know: hair and coats stay stiff, because the game moves them with a physics simulation the kit does not have yet; and nobody has compared the animations side by side with the running game yet.


KOS-MOS turning once while playing battle clip 0, a stance-like loop

python cli.py model --iso "Disc 1.iso" --path 'mdl\chr\pc\C3kosmos00.chr' \
       --out kosmos.glb --motion 'pac\bat\C3kosmos00.sme#0,21'
python cli.py motion --iso "Disc 1.iso" --sweep     # read every animation on the disc

How the animations were decoded and checked: docs/MOTION.md.

Changing textures

Shion in the Vector S-Line hall, retail (left) and with her hair recoloured by chr-iso-sweep (right), PCSX2 captures

Change a character's colours everywhere they appear. The game keeps many copies of each character on the disc; chr-iso-sweep finds and recolours all of them. On the right is Shion in the Vector S-Line hall, as the game ships and after a warm recolour, both captured in the emulator from the same save.

You can also do it by hand: chr-decode turns every texture of a model into PNG, chr-palettes exports its colour list as a little swatch picture you can repaint, and chr-import-palettes puts your colours back.

Below, KOS-MOS from the retail disc and from a copy recoloured blue, shown in Blender after taking her back out of the copy. The blue filter changes her blue armour trim as well as her hair, so look at the result before you recolour a whole disc. Step by step: docs/MODDING-CHARACTERS.md.


KOS-MOS from the retail disc (left) and from the recoloured copy (right), rendered in Blender

Textures in their real colours

Many of the game's menu pictures share one picture file and pick their colours from the game's own drawing code. The kit reads that code, so icons, portraits, gauges and the title menu come out the way the game draws them.

UI sheets before and after the XTX fix: the top half is the old sepia ramp read 16 pixels off, the bottom half the corrected decode with per-picture palettes

Top: what earlier versions produced. Bottom: each icon, thumbnail and portrait with its own colours.

Window sheets, titleobj and the minigame sheet before and after binding palettes from the game's own draw code

Field map textures Effect textures
Field map textures Effect textures

Translating the game

The translation editor is the easy way, for any language. Open it, pick your discs and a language, and type. It shows every line of both discs, grouped the way you meet them in the game, checks each line as you type, and shows how it will look in the game's own font. Press Build and you get copies of Disc 1 and Disc 2 that play in your language. No programming needed.

  • 382 languages to choose from. French works with nothing to set up: the three letters the font lacks (œ Œ Ÿ) are added at the size of the game's own letters.
  • Whole new alphabets (Arabic, Devanagari, Cherokee, Chinese, Korean…) are drawn into the game's font from a font on your computer. For large alphabets the build opens the font's kanji rows, which hold thousands of letters. Arabic and the other joining scripts are drawn joined.
  • Dialogue gets a width guide taken from the game's own window code, and Wrap to fit breaks long lines for you.
  • Its builds have been played in the emulator in French, Spanish, Korean, Hindi, Chinese, Cherokee, Russian, Arabic and N'Ko.
The Settings menu in French, drawn by the game in PCSX2 from a disc the editor built A Spanish line in the first cutscene's dialogue box, PCSX2 capture
French menus, in the game A Spanish cutscene, in the game
The translation editor: the opening scene being translated into French, with a preview of the original and the translation drawn with the game's own font
The editor: every line of both discs grouped the way you meet them, checked as you type, and previewed in the game's own font
Language setup: Arabic, fonts that have every letter, and a test line drawn right to left Traditional Chinese in the first dialogue box, PCSX2 capture of a disc the editor built
Setting up a new alphabet Traditional Chinese, in the game
Korean in the opening scene's dialogue box, PCSX2 capture of a disc the editor built N'Ko in the opening scene's dialogue box, right to left with the letters joined, PCSX2 capture
Korean, in the game N'Ko, joined and right to left

Start here: the beginner's guide, step by step. A tour with more pictures: docs/LANGKIT.md. Every detail of the editor: docs/TRANSLATION-EDITOR.md.

To open it: the Translation editor button in the app, or translate.command / .bat / .sh. Translators can also download it on its own, as Xenosaga3-Translation-Editor-<version>-win64.zip, from the next release on (or build a Mac app with python build.py --editor).

Prefer plain text files? text-export writes every line the game shows (scenes, menus, the database, battle messages, movie and event subtitles) as UTF-8 files you can edit in anything, and text-import writes them into copies of both discs, refusing anything the disc's font cannot show (docs/TRANSLATING.md).

Translating into another alphabet

The USA game only knows Latin letters. To show another script, the kit draws the letters your translation needs into empty slots of the game's own font, then writes your text using those slots. It handles the hard parts for you: letters that change shape when joined, right-to-left lines (checked against ICU, the standard library for this), and line wrapping. Several scripts can share one disc. These are all pictures of the game drawing them in the emulator:

Hindi (Devanagari, conjuncts and vowel signs) in a scene dialogue box Arabic: the "story so far" screen, right to left
Hindi in a scene's dialogue box Arabic on the "story so far" screen
Amharic: the save screen's title, the overwrite prompt and Yes/No Georgian: the "story so far" screen
Amharic on the save screen Georgian on the "story so far" screen
Japanese on the USA disc with --unlock jp: the field menu's first entry and help line A location caption in Hindi over the real-time opening
Japanese on the USA disc, with letters borrowed from the Japanese font A Hindi place name over the opening

Hindi, Amharic and Georgian were put on one disc together (87 new letters) and play together. The whole procedure: docs/SCRIPTS.md; how the game's font works: docs/FONT.md.

Audio samples

Press play. These came out of the kit, from the retail discs. Episode III's music is recorded, not sequenced, so the songs are the game's own recordings, as 25-second excerpts. The voice lines are cut from the movies' own sound at the times in each movie's subtitle file, so music and effects are mixed in. The picture behind each song is a map from the game, not necessarily where the song plays.

M01 · snd/adx/M01.adx

bgm_m01.mp4

M11 · snd/adx/M11.adx

bgm_m11.mp4

M56 · snd/adx/M56.adx

bgm_m56.mp4

M78 · snd/adx/M78.adx

bgm_m78.mp4

A01 · snd/adx/A01.adx

bgm_a01.mp4

Voices and effects: "Do it anytime, KOS-MOS!" / "Acknowledged." (movie s030100), "I am order!" / "Not you, KOS-MOS!" (s031300), "Fear drives evolution." (s083110, Disc 2), "When Mary fulfills her duty, Zarathustra shall speak!" (s093500, Disc 2), "I am not Mary. I am... KOS-MOS!" (s094820, Disc 2), then a battle callout (bat_voice/allen_bst1), a system jingle (sys/system01) and a field sound effect (CIT.dap cue 3)

voices_and_effects.mp4

The same clips, and a few more (B01, an event voice, a battle sound effect), are in docs/samples/ as MP3 files, and docs/gallery/make_audio_videos.py makes these videos from them. The full sets (all 120 music tracks with their loop points, 289 battle callouts, 607 sound banks, every movie's sound and every spoken scene line) come out of your own disc. More in docs/MUSIC.md.

Movies, fonts and menus

A frame of the opening movie s000300: young Shion in a cockpit Vector S-Line Division gate hall, retail, PCSX2 capture
A frame of the opening movie The Vector S-Line hall in the game itself, for comparison
A menu background, item icons and the controller sheet Party portraits from the battle window sheet window0.xtx
Menu pictures: a background, item icons, the controller Party portraits from the battle window
font0 glyph sheet 0 Four of the pictures behind the story-so-far screen
One page of the game's main font Four of the 71 pictures behind the "story so far" screen
KOS-MOS's texture pages from C3kosmos00.chr Extracted memory-card save illustrations
KOS-MOS's textures Some of the 348 memory-card save pictures

The window

The kit's window: a card per command, grouped by section, the environment panel on the right

The app is a page in your browser that only your own computer can see. It has one card per command, grouped into sections (Disc, Browse, Models, Text & translation, Fonts & scripts, Modding, Diagnostics). The panel on the right lists the discs it found, tells USA, Japanese and prototype discs apart, and shows which helper programs are installed. Show command prints the command line a card will run, for anyone who wants to learn the terminal way. (The discs in this picture are empty stand-ins.) More: docs/INSTALL.md.

Regions

The kit tells by itself which version a disc is (python cli.py region --iso X.iso -v says so out loud and checks it). Give it Disc 1 and Disc 2 of the same version; the tools that write refuse a mixed pair.

  • USA discs: everything on this page.
  • Japanese discs (SLPS_256.40 / 256.41): read and rebuilt exactly, with their own text encoding and font rules. 140 scenes exist only in the Japanese release, and align-export puts the Japanese and English script side by side (as a table, JSON, or a two-language subtitle file). Writing works on copies; not yet played in the emulator.
  • The May 2006 press prototype: read like the USA discs; its program differs from the final game's.
USA retail May 2006 prototype Japan retail
Boot program SLUS_213.89 (Disc 1), SLUS_214.17 (Disc 2), same code SLUS_213.89, different code (sha256 1c3d028a…) SLPS_256.40 (Disc 1), SLPS_256.41 (Disc 2), same code
Language folder \us\ (cf\us, mnu\us, mov\us, jpg\us …) \us\ \jp\; jpg\, ef\map\, ef\esp\ and mnu\pse\ files sit at the folder root (resolve handles both)
Text encoding the program's list of two-byte pairs; lone é, ö … are Latin-1 same as USA EUC-JP: any byte from 0xA0 pairs with the next; no half-width kana, no Latin-1
Proportional letters 0x180 (Latin and symbols) 0x180 0xC0 (kana are fixed width)
Message.Dat 933 messages, u32 offsets, strings from 0x2800 same layout 871 messages, u16 offsets, strings from 0x800
Subtitles mono allowed as USA no mono; mov\jp\bat files kept within 1 KiB (the developers' own note)
Scenes 715 .sb per disc 886 text objects, as many as USA Disc 1 856 (140 of them JP-only, load status unknown)
Writing tested on copies text-import, lang import, patch (in place and grown, pair and single); played in PCSX2: same-size, Arabic, --unlock jp, grown (Disc 1) patch same size text-import, patch (in place and grown); not played

Good to know

Safe by design. patch and the translation tools write into copies, never the originals, and check every file afterwards. (A few older commands, repack-* and chr-iso-*, change an image in place: give them a copy.)

Still open:

  • Nothing written from Disc 2, the Japanese discs or the prototype has been played yet, and no battle screen has been captured.
  • How much room the game gives each text file when it loads it is not known, so text that grows past its slot needs --grow.
  • The animations are not yet compared with the running game, and hair and coats stay stiff.
  • One effect format (.xep) is not decoded, and about a fifth of the art on the battle window sheets still gets its colours from a best guess rather than the game's code.

The full history, with every detail and test: docs/UPDATES.md. For the curious, docs/disc-catalog.md lists every kind of file on both discs, what it is, and a few fun finds.

Docs

Read this When you want to
INSTALL.md install the kit on Windows, macOS or Linux
BROWSING.md know what the kit writes and where to look first
BLENDER.md bring the models into Blender
MODELS.md, MOTION.md learn how the models, skeletons and animations work
MODDING.md, MODDING-CHARACTERS.md change the game: recolours, pictures, text, any file
TRANSLATING-GUIDE.md translate the game into your language, step by step, no programming
LANGKIT.md see the translation editor at work, with pictures from the game
TRANSLATION-EDITOR.md look up every detail of the translation editor
TRANSLATING.md, SCRIPTS.md, FONT.md translate with text files; add a new alphabet; how the font works
DIALOGUE.md get every line in play order, with voice clips
MUSIC.md get the soundtrack with its loop points
REPACK.md put any file back on the disc
FINDS.md, HISTORY.md, disc-catalog.md read about curiosities on the discs, and the background
MANUAL-PIPELINE.md see every command, and use the older 7-Zip pipeline
FORMATS.md see how every file is laid out, byte by byte (for tool writers)
CODEBASE.md find your way around the code (for programmers)
UPDATES.md see what changed, and when

All documents, grouped: docs/README.md.

Credits

By Jessi Ray Godsibb. Originally bootstrapped with ChatGPT; rebuilt around the corrected disc model.

  • Anzinono: xenosaga3-translation-kit (MIT), a German translation kit for the USA discs. udf.py ports its UDF descriptor handling (CRC-CCITT, tag fix-up, partition/integrity/anchor offsets) from tools/x3rebuild.py, so a disc that grows stays readable by every tool. Its database notes (docs/formats/datenbank.md, DBF string fields 3, 5 and 9-14) confirmed that the 14 mid-string values in DBC2.bin / njDataText.bin are numbers. That kit's xtx.py is in turn based on this kit's xtx_decode.py.
  • Lybac: the original Xenosaga III unpack and repack tools, whose LBA lists (lba/) this kit started from.

Xenosaga Episode III was made by Monolith Soft and published by Namco. This project is not affiliated with either and contains no game data.

Sibling kits: Episode I · Episode II

About

Python-only disc extractor for Xenosaga Episode III: Also sprach Zarathustra (PS2, USA, SLUS-21389): textures to PNG, audio to WAV, movies to MP4, MIPS disassembly, data dictionary of every file type, local web GUI. Beta, testers welcome.

Topics

Resources

Security policy

Stars

3 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages