Brandish: The Dark Revenant translation

Discussion in 'PSP - Hacking & Homebrew' started by G-Han, Apr 17, 2014.

  1. G-Han
    OP

    G-Han Advanced Member

    Newcomer
    64
    5
    Feb 17, 2009
    Netherlands
    [​IMG]

    About this project:
    In another topic I’ve expressed my interest to work on a translation of Brandish: The Dark Revenant for PSP bit by bit. Difficulty-wise, it's something I'm able to handle with my current schedule and language skills. However, I’m not able to do this on my own. In the same thread as mentioned above, user GHANMI managed to provide me with a text dump, but is unable to insert the text back. And although I am able to translate Japanese, my knowledge of coding is extremely limited.

    Hence, I was wondering whether someone would be willing to write me a program which extracts and inserts text from the files in Brandish: The Dark Revenant. This would allow me to work in e.g. a spreadsheet editor or CAT tool and to check how the translation appear in the game itself, so I basically would be able to advance on my own (pace). Like most people, my schedule is packed tightly and I won't be able to work every night on this project.

    Despite being a long-time lurker and contributer, this is actually the first time I’m pitching a translation project, so please let me know if I forgot to mention something.

    Progress:
    Extracting text files: done.
    Translation: ca. 19%.

    About the game:
    See Wikipedia for more information on the PSP remake and Hardcore Gaming for the series in general.

    Screenshots (from GameFAQs):

    [​IMG] [​IMG] [​IMG] [​IMG]
     
    KiEgon likes this.


  2. GHANMI

    GHANMI GBAtemp Advanced Fan

    Member
    971
    493
    Jun 10, 2012
    Oh, and I should mention something.
    The text is uncompressed Shift-JIS, but still accepts ascii characters just fine, and they show up with the appropriate width.
    Its internal structure is very similar to Ys 7 and Nayuta no Kiseki.
    For those attempting European translations, the font is out there and can be edited (at least the half width katakana letters) to satisfy your needs for accentuated characters.
    There's also a pmf video with subtitles. You can edit it (editing it would degrade the fluidity, but in this case the video originally isn't that fluid to begin with) following a guide posted on CUE's forums (in Spanish).
    As for the graphics... I don't know. Tilemolester?
     
  3. Maxtram

    Maxtram Advanced Member

    Newcomer
    93
    5
    Oct 14, 2010
    Venezuela
    It's Dark Revenant not Last Revenant
     
  4. Foxi4

    Foxi4 On the hunt...

    pip Reporter
    23,537
    21,496
    Sep 13, 2009
    Poland
    Gaming Grotto
    Fixed. :)
     
    G-Han likes this.
  5. neoxephon

    neoxephon GBAtemp Fan

    Member
    437
    138
    Jul 13, 2009
    United States
    USA
    I've been poking around inside this game and here are a few things that will be problematic:
    • Some of the text (such as item names and descriptions) appear to be hidden somewhere. There are two files that contain all of the items (/data/txt/item.tb + /data/ext/txt/item.tb) but editing these changes nothing in the game. In fact, they don't even appear to be used by the game. I've searched through all of the other files and not found the text anywhere else. I thought maybe it could be in the EBOOT.BIN (lots of games put text in there), but that isn't the case. Yet it has to be grabbing the text from somewhere. I'll keep looking later today when I get the chance.
    • The comma is used as a line break. If you want to use a comma at all, that will have to be changed.
    The pointers seem to be something entirely different from what I've seen in other PSP games that I've poked around in. But I haven't spent much time with the pointers yet. I'll look at them more later on and once I figure out how they work, I can program a tool to dump and re-insert the text.

    The graphic files shouldn't be a problem to edit. It uses the standard Falcom PSP format (.itp) and there are already tools that can convert from .itp to .bmp/.png and back again.

    UPDATE
    It seems that some of the files, such as item.tb, are packed into the .act files located in /data/pa

    I am 99% sure that this is where the game is pulling that text from. The other files are just dummy files and are unused.

    I can program a tool to separate the files, but they are compressed. I'm not an expert when it comes to compression algorithms, but I'll keep looking and see what I can figure out.

    The script is uncompressed, though.
     
    GHANMI and G-Han like this.
  6. G-Han
    OP

    G-Han Advanced Member

    Newcomer
    64
    5
    Feb 17, 2009
    Netherlands
    Oops.

    Also, thanks a lot, neoxephon!
     
  7. DaFixer

    DaFixer Dare to be stupid

    Member
    382
    107
    Aug 29, 2010
    Netherlands
    In my mencave ;)
    Nice!!
    Ga zo door ;)
     
    G-Han likes this.
  8. neoxephon

    neoxephon GBAtemp Fan

    Member
    437
    138
    Jul 13, 2009
    United States
    USA
    I've basically finished the programming to unpack the .act files. Repacking I'll do shortly, it's simple. At the moment, I'm still trying to figure out the compression. Falcom likes to use LZSS variants, so it might be that.
     
    G-Han likes this.
  9. GHANMI

    GHANMI GBAtemp Advanced Fan

    Member
    971
    493
    Jun 10, 2012

    There should be a pspfont file (openable with Tile Molester, Mode 2-Dimensional, 2 bpp linear, reverse order, 2 tiles/row) where you can just draw the coma elsewhere as another symbol (like the dollar sign, maybe?). No need to spend unnecessary energy and effort beyond that on that particular issue that can be resolved without resorting to mips assembly.

    I'd appreciate a lot if you could share a link to the "itp" tools here. xentax forums aren't showing the links for non-members anymore, which is quite problematic for anyone without a compatible credit card..
    And if you can, please take a look at Nayuta no Kiseki/Ys 7 to see if your "act" tools work on it as well (the general file structure and even some of the contents (case in point: the graphic format and the font structure, and to a limited extent the script files) is really similar between all of those)
    And thanks a lot for taking the time and effort to take a look at this. I'm still a long way too inexperienced to handle reverse engineering compressions
     
  10. neoxephon

    neoxephon GBAtemp Fan

    Member
    437
    138
    Jul 13, 2009
    United States
    USA
    Yeah, I'll definitely try that with the font, if I can get past the compression issue. I'm very, very much a beginner with ASM.

    The .itp tool can be found here: http://www.pokanchan.jp/dokuwiki/software/itxcnv#itp_converter

    It's command line, but really simple to use.
     
    GHANMI likes this.
  11. Maxtram

    Maxtram Advanced Member

    Newcomer
    93
    5
    Oct 14, 2010
    Venezuela
    good look i may try this game after the translation
     
  12. neoxephon

    neoxephon GBAtemp Fan

    Member
    437
    138
    Jul 13, 2009
    United States
    USA
    Man, this game has some weird stuff going on.

    I noticed that doing any kind of modification to the packed files in the .act files (that I mentioned before) made absolutely no visible changes in the game.

    Just when I was about ready to go crazy, I decided to just try something out for the hell of it.

    I changed the name of 2 items in the uncompressed items file (located in /data/txt/item.tb).

    I then put the modified item.tb into the ISO. After, I deleted the two files that contain (among other files) the compressed versions of the item.tb file.

    Guess what? Now the game is automatically reading the text from the uncompressed item.tb, that it wasn't reading from before.

    Check it out...
    ULJM05424_00000.jpg ULJM05424_00001.jpg

    Notice the item names are now in sexy English?

    If things work out as well as they have so far, we might be able to avoid having to deal with any of the compression.
     
    DaFixer, G-Han and GHANMI like this.
  13. G-Han
    OP

    G-Han Advanced Member

    Newcomer
    64
    5
    Feb 17, 2009
    Netherlands
    Great progress there, neoxephon! Awesome.
     
  14. neoxephon

    neoxephon GBAtemp Fan

    Member
    437
    138
    Jul 13, 2009
    United States
    USA
    I'm still trying to figure out the pointer system, specifically the pointer system for the script. There is some kind of pointer system, I can tell that much from my tests, but it does not seem to be any of the typical pointer systems that I've worked with in other games.
     
    G-Han likes this.
  15. G-Han
    OP

    G-Han Advanced Member

    Newcomer
    64
    5
    Feb 17, 2009
    Netherlands
    Is it something I might be able to help with?
     
  16. neoxephon

    neoxephon GBAtemp Fan

    Member
    437
    138
    Jul 13, 2009
    United States
    USA
    That depends on how comfortable you are with using a hex editor and whether you know what a pointer is and what it does.
     
  17. G-Han
    OP

    G-Han Advanced Member

    Newcomer
    64
    5
    Feb 17, 2009
    Netherlands
    Meh, not at all. Guess I'll just keep on cheering from the sidelines.
     
  18. zero_g_monkey

    zero_g_monkey GBAtemp Fan

    Member
    332
    203
    Aug 9, 2013
    United States
    Just wanted to say this is brilliant. Figuring out that you can delete the compressed file and use the uncompressed one... Wonderful. Did a test run on the first few minutes of Zero no Kiseki. It works!!! Good luck with the project. Falcom pointers are either straight forward or broken down like the file contains individual files or they go the block method... or the are completely random (as in haven't figured them out myself). The pointers are what have been holding me up with Eiyuu Densetsu 1 & 2 on PSX. Again, good luck and great find.
     
  19. neoxephon

    neoxephon GBAtemp Fan

    Member
    437
    138
    Jul 13, 2009
    United States
    USA
    Yeah, I still haven't had any luck figuring out the pointers. The uncompressed file trick works with Nayuta no Kiseki, as well. Probably works with most of their PSP games.
     
    GHANMI likes this.
  20. GHANMI

    GHANMI GBAtemp Advanced Fan

    Member
    971
    493
    Jun 10, 2012
    Actually, I tried with Tengai Makyou IV PSP. There's a font (uncompressed) included in the eboot, and the script (an uncompressed file that seems to also include graphics by the hex data patterns but not sure really) is divided on 12 files.. When I tried modifying both of them and keeping the same size (with UMDReplace, then verifying extracting the files again to check if they have been replaced indeed), the game behaves exactly as if it hasn't been touched at all, original text, fonts and all.
    I don't really know whether they have a compressed duplicate or not.
    Could this be some standard practice for PSP games? Or a bug with PPSSPP? I wish I knew.

    To be honest those games and their gargantuan script scare me to the point of not even thinking about touching their isos.
    (Then again, I was crazy enough to look into Manjimaru DS (a game whose speedruns clock at 13 hours): uncompressed Shift-JIS text, though compressed graphics and font. They are however compressed in a format that accepts a bigger color palette than the TG-CD original: a pipe dream of mine would be translating those whenever I learn Japanese with the already FF4-quality graphics enhanced to SNES-quality)

    EDIT: sorry for double-posting.