Tokugawa Corporate Forums

Retro Japanese Computing
It is currently March 28th, 2024, 3:54 pm

All times are UTC




Post new topic Reply to topic  [ 2 posts ] 
Author Message
PostPosted: July 11th, 2017, 12:11 am 
Offline

Joined: May 25th, 2017, 12:51 am
Posts: 1
I've been trying to extract the script from the leaked English translation of the DOS/V version of Princess Maker 2, as it's better than the new translation (turns out having a Korean developer translate text from Japanese to English won't have the best results). Because of this, I'd like to inject the good translation into the Steam remake since it has nicer graphics. Actually injecting text into the remake is easy, since the script is just stored in the executable in plain text. However, the "extracting the script from the old version" part is a lot harder. The DOS version stores its data in ".lbx" files which are pretty much just every file in a certain category stored in one file with the hex offsets listed in the end. After this, the text files are still compressed or something. By using DOSBox's memory viewer, I've found that the PM2 executable is something like a BASIC interpreter, and all the text files are BASIC programs (according to an interview with the game's translator the BASIC dialect is called PM-BASIC). Here's a snippet from one of the files I recovered through memory dumping:
Code:
IF ( IRND = 8 )
   IF ( URA_BREAST_TYPE = 3 )
      IF ( B_IROKE >= 120 )
         TXGIRL(1)


         "My bust size is pretty large."
      IF ( B_IROKE < 120 )
         TXGIRL(11)

          TXT("I'm worried that my bust is getting a bit ")
         "too large..."
      GOTO KAIWA_RET
   IF ( URA_BREAST_TYPE = 2 )
      IF ( B_IROKE >= 120 )
         TXGIRL(1)

         "My bust size seems to be about average."
      IF ( B_IROKE < 120 )
         TXGIRL(10)

         "My bust size is only average..."
      GOTO KAIWA_RET
   IF ( URA_BREAST_TYPE = 1 )
      IF ( B_IROKE >= 120 )
         TXGIRL(11)

         "Dad, do men prefer big-busted women?"
      IF ( B_IROKE < 120 )
         TXGIRL(1)

         "A smaller bust makes it easier to move around."
      GOTO KAIWA_RET

Anyway, none of the compressed files match any compression algorithm I know of, which is why I think they're binary BASIC files. Anyway, Here's a zip file containing the entire compressed script and everything I dumped with memory editing before I got bored (it only loads one file into memory at once, which makes dumping the script fairly tedious). If anyone recognizes the format of the binary BASIC files and there's a way to decompress them without having to do every possible action in the game and dump the memory, I'd love to hear it.


Top
 Profile  
 
PostPosted: July 24th, 2017, 12:07 pm 
Offline

Joined: March 29th, 2017, 3:01 pm
Posts: 1
Just out of curiosity wasted yesterdays evening and some of the morning today and here it is. It doesn't have anything to do w/ BASIC, just some obfuscation method + good old RLE variant. HTH!


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 9 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group