• With over 20,000 games created, The most widely used novel game engine.

What is the Localization (Translation) Feature?

This feature requires TyranoScript V600 or later.
A plugin is also available for versions before V530 to enable translation features.

TyranoScript provides a powerful translation feature for localizing games for international audiences.

- Automatically extracts translatable text
- Switch languages freely in a single build
- Automatically detect and set language based on the player’s environment
- Export translations as CSV for editing in tools like Excel

You can switch between any languages.

(Examples)

  • Japanese → English
  • Japanese → Chinese
  • English → Japanese
  • English → Chinese
As you can see, it supports a wide range of languages.

Let’s try it out!

Download TyranoStudio

First, download the latest version of TyranoStudio that supports the translation feature.

>>Download the latest TyranoStudio

Then load your TyranoScript project as usual.

Using the Translation Feature

Let’s try translating to English for this example.

First, create the language you want to localize into.
From the left menu, click "Development" → "Translation" → then click "Add Language".



Enter a language code using alphanumeric characters.
For example: English = "en", Chinese = "ch", Japanese = "ja", etc.




Once added, select "scene1" from the scenario list on the left.
You’ll see the game script has been automatically parsed and displayed.




Let’s begin translating.

Double-click a blank cell to edit and enter the English translations in the left column.
When you're done, click the "Save" button in the lower right.



Now let’s preview the results.
To apply the translation in-game, use the [lang_set] tag.

Open first.ks and add the following script wherever you’d like:


[lang_set name="en" ]
Save and preview the game.


Your game is now running with the English translations. It’s that easy to create localized versions!

Translating Character Names

Click "Character" to see a list of characters used in your game. You can input their translations just like before.



Once saved, the translated names will appear in-game as well.

Register Tags You Want to Translate

You may also want to translate things beyond dialogue—like choice options or button labels.

Use the "Tag Registration" feature for that.

Click the gear icon in the top right corner.



Here, you can register tag names and parameters to extract for translation.
By default, tags like glink and ptext are registered.

For example, if you created a macro like:

[mymacro value="Translate this"]

Click "Add" and register the tag as “mymacro” with parameter “value” to extract “Translate this”.

Don’t forget to click "Apply Settings" to finalize.

Exporting and Importing CSV

You can export to CSV and edit with Excel or other tools instead of using the editor UI.

Use the buttons in the top right corner of the translation screen to import or export.



Conditional Behavior Based on Language

Sometimes the built-in translation tool isn’t enough—especially for images with embedded text or when more explanation is needed for a certain language.

In those cases, use the [if] tag to conditionally change behavior based on the selected language.


[if exp="TYRANO.kag.lang==='en'"]
Processing for English[p]
[elsif exp="TYRANO.kag.lang==='ch'" ]
Processing for Chinese[p]
[else]
Processing for other languages[p]
[endif]

The currently selected language from [lang_set] can be accessed via TYRANO.kag.lang.
This lets you fully customize behavior for each language.

Automatically Detect and Set Language Based on User's Environment

You can automatically detect the user’s language and apply it using the code below:


[iscript]
// Get user's browser language
var lang = navigator.language;

// Set to default if unsupported
sf.select_lang="default";

if(lang.indexOf("en")!=-1){
	sf.select_lang = "en";
}
[endscript]

[lang_set name="&sf.select_lang"]

The value returned by navigator.language will vary by environment, so be sure to test the values it returns for your supported languages.

Let Users Choose a Language and Save the Setting

You can also let players choose their preferred language via a language settings screen.
The [lang_set] tag can be used at any time, so switching languages within a single build is easy.

To make sure their choice is remembered on the next playthrough, store it in a system variable like this:


[iscript]
if(!sf.selected_lang){
    // If not set, use default
    sf.selected_lang="default";
}
[endscript]

[lang_set name="&sf.select_lang"]
Then, when a user selects a new language, just store it into sf.selected_lang.

Using Translation in Older Versions (Before V530)

If you can't upgrade to a newer version of TyranoScript for some reason, there's a plugin available that enables translation features in older builds.

Download the translation plugin

For detailed instructions, refer to the included readme.txt.