Vladya

Description of the parameters and settings file.


Example of a setting file:

{
    "gameLanguage": "ja",
    "directionOfTranslation": "en",
    "modeOnStartup": "off",
    "_debug_mode": false,
    "translationService": "selenium_deepl",
    "workMethod": "dialogueOnly",
    "originalInHistory": false,
    "requestsFrequency": null,
    "splitTextAsSentences": false,
    "googleHost": "translate.google.com",
    "seleniumStartMode": "hide",
    "seleniumInputSplitMethod": "strings",
    "extraTextOptions": {
        "font": null,
        "size": null,
        "italic": false,
        "bold": false
    }
}




Parameter Description.

  1. gameLanguage: 1

    • “The original language of the game.” 5

    • The language of the game itself (from which you need a translation).

      • Language code from a specific service, or the name of the language in English.
        • Examples of valid parameters:
          • “en”
          • “en-GB”
          • “Portuguese”
          • “Polish”
          • “Chinese”
  2. directionOfTranslation: 1

    • “Direction of translation.” 5

    • The language in which to translate the game.

      • The format of the specified data is identical to parameter gameLanguage.
  3. modeOnStartup: 1

    • Translator mode at game start.

    • The following 4 parameters can be used:

  4. _debug_mode: 2

    • “Debug mode.” 5

    • When this option is activated, translator work changes as follows:
      • If an error occurs, traceback will be raised.
      • Logging of the translator’s actions will be enabled.
    • Except in special cases, you should not activate this option.
  5. translationService: 1

    • “Translation service.” 5

    • The service that will do the translation.
    • The following values are valid:

      • “google_gtx”:

        • Non-browser logic.
        • The service with the best (among non-browser) translation quality.
        • Since Google bans on suspicion of automation, the request frequency is forcibly reduced to 8 requests per minute.
      • “google_client5”:

        • Non-browser logic.
        • A service with poor translation quality but good speed.
      • “google_rpc”:

        • Non-browser logic.
        • Completely identical to “google_client5”, but with the ability to change the service host (parameter “googleHost”).
      • “selenium_deepl”:

        • Browser logic.
        • Service with the best, among the presented, translation quality.
        • There are disadvantages, typical for translators with browser logic.
          • You can read more in the relevant section in the FAQ.
  6. workMethod: 1

    • “Method of work of the translator.” 5

    • Translator’s work method.
    • The following values are valid:

      • “dialogueOnly”:
        • “Translation of dialogs and choice menus.” 5
        • Translator will use parameter config.say_menu_text_filter to work.
        • The main text (in the dialog box) and the choice menu will be translated.
        • In most cases it is recommended to use this parameter.
      • “allText”:
        • “Translation of all text in the game (Beta).” 5
        • Translator will overwrite the built-in Text.set_text method.
        • All displayed text on the screen will be translated.
        • The mode is in beta stage and is not recommended for use unless absolutely necessary.
        • Since when this option is activated all the text on the screen will be translated, it is possible long “freeze” in the game.
        • Absolutely contraindicated for use if the game demonstrates dynamic data.
          • Such as:
            • Time.
            • Changing a character’s stats.
            • etc.
          • Because the translator will try to translate each of the new values, which will cause the process to freeze completely.
  7. originalInHistory: 2

    • “Save the original text in the history.” 5

    • If this option is enabled, the “history” screen will display the original text instead of the translation.

  8. requestsFrequency: 3

    • “Frequency of requests.” 5

    • Frequency of requests to the translation service.
      • Number of requests per minute.
    • For some translation services, the value is fixed and unchangeable.
    • For services with browser logic the value is ignored.
  9. splitTextAsSentences: 2

    • “Split sentences during translation.” 5

    • If this option is activated, the text will be divided into “sentences” according to the following pattern before translation:

        # Python RE logic.
        r"(?P<text>[^!?….\r\n]+)(?P<end_mark>[!?….]*)"
      
    • Some translation services (e.g. google_client5) return an incorrect translation if there are excessive punctuation marks in the text. This setting prevents this from happening.
    • In some services, this parameter is activated by default and a user value is ignored (for example, in the previously mentioned service google_client5).
    • It is not recommended to activate this option.
      • In those services where it is required, it is activated by default.
  10. googleHost: 1

    • Host for translation service google_rpc.
      • When selecting other services, this option will be ignored.
    • For countries where the standard translate.google.com does not work correctly (or slowly).
    • For example:
      • For Latvia:
        • “translate.google.lv”
      • For China:
        • “translate.google.cn”
      • And so on.
  11. seleniumStartMode: 1

    • Browser startup mode for services with browser logic.
      • Read more about the browser logic in the relevant section in the FAQ.
    • The following values are valid:
      • “hide”:
        • The browser will run as a background process and will not interfere with the taskbar.
      • “default”:
        • The browser will start in default mode (as if it were started by the user).
          • When restarting, the browser will also return to default mode, even if the user minimizes the window.
      • “minimized”:
        • Identical to parameter “default”, but, after starting, the browser is minimized.
    • Important:
      • Since the browser logic is automated, user intervention (as in the examples below) can interfere with correct work:
        • Clicking buttons on pages.
        • Opening tabs.
        • Closing the browser window.
        • etc.
      • In the case of such user intervention complaints about incorrect work are not accepted.
  12. seleniumInputSplitMethod: 1

    • Split input text mode, for services with browser logic.

    • The following values are valid:

      • “all”:
        • All text will be entered at once.
        • It may freeze if the text is large.
        • Browser automation may be detected.
      • “strings”:
        • The text will be entered line by line.
      • “symbols”:
        • The text will be entered character by character, with no pause between entries.
      • “humanTyping”:
        • Simulated human input with an average typing speed of 450 characters per minute (the real value is randomized).
  13. extraTextOptions:

    • “Settings for the displayed text.” 5
    1. font: 1

      • “Font.” 5
      • The font with which the text will be displayed.
      • The path to the font file is set relative to the folder “%NovelDir%\game”, where %NovelDir% is the folder with the game.
        • For example, the font is in a folder:
          • “C:\Games\MyNovel\game\fonts\Comic Sans.otf”
        • So in the file you have to write:
          • “fonts/Comic Sans.otf”
            • All backslashes (\), if present in the path, should be replaced by forward slashes (/).
      • Selecting a font once does not have to be repeated for every game.
        • All used fonts are cached.
          • If you specify in another game a font that was already selected earlier, the file will be added automatically.
          • You can also select a font in the GUI4 under “Pick from the previously used ones”.
    2. size: 1

    3. italic: 2

      • “Italic text.” 5
      • When this option is activated, italicizes the displayed text.
    4. bold: 2

      • “Bold text.” 5
      • When this option is activated, it makes the displayed text bold.
  1. A text data type. A value escaped by quotation marks is expected.  2 3 4 5 6 7 8 9 10 11

  2. Boolean data type. true/false.  2 3 4 5 6

  3. Positive numeric data type. A number from a set of positive real numbers is expected.  2

  4. Graphical User Interface. The setting window that shows up in the game.  2 3 4

  5. Parameter name in the GUI.  2 3 4 5 6 7 8 9 10 11 12 13 14 15