Kingdom Hearts: Final Mix Translation Patch (In progress)

Discussion in 'Code Vault' started by Trilix, Feb 20, 2012.

  1. Darth Typho Destiny Islands Resident

    Joined:
    Mar 30, 2007
    3
    88
    Come on! :( There has to be someone out there, that knows of, or can make a patch for this game! Come on! Please! Anything! Even the smallest patch would work, there has to be something, or somone can make something!
     
  2. Mixt The dude that does the thing

    Joined:
    Oct 18, 2006
    Gender:
    Male
    826
    Unfortunately as Majik said, for a patch to be made the game must be reverse engineered. This means reversing both compression and encoding algorithms before you can even touch the meat and bones of the project. And even then you must understand how the structure of the game works and edit it properly, followed by debugging and so on. As I understand it KH1 is harder than KH2 and has had less effort put into it. I really just don't see a translation patch for this coming any time soon (though I would optimistically like to believe that there are enough people examining this dead project from time to time to reach the answer eventually).
     
  3. DarkSonic22 Moogle Assistant

    Joined:
    Feb 2, 2010
    0
    9
    Up! Any news about a KHFM patch?
     
  4. Miles Cull a Duty 2 : Electric Boogaloo

    Joined:
    Jul 31, 2011
    Gender:
    Male
    Location:
    Ohio
    258
    Nope.
     
  5. EvilMan_89 Code Master

    Joined:
    Sep 30, 2006
    Gender:
    Male
    203
    yea, i don't think any of us should expect any news either. i think at this point, our best bet is to hope that Kingdom Hearts 1.5 Remix makes it out of Japan.
     
  6. Hidden Smithery King's Apprentice

    Joined:
    Feb 2, 2010
    81
    452
    I certainly hope it does.

    I don't know about the rest of you but it feels... odd... to me, having translation patches for KH2 and BBS but not the original game. I've recently looked into a lot of KH-related things the last few days and it's astounding to see how many people have tried, or at least claimed to have tried, and ultimately failed to make any sort of headway with the project idea. Although not quite as bad, it's similar to the Half-Life 2 Beta recreation effort; seemingly cursed and with little to no progress to show for it.

    I've been attached to the KH series since I was a child and I've grown up alongside it, as many of you here have. I know that in the years following the release of the game, it's bonuses and texts have been translated online.. Many of us, myself included, have found various ways to actually play said content, legally or otherwise. However the fact that we can't enjoy it without breaking the flow of the game, forcing us to either learn a language foreign to many or have a guide nearby at all times.

    I say this less directly to you, EvilMan_89 and more to whoever decides to read this thread again in the future (it shows up all the time in Google searches); if you believe you have the technical know-how, and can figure out some way to make a patch for this game happen, please attempt it. A partial patch is better than no patch at all.

    Whoever reads this in the future, please understand that there will be at least one other KH fan in the world who will love your work. It's been done with two other Final Mixes; I know that it's different every time, but it's proof that it, in some form, can be done.

    If I knew how, I would try my best to make a partial patch myself, I would. But that's beyond my knowledge.
     
  7. root670 Destiny Islands Resident

    Joined:
    Feb 28, 2013
    5
    52
    Last month, I created a tool that can encode text into the character set that's used in the US and JP (think ASCII and Shift-JIS) versions of Kingdom Hearts and Final Mix. I'll need to clean it up, but I'd like to share it sometime in March. As of now, it can't convert Kanji, just Latin text.

    I've found that some text in the game (menu text in particular) is not compressed or encrypted. Using my tool, you can type in a known string of text and get an encoded result (given as hex digits). You can then search through the ISO using a hex editor and replace the text with something else. This could potentially be used to create a translation patch, but it's kind of pointless without a data compressor/decompressor. All cutscene files are compressed, and you can decompress these using Falo's file dumper. You can search for text inside these files using hex codes encoded with my tool, but I don't have a way to recompress them yet. I decompiled the decompression routine from Falo's dumper so I can better understand it. You can, however, save edited text that's uncompressed back the ISO. As a test, I was able to crapilly translate the menu items on the pause menu and save it back to the ISO.

    The major hurdle for creating a translation patch for Final Mix is that it only has upper-case letters available outside of Kanji in its font table. This table could be replaced with one from the US version, for example, but I don't have the know-how to be able to do this. Add that I have no knowledge of the Japanese language; this translation patch won't be created by me. I'm hoping my text encoder tool could help someone else who's interested.
     
  8. Miles Cull a Duty 2 : Electric Boogaloo

    Joined:
    Jul 31, 2011
    Gender:
    Male
    Location:
    Ohio
    258
    How did xyeenamo import lower case letters in 2FM?
     
  9. root670 Destiny Islands Resident

    Joined:
    Feb 28, 2013
    5
    52
    He was able to replace the font table with the one used in the US release, IIRC.

    Edit: Font is stored in a file called menu/sysfont.bin and can be extracted using Falo's ripper. It's compressed in the US release and uncompressed in Final Mix. Haven't checked the original JP release yet, though.
     
  10. masterjiraia89 Moogle Assistant

    Joined:
    Mar 6, 2013
    Gender:
    Male
    0
    3
    Hey, would it be possible to use kingdom hearts wikia for examples of what text strings to put where, it might help
    it doesn't have to be as hard as translating, words (in any language) only represent the meaning behinde the object
    it might be possible to rip the text strings run them through google translate switch to wikia and find a close match and apply it and there you go
    I'm sorry if this doesn't work it was just a thought I had and I didn't mean to be rude or anything
    I'd like to help but only know english non-console game and program development sorry.
    but, if there is any thing you need to help this project along, ask, I might now how to help, then again, I might not.
     
  11. Hidden Smithery King's Apprentice

    Joined:
    Feb 2, 2010
    81
    452
    I will attempt to locate that ripper and I will check for you.

    If this is really possible to do, I offer my services (time and energy mostly) to help this project. I think cutscenes could wait for a while as long as menu text is translated.

    I just want to see this done properly.

    (Also, did Xeeyamo release his tools or not? I would REAAAAAAAAAAAAAAAALLY like to fix up some of the grammar choices he made. They kill me every time I see them.)

    EDIT:
    I can't seem to find that ripper. Pity.
     
  12. root670 Destiny Islands Resident

    Joined:
    Feb 28, 2013
    5
    52
    Here's a link to the ripper: http://www.sendspace.com/file/g1rhf5. I tried swapping the sysfont.bin file from the US version into the Final Mix version just to see what would happen. The game was able to read it without crashing, but the table wasn't "lined up" to the character table of the final mix version or the US version. Also, I'm pretty sure Xeeyamo hasn't released any of his tools he mentioned. In fact, in a little over a week from now, it'll be one year since he last updated his blog :(.
     
  13. NarutoSuperKubii Chaser

    Joined:
    Aug 6, 2008
    164
    He did release his kh2 dumper which has the capabilities of recompiling everything but its just for kh2. As far as I know that was his only tool.
     
  14. Hidden Smithery King's Apprentice

    Joined:
    Feb 2, 2010
    81
    452
    Damn.

    I guess I'll either have to deal with it or gain amazing programming skills to remake it. I wonder if you could just edit the patch file he made somehow?

    And by "Not lined up" do you mean that the text was randomized or something?
     
  15. root670 Destiny Islands Resident

    Joined:
    Feb 28, 2013
    5
    52
    Basically, yeah. It was just a bunch of random characters that looked quite odd:
    [​IMG]
    Also, here's a preview of what I've done so far with the translation. It's just the main menu for now, but shows that more is possible. All the menu strings here were uncompressed and could be modified without any issues. Note that I did this on the original Japanese version of the game (not Final Mix):

    [​IMG]

    Here's a PPF patch for what I have so far: http://www.sendspace.com/file/s4bpzw. Again, this is not for the Final Mix version[/quote]
     
  16. Hidden Smithery King's Apprentice

    Joined:
    Feb 2, 2010
    81
    452
    [/quote]
    Astounding.

    I'd like to help you. Can I? Pretty please with the x-blade on top?
     
  17. root670 Destiny Islands Resident

    Joined:
    Feb 28, 2013
    5
    52
    You might be able to help, here's the string encoder/decoder I made that I mentioned earlier: http://www.sendspace.com/file/5ckh2g

    Here's a quick readme.txt for it
    The main thing we can do (before decompression/compression is dealt with) is find strings in the game's ISO. It's a little hard to explain, but here's how it works:

    You need:
    a hex editor (I like HxD)
    PCSX2
    CheatEngine
    An ISO for Kingdom Hearts (you can rip this yourself using ImgBurn or similar).

    Run the game using PCSX2. Find some text in the game, like the pause menu for example. My String encoder/decoder can deal with Latin characters (ABCDEFGHI...etc.), but no Japanese characters. If your're looking for Japanese characters, use this table to match the characters on the screen and find their hexidecimal equivalents. This can be challenging because some characters are represented in two different ways that are indistinguishable when you see them in the game. Specifically, some characters are represented as 2 bytes and also 1 byte. The :"2 byte" characters will always begin with 0x19.

    To view that table, disable any automatic translation in your browser and ensure that you have the needed Japanese fonts installed. If they display as a bunch of rectangles, something went wrong.

    When you've figured out the hex codes for some text, open CheatEngine. Click the rainbow button on the top left and select PCSX2.exe. Under "Memory Scan Options", change start to 20000000 and end to 21000000. Check the box next to "Hex" and paste in any hex values you've found from the table. Click "First Scan". From the results that you find (if any), double click them and modify their values. If you've found the correct string in memory, the text should change on screen. So if, for example, I searched for SORA ("40 3C 3F 2E" in hex) and found the correct location in memory, If I modified one byte the text would immediatly change on the game screen.

    After you've found a location that changes text on the screen, highlight it and press CTRL-B to bring up the memory browser. Using your mouse, select a bunch of characters near that location that the text's in. This would be in the bottom window pane. Press CTR-C to copy the values to the clipboard. Open up the Kingdom Hearts ISO in the hex editor of your choice and open the Find dialog (CTRL-F in HxD). Change the Datatype to "Hex-Values". Press CTRL-V to paste the values you got from cheat engine. Click "OK".

    If you're lucky, the hex editor will find the location of the text on the disk and you can modify it with new hex values provided by my string encoder program. Make sure you select "Shift-JIS" If you're using a Japanese version of the game, which you probably are in this case. If it didn't find it on the disk, the text you want is probably compressed and, as of now, cannot be modified. After making a change, save the ISO, Load it in PCSX2 and hope for the best.

    IMPORTANT: The hex codes you change in the game must maintain be a similar length to the original hex codes, ensuring that a NULL character (0x00) is at the end of it. Otherwise, you'll run right into another string and will cause text corruption and other oddities in the game.




    That was probably overly-technical, but that's the amount of work that must be done just to scrape the surface with a translation patch. This method is extremely time consuming, so it's not very practical. If anyone finds some text locations in the game that are useful, post them here I guess. Please do not PM them to me.
     
  18. Hidden Smithery King's Apprentice

    Joined:
    Feb 2, 2010
    81
    452
    I'll see if I can convince my boyfriend to let me use the computer later today then. First I'll try to replicate what you made above (the start menu) to make sure I have a rough idea of what to do, then I'll see about getting the character names to show on the screen too (if that is too hard I might just try to get one of the Heartless' entries to show).
     
  19. root670 Destiny Islands Resident

    Joined:
    Feb 28, 2013
    5
    52
    That's the spirit :). Thanks for your help.
     
  20. Hidden Smithery King's Apprentice

    Joined:
    Feb 2, 2010
    81
    452
    Okay, I've been trying to get the word "CONFIG" to show on the screen for roughly the last hour or so. Nothing so far.

    I may be doing it wrong, however.

    If I'm understanding you correctly, コンフィグ translates to Config. Each character in the word コンフィグ has it's own value on that table, which when I put them together, looks like this: E9190DFB19291910. I search for that with the value type "2 Bytes", and I get 101 results. However, all of listed addresses have the value listed of 1910, which I think is wrong.

    (Keep in mind that this is the normal Japanese version of KH, and I haven't applied that patch you posted earlier.)

    It amazes me that you could explain it so nicely and I still manage to mess it up somehow.

    Here's what I'm looking at.
    [​IMG]

    The 4-byte search never seems to find anything.

    I wish you could/would get on more often than once a day. This is going nowhere fast.

    EDIT:
    Okay, I got impatient and decided to just try it without using Cheat Engine to find out what I was looking for. I searched the iso, using the hex editor, for E9190DFB19291910 (the only result apparently), changed it to 303C3B3336340101 ("CONFIG" and two spaces to fill up the left over digits) and here is the fruit of my labor:
    [​IMG]