Toggle menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

BinJ Editor 3DS: Difference between revisions

From GameBrew
No edit summary
m (Text replacement - "Category:3DS homebrew rom hacks" to "")
 
(13 intermediate revisions by the same user not shown)
Line 1: Line 1:
{{Infobox 3DS homebrew
{{Infobox 3DS Homebrews
| title = BinJ Editor
|title=BinJ Editor
| image = https://dlhb.gamebrew.org/3dshomebrew/BinJEditor.jpg|250px
|image=Binjeditor2.png
| type = Hack Utilities
|description=A tool For translating Dragon Quest Monsters games.
| version = v2.2.1
|author=Ich_73
| licence = Mixed
|lastupdated=2021/08/25
| author = Ich_73
|type=Hack Utilities
| website = https://gbatemp.net/threads/release-binj-editor-a-tool-for-translating-dragon-quest-monsters-games.573053/
|version=2.2.1
| download = https://dlhb.gamebrew.org/3dshomebrew/BinJEditorv2.2.1.7z
|license=Mixed
| source = https://github.com/Ich73/BinJEditor
|download=https://dlhb.gamebrew.org/3dshomebrews/binjeditor.7z
|website=https://gbatemp.net/threads/release-binj-editor-a-tool-for-translating-dragon-quest-monsters-games.573053
|source=https://github.com/Ich73/BinJEditor
}}
}}
<youtube>ksgFDNKbdts</youtube>
BinJ Editor is an editor for .binJ and .e files with custom decoding tables. It allows you import, edit, save, share and export translations for games using the .binJ and .e file format to store messages. Those games include:
* [[Dragon_Quest_Monsters_-_Terrys_Wonderland_3D_3DS|Dragon Quest Monsters: Terry's Wonderland 3D]].
* [[Dragon_Quest_Monsters_2_-_Cobi_and_Taras_Marvelous_Mysterious_Key_3DS|Dragon Quest Monsters 2: Iru and Luca's Marvelous Mysterious Key]].


'''Abstract'''
The program was written while researching binJ and e file formats, if you want to learn more about them, check out [https://github.com/Ich73/BinJEditor/wiki/BinJ-Format BinJ Format] and [https://github.com/Ich73/BinJEditor/wiki/E-Format E Format].
BinJ Editor lets you import, edit, save, share and export translations for games using the .binJ and .e file format to store messages. Those games include ''Dragon Quest Monsters: Terry's Wonderland 3D'' and ''Dragon Quest Monsters 2: Iru and Luca's Marvelous Mysterious Key''.


<span style="font-size: 18px"><span style="text-decoration: underline">'''Introduction'''</span></span>
==Features==
Hi, the last past weeks I was trying to find out how the binJ file format works. Simply because I wanted to change a few messages in ''Dragon Quest Monsters 2: Iru and Luca's Marvelous Mysterious Key''. I thought this surely can't be that hard. The short answer is I was wrong, the long answer is hidden in the following spoiler.
* Import and Export .binJ and .e files.
* Save and Open .savJ and .savE project files.
* Apply and Create .patJ and .patE patch files.
* Use different separator tokens and decoding tables.
* Send the current file via FTP.
* Search for texts in multiple files at once.
* English, German, Spanish.


<div class="ToggleTriggerAnchor bbCodeSpoilerContainer">
==Installation==
Download contains builds for Windows as standalone executable and installer.
* BinJEditor-Standalone.zip - Extract the archive to a directory of your choice and run BinJEditor.exe.
* BinJEditor-Installer.zip - Extract the archive and run BinJEditor-Installer.exe to install BinJ Editor on your PC.
** After that you can launch it from the start menu.
** File associations will be registered for .savJ, .savE, .binJ and .e files.


<span>Spoiler: <span class="SpoilerTitle">Backstory</span></span>
If you cannot start BinJ Editor on Windows 7, have a look at [https://github.com/pyinstaller/pyinstaller/issues/4706#issuecomment-633586051 this answer]. Additionally you may want to install [https://www.python.org/downloads/release/python-383/ Python 3.8].
<div class="SpoilerTarget bbCodeSpoilerText">


The first thing I did to translate a text was opening the binJ file using Notepad++. Since it directly showed japanese characters I thought, I could directly replace them and expected it to work. Even though I was looking at a binary file, which you usually can't just read with a text editor. But when I copied some texts to Google Translate to find out what they mean, I was disappointed. The texts weren't real japanese. So I googled a bit and found [https://gbatemp.net/threads/dragon-quest-monsters-2-iru-and-lucas-marvelous-mysterious-key-translation-project.471939/ this thread] where they chatted about binJ files.
'''Note:''' It is recommended to update the decoding table of every .savJ and .savE file even if you did not use any of those symbols. To update the decoding table of all save files you can use the CS -f script of [[Translation Toolkit 3DS|Translation Toolkit]] or open the file, choose Edit > Decoding Table and select the table you want (not Table from Save).


They wrote that these files use a custom encoding for japanese characters and characters in general. What you have to understand about binary files is that they are basically 1s and 0s. This is true for all files, but &quot;normal text files&quot; use a standardized encodings. This means that the byte &quot;0110 0001&quot; with a common encoding like ASCII or UTF-8 always stands for the character &quot;A&quot;. But for the game I tried to translate a custom encoding is used. They encode the character &quot;A&quot; using the byte &quot;0000 1101&quot;. Once I used the encoding table provided in the thread I was able to read the correct texts. Now I tried to change a single character by replacing the original bytes for this character with the bytes for the character I replaced it with. I sent the file to my 3DS and launched the game. It worked. Great.
==User guide==
Import a file:
* Choose File > Import... and select the file. This process may take a few seconds.  
* Now you can start editing the file by entering text into the last column.
* To save, choose File > Save As... or export an edited .binJ file by choosing File > Export....
* A full explanation can be found on [https://github.com/Ich73/BinJEditor/wiki/BinJ-Editor-Manual BinJ Editor Manual].


Now I only needed to find a way to tell the individual texts appart and luckily the texts were always separated by a special two-byte long token. Thus I wrote a small programm that read the binary data, splitted the texts and decoded the bytes to japanese texts. And it worked great. This was the point where I started developing the first version of BinJ Editor. A thing that I haven't talked about yet is that with this method you have to keep the byte length of the original text and the translated text the same. Otherwise the game won't find the texts and just crashes. The problem with this method is that japanese is a lot denser than english. Normally two characters of japanese text are translated with about eight characters of english text. But since the encoding table they used is optimized for japanese text, a lot of common japanese characters are encoded using no more than a single byte. This means the english translation for a two character long japanese text is only allowed to have two bytes as well. As an example you could translate &quot;�性&quot; (resistance) with &quot;RE&quot; but not &quot;RES&quot; and definitely not with &quot;Resistance&quot;. That was a thing I was able to overcome much later.
FTP Client:
* Handy for directly sending the edited files to your 3DS for Luma to patch.
* More on that can be found on [https://github.com/Ich73/BinJEditor/wiki/BinJ-Editor-Manual#ftp-client BinJ Editor Manual].


But what I was able to do was shorten the texts by simply replacing not-needed characters with null bytes. And therefore I started developing the first version of BinJ Editor. After the first sketch was finished I started translating a few menu texts as a proof of concept. And this was the point were I realized all binJ files have a weird long &quot;first text&quot; that I never looked into. All first texts looked similar and at this point I thought maybe those bytes are the addresses of the texts in the binary file. I checked it and I was right. That means that given a list of texts (with their respective lengths) I was able to re-create this address block. Now I had two possibilites: rewrite my import function of binJ files to validate that the texts I obtain by looking at the separator tokens are correct OR just believe it works. And... I chose the second option. Which was the bad one. But at least I could now replace texts with translated texts of arbitrary length. So I rewrote a lot of parts of BinJ Editor and started translating more parts of the game. Until...
Search Dialog:
* Another useful tool which let's you search multiple binJ, e and other files at once.
* More on this tool can be found on [https://github.com/Ich73/BinJEditor/wiki/BinJ-Editor-Manual#search-dialog BinJ Editor Manual].


... there were problems. I translated some battle messages and whenever I entered a battle the game crashed. So I looked into the binary data once again and found out that this particular binJ file included the same address twice. So I had to look into the address block while parsing binJ files... I started rewriting the corresponding parts of BinJ Editor and at some point I realized that I always missed the first text of the translation before because the first text does not start with the separator token as all the other texts do. And did I mention one file contains a one-byte off pointer? Anyway... someday I got all of this to work and this basically is the whole story of how I got to decipher the binJ file format and how I wrote BinJ Editor. I later cleaned things up, added some convenient features, wrote documentation and... created this post.
In the below section, you will find some examples screenshots from Dragon Quest Monsters 2: Iru and Luca's Marvelous Mysterious Key. Note that the first screenshot of each row is the original, the second one the translated (using BinJ Editor) and the third one the translated including a custom font and custom images (cannot be done using BinJ Editor).


</div>
==Screenshots==
'''BinJ Editor''' <br>
https://dlhb.gamebrew.org/3dshomebrews/binjeditor3.png


</div>
https://dlhb.gamebrew.org/3dshomebrews/binjeditor4.png
If you simply want to know more about the binJ and e file formats check these out: [https://github.com/Ich73/BinJEditor/wiki/BinJ-Format BinJ Format] and [https://github.com/Ich73/BinJEditor/wiki/E-Format E Format]


'''Examples''' <br>
https://dlhb.gamebrew.org/3dshomebrews/binjeditor6.png


<span style="font-size: 18px"><span style="text-decoration: underline">'''Presentation'''</span></span>
https://dlhb.gamebrew.org/3dshomebrews/binjeditor7.png
[[File:proxy.php?image=https%3A%2F%2Fuser-images.githubusercontent.com%2F44297391%2F91449697-b562e480-e87b-11ea-983f-1c6407ecef3a.png&hash=d019a924d07e1031c1a18a58053df2f5|class=bbCodeImage LbImage|[?IMG]]]


To import a file choose &quot;File &gt; Import...&quot; and select the file. This process may take a few seconds. Now you can start editing the file by entering text into the last column. When you finished editing you can save a project file by choosing &quot;File &gt; Save As...&quot; or export an edited .binJ file by choosing &quot;File &gt; Export...&quot;.
https://dlhb.gamebrew.org/3dshomebrews/binjeditor8.png
A full explanation can be found on the Website of this project: [https://github.com/Ich73/BinJEditor/wiki/BinJ-Editor-Manual BinJ Editor Manual]


[[File:proxy.php?image=https%3A%2F%2Fuser-images.githubusercontent.com%2F44297391%2F91468919-f74b5500-e892-11ea-8c2d-5d046eb6ac81.png&hash=7877d050c4a59759447fd78f04787b61|class=bbCodeImage LbImage|[?IMG]]]
==Changelog==
'''v2.2.1'''


It also includes a very handy FTP Client for directly sending the edited files to your 3DS for Luma to patch.
Changes:
More on that can be found in the Manual as well: [https://github.com/Ich73/BinJEditor/wiki/BinJ-Editor-Manual#ftp-client BinJ Editor Manual]
* Small bug fixes.
* Update decoding tables.


[[File:proxy.php?image=https%3A%2F%2Fuser-images.githubusercontent.com%2F44297391%2F96344030-5c087c00-109a-11eb-9f66-37f79e5546f6.png&hash=ac9996d306eaf42e653b8782f55e1f91|class=bbCodeImage LbImage|[?IMG]]]
'''v2.2.0'''


Another very useful tool is the Search Dialog which let's you search multiple binJ, e and other files at once.
Additions:
More on this tool can be found in the Manual: [https://github.com/Ich73/BinJEditor/wiki/BinJ-Editor-Manual#search-dialog BinJ Editor Manual]
* Open and go to a search result by double clicking it.
* Add menu option alternating colors.
* Add menu option expert mode.
* Implement wildcard search.


Changes
* Rewrite internal structure.
* Update decoding tables.


<span style="font-size: 18px"><span style="text-decoration: underline">'''Examples'''</span></span>
'''v2.1.0'''
As an example I present you four screenshots from ''Dragon Quest Monsters 2: Iru and Luca's Marvelous Mysterious Key''.
The first one is the title screen, the second one the loading screen and the third one the status screen of my buddy Pineapple. All texts are stored in binJ files.
The fourth screenshot shows a dialog with the father of the protagonists which is stored inside an e file.
Note that the first screenshot of each row is the original, the second one the translated (using BinJ Editor) and the third one the translated including a custom font and custom images (''cannot'' be done using BinJ Editor).


<div class="ToggleTriggerAnchor bbCodeSpoilerContainer">
Additions:
* Add support for installed version with file associations.
* Add go to line option.
* Add close file option.
* Add option to scale rows to contents.
* Add icons for menu entries.


<span>Spoiler: <span class="SpoilerTitle">Title Screen</span></span>
Changes
<div class="SpoilerTarget bbCodeSpoilerText">
* Improved editing behaviour.
* Update decoding tables.


[[File:proxy.php?image=https%3A%2F%2Fuser-images.githubusercontent.com%2F44297391%2F91964127-0c026f80-ed0f-11ea-95da-69fc2f2858d3.png&hash=75dc68055d589c35a0e09955dd11972c|class=bbCodeImage LbImage|[?IMG]]]
'''v2.0.0'''


</div>
Additions:
* Add support for .e files.
* Add search dialog (see Manual).
* Add option to automatically scale rows to contents.


</div>
Bugs
<div class="ToggleTriggerAnchor bbCodeSpoilerContainer">
* Fix bug when using copy and paste actions while the table is sorted.


<span>Spoiler: <span class="SpoilerTitle">Loading Screen</span></span>
Decoding Tables
<div class="SpoilerTarget bbCodeSpoilerText">
* Change middle dot to katakana middle dot.
* Allow input of j-ascii space, ¿ and ¡.


''Note:'' The monsternames are fixed, so my Slimey has a japanese name and the others have german nicknames.
[https://github.com/Ich73/BinJEditor/releases Release notes.]


[[File:proxy.php?image=https%3A%2F%2Fuser-images.githubusercontent.com%2F44297391%2F91964134-0efd6000-ed0f-11ea-9341-e2057a400ede.png&hash=09b112c2e0369e30088cb776f76568c5|class=bbCodeImage LbImage|[?IMG]]]
==External links==
 
* GitHub - https://github.com/Ich73/BinJEditor
</div>
* GBAtemp - https://gbatemp.net/threads/release-binj-editor-a-tool-for-translating-dragon-quest-monsters-games.573053
 
</div>
<div class="ToggleTriggerAnchor bbCodeSpoilerContainer">
 
<span>Spoiler: <span class="SpoilerTitle">Status Screen</span></span>
<div class="SpoilerTarget bbCodeSpoilerText">
 
''Note:'' The game does weird things with the width of some texts, so &quot;AGIL&quot; displays unreadable and &quot;A�G�I�L&quot; does the job.
 
[[File:proxy.php?image=https%3A%2F%2Fuser-images.githubusercontent.com%2F44297391%2F91976011-9bfce500-ed20-11ea-801e-e9cde0104a54.png&hash=3138fd7f28f7e8e24c4262dd2658bd9a|class=bbCodeImage LbImage|[?IMG]]]
 
</div>
 
</div>
<div class="ToggleTriggerAnchor bbCodeSpoilerContainer">
 
<span>Spoiler: <span class="SpoilerTitle">Conversation with Dad</span></span>
<div class="SpoilerTarget bbCodeSpoilerText">
 
[[File:proxy.php?image=https%3A%2F%2Fuser-images.githubusercontent.com%2F44297391%2F96371242-0054f600-1161-11eb-9465-b48d31067c64.png&hash=4e1752d0e71268be65ca69d55e7bac5d|class=bbCodeImage LbImage|[?IMG]]]
 
</div>
 
</div>
 
 
<span style="font-size: 18px"><span style="text-decoration: underline">'''Download'''</span></span>
The project is hosted on GitHub: [https://github.com/Ich73/BinJEditor BinJ Editor on GitHub]
You can download the latest version at: [https://github.com/Ich73/BinJEditor/releases/latest Latest Version of BinJ Editor]
 
 
I hope you like it
Ich_73
<div class="messageTextEndMarker">
 
 
</div></blockquote>

Latest revision as of 06:11, 6 Mayıs 2024

BinJ Editor
Binjeditor2.png
General
AuthorIch_73
TypeHack Utilities
Version2.2.1
LicenseMixed
Last Updated2021/08/25
Links
Download
Website
Source

BinJ Editor is an editor for .binJ and .e files with custom decoding tables. It allows you import, edit, save, share and export translations for games using the .binJ and .e file format to store messages. Those games include:

The program was written while researching binJ and e file formats, if you want to learn more about them, check out BinJ Format and E Format.

Features

  • Import and Export .binJ and .e files.
  • Save and Open .savJ and .savE project files.
  • Apply and Create .patJ and .patE patch files.
  • Use different separator tokens and decoding tables.
  • Send the current file via FTP.
  • Search for texts in multiple files at once.
  • English, German, Spanish.

Installation

Download contains builds for Windows as standalone executable and installer.

  • BinJEditor-Standalone.zip - Extract the archive to a directory of your choice and run BinJEditor.exe.
  • BinJEditor-Installer.zip - Extract the archive and run BinJEditor-Installer.exe to install BinJ Editor on your PC.
    • After that you can launch it from the start menu.
    • File associations will be registered for .savJ, .savE, .binJ and .e files.

If you cannot start BinJ Editor on Windows 7, have a look at this answer. Additionally you may want to install Python 3.8.

Note: It is recommended to update the decoding table of every .savJ and .savE file even if you did not use any of those symbols. To update the decoding table of all save files you can use the CS -f script of Translation Toolkit or open the file, choose Edit > Decoding Table and select the table you want (not Table from Save).

User guide

Import a file:

  • Choose File > Import... and select the file. This process may take a few seconds.
  • Now you can start editing the file by entering text into the last column.
  • To save, choose File > Save As... or export an edited .binJ file by choosing File > Export....
  • A full explanation can be found on BinJ Editor Manual.

FTP Client:

  • Handy for directly sending the edited files to your 3DS for Luma to patch.
  • More on that can be found on BinJ Editor Manual.

Search Dialog:

  • Another useful tool which let's you search multiple binJ, e and other files at once.
  • More on this tool can be found on BinJ Editor Manual.

In the below section, you will find some examples screenshots from Dragon Quest Monsters 2: Iru and Luca's Marvelous Mysterious Key. Note that the first screenshot of each row is the original, the second one the translated (using BinJ Editor) and the third one the translated including a custom font and custom images (cannot be done using BinJ Editor).

Screenshots

BinJ Editor
binjeditor3.png

binjeditor4.png

Examples
binjeditor6.png

binjeditor7.png

binjeditor8.png

Changelog

v2.2.1

Changes:

  • Small bug fixes.
  • Update decoding tables.

v2.2.0

Additions:

  • Open and go to a search result by double clicking it.
  • Add menu option alternating colors.
  • Add menu option expert mode.
  • Implement wildcard search.

Changes

  • Rewrite internal structure.
  • Update decoding tables.

v2.1.0

Additions:

  • Add support for installed version with file associations.
  • Add go to line option.
  • Add close file option.
  • Add option to scale rows to contents.
  • Add icons for menu entries.

Changes

  • Improved editing behaviour.
  • Update decoding tables.

v2.0.0

Additions:

  • Add support for .e files.
  • Add search dialog (see Manual).
  • Add option to automatically scale rows to contents.

Bugs

  • Fix bug when using copy and paste actions while the table is sorted.

Decoding Tables

  • Change middle dot to katakana middle dot.
  • Allow input of j-ascii space, ¿ and ¡.

Release notes.

External links

Advertising: