Translator++ 3.6.18, Better experience for Renpy and KAG translation

Hello fellow translators,

This is a quick update notification for the latest version that you can download via auto-update.

Translator++ Ver. 3.6.18

  • Update : KAG ver 1.0 : Implementing ES tokenizer for TJS parser. TJS files are now parsed more accurately.
  • Update : RenParser ver 0.7 : Implementing Snippet viewer.
  • Update : ESParser ver 0.2 : Passing arguments to trans data.
  • Update : KAGParser : Completely overhaul the parser, using TyranoScript parser now
  • Update : KAGParser : TJS files are more accurately handled with ESParser.
  • Update : KAGParser : Embedded scripts are handled properly now
  • Update : KAGParser : Option to select character encoding when injecting translation
  • Update : RenParser : Beter parser, can properly handle heredocs now.
  • Update : RenParser : Loaded texts are evaluated now. No need to escape special characters on the grid now.
  • Add : Snippet viewer for KAG’s KS files
  • Add : Snippet viewer for KAG’s TJS files
  • Add : Snippet viewer for Renpy’s RPY files
  • Add : Snippet viewer for Renpy’s RPY files
  • Fix : object’s parameters are now sorted correctly when sanitizing trans data
  • Fix : Core file opener updated. Can handle unicode better
  • There are changes on the parser for KAG & Renpy, old trans files may not be able to inject or export with the new parser. Please refresh your project. https://dreamsavior.net/?p=1292

Snippet viewer for Renpy & KAG

Some time ago one of the Patrons requested a feature to let us view who is the actor (or who is currently speaking) on the translated line. I added that feature to the context menu. 

The actors or who is currently speaking is noticeable through the context.
Now we know that MC is the one talking in this line.

In addition to making it easier for us to find out who is speaking, this feature allows us to easily tag certain actors through the search menu.

We can batch-tag all MC’s line from search window.

But that alone may not be enough, sometimes to translate something we need to know the context of the conversation in the original script, just like the snippet viewer in RPG Maker MV & MZ. So the ability to view a snippet of the code would be a great addition into our translation experience.

So here it is, a snippet viewer for translated lines. It fully syntax-highlighted

With this, we now have no more reason to manually translate Renpy in the source code.

KAGParser is overhauled

After delving deeper into the KAG engine, I decided to overhaul KAGParser. Mainly because I was not satisfied with the performance of the previous parser. In previous releases I used AST Parser to parse kirikiri scenario files (KS files). The result is more accurate than the first parser I made in the early version of KAGParser… however, this new parser is very slooooow. Sometimes it takes tens of seconds to parse a single file.

Finally I decided to use the parser from TyranoScript (not to confuse with Tyrano Builder) which seems to be very stable now. This parser is much faster than AST Parser. And unexpectedly, after rummaging the source code, I find out that TyranoScript only uses the old school byte-by-byte parsing… no RegEx involved. This proves that sometimes you don’t really need an alien inscription or cthulhu-summoning-verses(red. Regex) to create a fast and accurate parser.

An important reminder for those of you who are translating KAG games. Because there is a change in the parser, so you need to refresh your project. You can read more about how to refresh your Translator++ project here.

Also, Just like Renpy, you can see a snippet of the scenario on the active line.

I made my own syntax highlighter for the KS script.

Of course, if you want to see the entire contents of the scenario file, you can open it directly via the context menu :

Right click on the snippet code to open context menu

Enjoy