manual | ||
scripts/abcde | ||
armips.exe | ||
build.bat | ||
datacommands.txt | ||
dump.bat | ||
extract.py | ||
filelist.txt | ||
font.py | ||
font.tbl | ||
isotool.py | ||
kefin.tbl | ||
kefinold.tbl | ||
notes.txt | ||
patch.asm | ||
pointer.py | ||
README.md | ||
script.py |
Ys V: Lost Kefin - Kingdom of Sand (PS2) English Translation
Currently using Sam Farron's translation from his Translation Series with permission
How to Help
Since this translation project currently uses an existing translation, it would be helpful to have people transcribing all the text in Sam Farron's playthrough since I'm focusing on the hacking side of things.
If you want to help with the translation please contact me!
Current Progress
I am replacing the usage of armips with acbde for script extraction and insertion. Currently I have raw dumps only as I need to figure out all the control codes to get a full pointer dump
Building
- Copy the original .iso to the root of this repo and rename it to
lostkefin.iso
- Run
isotool.py -m extract --iso lostkefin.iso --filelist filelist --files extracted
to extract all the files - Copy the contents to the
extracted
andtranslated
folders - Make changes as needed to the files in the
translated
folder - Run
isotool.py -m insert --iso lostkefin.iso -o english.iso --filelist filelist.txt --files translated
to create a modifiedenglish.iso
Running build.bat automatically patchespatch.asm
and buildsenglish.iso
Hacking Notes
- The game uses SHIFT-JIS encoding for its text
- English letters are halfwidth (1 byte, 10 pixels wide) and Japanese letters are fullwith (2 bytes, 20 pixels wide)
- The game's base pointer is $FFF80
- Extracted .bin files with
_anm
in the filename are animation files with indexed 8BPP graphics and have the headerNAXA5010
- Extracted .HGB files are texture files with 32BPP RGBA graphics
- Music files are
.hd
(header),.bd
(header), and.sq
(sequence) files - See my notes file for more terribly organized notes
Extracting the DATA.BIN Files
extract.py
extracts all the files and folders from DATA.BIN into the DATA
folder (but does not extract the files into their correct folders yet) and all files from DATA0.bin into the DATA0
folder, a logfile.txt
is also created
Font info
The game uses Shift-JIS encoding but I decided to make table files so I can include control codes
font.py
extracts the fontmap from SLPM_663.60
to create a quick font.tbl
table file. Use kefin.tbl
for corrected values and control codes
In SLPM_663.60
the font is located at $1A3E90 as 4BPP graphics, its palette is stored at $25E4C0, and the fontmap is at $1A31F0
Script Info
- Script files (named
stageXX.bin
) have the first $2000 bytes as a pointer table - Each pointer first as an "index" number (4 bytes, little-endian) then the pointer value to the file (4 bytes, little-endian)
- Pointer value are calculated as
pointer + $2000
- Changing the pointer seems to cause the game to freeze
Before running
script.py
copy the script files (as extracted fromDATA.BIN
) to thescripts
folder.script.py
will extract the pointer information for each file into a separate text file. The python script will also include info for control codes.
Before runningdump.bat
make sure perl is installed. On Windows I recommend isnstalling Strawberry perl
The script can be dumped fromDATA.BIN
and intoscripts
after runningdump.bat
. Currently it is a raw dump because I have not figured out all the control codes, using a pointer dump will cause the scripts to be under-dumped.
Control codes
kefin.tbl
already has some control codes documented. The control code $3B $XX
is to show character names in textboxes. pointer.py
is used to extract the character names and their indexes to match.
To do
- Figure out all the control codes properly
- Update the extraction script to extract
DATA0.BIN
folders,DATA1.BIN
, andSLPM_663.60
- Continue inserting the English script
Game Manual Translation
In the manual
folder are scans for the game's manual. They were originally from landofys.narod.ru which is now landofys.com.ru(http://landofys.com.ru/) was scanned by Dragon.
Related Materials
- Translation of opening cutscene by mziab (I did not use this translation)
- Hacking attempt by Hectavus with only
SLPM_663.60
being translated - Cheatcodes by luc-ita
- Guide and walkthrough by VoidZankantou
- Guide addendum by uncle5555 (South Tower enterance requirements)
- Review the game by Kurt Kalata (includes review for original SFC game)
- Original game website from Taito
Credits
- Sam Farron - Allowing me to use his translation as the basis of this project
- Hilltop - Providing valuable and informatative videos such as hacking with Ghidra and PS1/PS2 graphics
- Life Bottle Productions - Providing me with their isotool.py script and their tutorial for finding the base pointer
- The Geofront - Specifically folks on their Discord Server for their support of this project
- My friend for introducing me to the world of Ys, also the biggest Lost Kefin fan so I'm doing this for him
- Sugunii for giving me motivation to play more Ys
- Falcom for making the wonderful Ys series