-
Notifications
You must be signed in to change notification settings - Fork 178
Localization
OpenHogwarts edited this page Dec 24, 2017
·
5 revisions
Do you want to translate the game to another language?
Just send a PR (pull request) with the following changes!
- Edit LanguageManager.cs#L22 (availableLanguages var) and add your language (options list: https://docs.unity3d.com/ScriptReference/SystemLanguage.html)
- Add the translation here: https://github.com/OpenHogwarts/hogwarts/tree/master/Assets/Resources/i18n
Don't worry about the .meta file, it is autogenerated by Unity.
- Edit it's
.jsonfile: https://github.com/OpenHogwarts/hogwarts/tree/master/Assets/Resources/i18n
- To translate a
UnityEngine.UI.Textcomponent, simple addLocalizedTextcomponent too and set the label translation onTextcomponent. - For incode translation =>
LanguageManager.get("PHRASE_HERE")