Search Unity

[WIP] Gamestrap Localization System

Discussion in 'Works In Progress - Archive' started by Rodiaz89, Jun 17, 2016.

  1. Rodiaz89

    Rodiaz89

    Joined:
    Apr 11, 2014
    Posts:
    136
    Hey everyone,

    I've been working on a new localization system for Unity, I know there are a couple already out there but I was looking for a simpler solution and I couldn't find one that I really liked so I decided to make one since I'm the owner of Gamestrap UI and I think these two packages could work well together.

    I'm looking for feedback before publishing the asset so please if you've ever had the need for a localization asset give me your comments!

    Features
    • Localize your application to any language
    • Localize texts, audio and images
    • Simple to use UI
    • Pre-made components for you to use in your text, audio, textures
    • Changes are shown in the editor
    • Export/Import to JSON/CSV
    • Modularize your Localization packages so not everything is in one place
    • Load the content through externally through an API or a static file on the web.
    Here is an example of how it works in the editor
    Editor.gif

    This is the way you set up the content
    You open the window and select the Localization asset you created.
    Screenshot-Window.jpg

    and then you can create your own keys,
    Languages.gif
    you can also see on the right that you can read a json file from an API.

    You can also localize Audio and textures
    Screenshot Audio.jpg

    You do need a gameobject with the Localization component and data assigned to it to work.

    You can also access the localization system through code like this:
    Code (CSharp):
    1. Localization.Current.GetText("name of the key");
    2. //OR
    3. Localization.Current.GetText(key_id);
    You can also register to see when the selected language changes:
    Code (CSharp):
    1.     public void Start()
    2.     {
    3.         Localization.Instance.OnLanguageChange += OnLanguageChange;
    4.     }
    5.  
    6.     public void OnLanguageChange(Language language)
    7.     {
    8.         if (language != null)
    9.         {
    10.             TextSource.text = language.GetText(id);
    11.         }
    12.     }
    Hopefully this is enough to show you the basics of how it works. I'm looking for feedback and first impressions to see what else I should add.
     
  2. GilbertoBitt

    GilbertoBitt

    Joined:
    May 27, 2013
    Posts:
    111
    amazing! i was thinking about this... really cool asset! when u think will be available to us all poor mortals? and i think u should be supporting PO files too! don't you? and great idea let the developers use remote load translation.. but don't u think put booth together.. like when we want to play but we don't have internet acess and let it player a old loaded translation file. and when the player connect to the remote translation update the local one.. to the players always be able to play.. without the always on login need internet to download translation..

    and for better use of unity i think you should add a simple "keys" editor and selection on the text components.. so the developer don't need always go to your editor to add a new key and translation.. but when he create a text/audio/image he will see a button on the component activate localization translation or something similar and if he active it the translations options like keys.. and using this component window he be able to edit every text/audio/image specify from each translation and on your window there he will be able to edit from there.. but add new languages only from your big windows. i will make something on photoshop to u understand.

    Sem Título-1.png

    like this.. i think for big games is better than enter always on the big window of yours to edit the text on certain localized text.. i not saying u to remove the one u use.. but add this too to better and faster edition while we r building our interfaces or mesh text... and u should consider let compatible with text plugins like the Text Mesh PRO! when i have more time i comeback to more feedback!
     
    Rodiaz89 likes this.
  3. Rodiaz89

    Rodiaz89

    Joined:
    Apr 11, 2014
    Posts:
    136
    Hey thanks for the great feedback, so to answer your questions:
    Not sure yet, it's still in progress, this is the first time I've published the concept so it depends on the feedback. But the idea is to have it up by the end of July fully commented, documented, tested, etc...
    Not sure, I'll have to look at the details but it should be doable, is there any advantage for you to use PO files instead of CSV or JSON files?

    Yeah hadn't realized that, I'll be adding this feature soon, just didn't want to overcrowd the UI but I'll look into it.

    Definitely, those types of compatibility should be simple to implement and I'll do them when people request them.

    Thanks again for the feedback :)
     
  4. GilbertoBitt

    GilbertoBitt

    Joined:
    May 27, 2013
    Posts:
    111
    @Rodiaz89 Po files r used to controll localization systems u can even find auto translators for specify language using po files to edit and update.. take a look https://poeditor.com/ so u can see how it work and how is better for translations and localizaded language systems.. po files r used on many CMS, Blogging frameworks and on..
     
    Rodiaz89 likes this.
  5. Konsicrafter

    Konsicrafter

    Joined:
    Mar 5, 2016
    Posts:
    4
    Hello,
    I just purchased the Localization asset and after importing into unity 5.5.1f1 64Bit
    I get three compiler errors:

    Assets/Gamestrap/Editor/UIIcons.cs(20,51): error CS0117: `Gamestrap.TextureLoader' does not contain a definition for `Load'

    Assets/Gamestrap/Editor/UIIcons.cs(30,53): error CS0117: `Gamestrap.TextureLoader' does not contain a definition for `Load'

    Assets/Gamestrap/Editor/UIIcons.cs(40,52): error CS0117: `Gamestrap.TextureLoader' does not contain a definition for `Load'

    How to fix the errors? I think the "Load" method is broken or not existing
     
  6. Rodiaz89

    Rodiaz89

    Joined:
    Apr 11, 2014
    Posts:
    136
    Hey Konstantine,

    I got your email and sent you an answer, the issue was that I hadn't updated Gamestrap Localization in the asset store so it could work with some updates in Gamestrap UI. I sent you the package with the fix. Sorry for the trouble and thanks for letting me know about it, I completely missed it!
     
    Konsicrafter likes this.
  7. Konsicrafter

    Konsicrafter

    Joined:
    Mar 5, 2016
    Posts:
    4
    Hello,
    thank you for your help. It seems, like I didn't get your email. Did you send it to "Konsicrafter@web.de"?
     
    Rodiaz89 likes this.
  8. Rodiaz89

    Rodiaz89

    Joined:
    Apr 11, 2014
    Posts:
    136
    Now I did :)