|
1 |
| -# UnitySimpleLocalization |
2 |
| -Simple and fast package for working with localization of games and applications in Unity |
| 1 | +# Unity Simple Localization System |
| 2 | + |
| 3 | +**Unity Simple Localization** is a set of free and open source **cross-platform tools** to localize your games or applications powered by Scriptable Objects with Easy-to-Use components and string editor. |
| 4 | + |
| 5 | +**Requirements:** |
| 6 | +- **Unity 2019+**; |
| 7 | +- **TextMeshPro** for UI Localized Text; |
| 8 | + |
| 9 | +*Future updates will be contain an editor for non-string assets;* |
| 10 | + |
| 11 | +## Get Started |
| 12 | +**Unity Simple Localization** has own **Setup Wizzard**, **Locale Creation** and **Editing** tools, Localized Text, Image and Audio Clips Components. |
| 13 | + |
| 14 | +**Installation process:** |
| 15 | +- Download and import <a href="https://github.com/DevsDaddy/UnitySimpleLocalization/releases">latest release from this page</a>; |
| 16 | +- Run **Setup Wizzard**; |
| 17 | +- Edit your Locales; |
| 18 | +- See <a href="#usage">usage examples below</a>; |
| 19 | + |
| 20 | +**Configuration Using Setup Wizzard:**<br/> |
| 21 | + |
| 22 | +<br/>Using **Setup Wizzard** (Simple Localization -> Setup Wizzard) you can setup your Simple Localization Configuration buy few clicks. |
| 23 | +You can select default language, initialization method, fallback string and add available languages. |
| 24 | + |
| 25 | +**Locales Editor:**<br/> |
| 26 | + |
| 27 | +<br/>Using **Locale Table Editor** (Simple Localization -> Tables -> Edit Locale Table) you can setup your strings for localization. |
| 28 | +<br/><br/>**If you need localize Images or Audio Clips - use LocalizedImage component:**<br/> |
| 29 | + |
| 30 | + |
| 31 | +**Manual Setup:** |
| 32 | +You can disable initialization at startup and initialize your instance by code: |
| 33 | +```csharp |
| 34 | +Localization.Main.Initialize(LocaleDB configuration = null); // Setup Configuration |
| 35 | +``` |
| 36 | + |
| 37 | +## Usage |
| 38 | +**You can simply subscribe to localization switch event and manage your code using current language:** |
| 39 | +```csharp |
| 40 | +// Event |
| 41 | +Localization.Main.OnLanguageSwitched?.AddListener(YOUR_CALLBACK_FOR_EVENT); |
| 42 | + |
| 43 | +// Get Current Language Data |
| 44 | +var langData = Localization.Main.GetCurrentLanguage(); |
| 45 | +``` |
| 46 | + |
| 47 | +## Coming Soon (TO-DO) |
| 48 | +**I plan to add the following functionality in the near future:** |
| 49 | +- Editor for localized Images, Audios and other assets; |
| 50 | +- New Table editor for locale tables; |
| 51 | + |
| 52 | +## Join Community |
| 53 | +- <a href="https://discord.gg/xuNTKRDebx">Discord Community</a> |
| 54 | +- <a href="https://boosty.to/devsdaddy">Buy me a Beer (Boosty)</a> |
0 commit comments