Search Unity

I2 Localization ( The most complete Localization solution for Unity )

Discussion in 'Assets and Asset Store' started by Inter-Illusion, Feb 27, 2014.

  1. Pyroman311

    Pyroman311

    Joined:
    Aug 14, 2010
    Posts:
    87
    Ahh okay cool. Been quite awhile since I used TMP...

    Thanks!
     
  2. MardukCorp

    MardukCorp

    Joined:
    May 21, 2016
    Posts:
    68
    @Inter-Illusion It seems you missed my question one page before this. I also send you an email 1 week ago and I saw that the one from someone else ended up in the spam folder. Please double-check your mails!
     
  3. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Hi,
    That could because of a few things:

    - The most common cause, is when updating from an old version of I2 Localization, sometimes the Unity package doesn't install as expected and there are left over files that shouldn't be there.
    To solve this, do a clean install (i.e. Delete the Assets\I2 folder and reinstall the plugin). That will remove any extra files and all will be setup right.

    - Also, when the TMPro target is now enabled, but it was in the previous unity version/project, then it will show that error.
    This can be solved by verifying that the targets are enabled correctly (sometimes doing Force Detection will solve this quickly)
    inter-illusion.com/assets/I2Localization...lizationTargets.html
    And verifying that the Localize component detected TMP for the object and not showing "Prefab" as the target. If it shows "Prefab", then, you should click in the popup and change the target from Prefab to TextMeshPro.

    Hope that helps,
    Frank
     
  4. MardukCorp

    MardukCorp

    Joined:
    May 21, 2016
    Posts:
    68
    @Inter-Illusion Thank you for the instructions!
    Did you also had time to check for my last mail I sent you (3. December)? It was about a different issue.
     
  5. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Hi,
    I missed your email in all the feedbacks from the sale! Sorry.
    I just replied to it.

    Hope that helps,
    Frank
     
    MardukCorp likes this.
  6. IronHelmet

    IronHelmet

    Joined:
    May 2, 2017
    Posts:
    19
    Hello Inter-Illusion,

    We are on unity 2017.4.3f1 and currently using I2 2.6.5 f5.

    I was thinking of updating our I2 plug-in to the latest version, do you know if its backwards compatible all the way back to 2017.4.3?
     
  7. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Yes, I2 Localization 2.8.10 is compatible with Unity 5.4.3 and higher.
    So, it will work fine in 2017.4.3, 2018 and even the 2019 alpha.

    Said that, if you find any issue, please let me know and I will try to solve it asap

    Hope that helps,
    Frank
     
  8. IronHelmet

    IronHelmet

    Joined:
    May 2, 2017
    Posts:
    19
    There were two minor issues. I think the coroutine manager moved and the update process didn't catch it, and something about a Debug.LogErrorFormat which i just changed to Debug.Log. I can dig back into what I did if you need more details.
     
  9. StefanoCecere

    StefanoCecere

    Joined:
    Jun 10, 2011
    Posts:
    157
    last update broke all my translations, since the words key can't have anymore a "." in them.. i2 automatically converted all database removing the "." and breaking my app.

    i renamed all "." to "_" and relinked all translation instances.

    i din0t read any notice about this huge breaking change!
     
  10. MrLucid72

    MrLucid72

    Joined:
    Jan 12, 2016
    Posts:
    665
    How last is "last" update? Did the recent beta just get out on the store?

    Also: The "Add Term to Source" button is broken:



    It really isn't in source -- BUT! Even though I exported, it's actually in my Google Sheets!



    This is so confusing -- how come it's in my recently-sync'd Google Sheet, but not in source? If I exported, then why is the entry above still there? Either way, it's not added to source. It's extremely out of sync. And why does this button not do anything?

    I tried to "export new", but that didn't seem to do anything.

    ______________________

    Then there are these random tabs at the bottom that seem to be made by a bug, probably due to rich text? I can't see anything in the docs about this, so I'm going to assume this isn't supposed to be there:



    I'm using the latest beta, which was hoping to resolve some issues, but it seems like it introduced more :/
    ______________________

    I'm running into so many bugs and after several weeks, I'm really struggling with the asset stability. Is this working 100% for anyone?
    ______________________

    EDIT: I tried deleting both of my languages, export replaced to google sheets. All terms/languages are still there. Seems like sync is broken? Which would explain a great deal of the issues I'm having :/ web service says it's verified:


    ______________________

    EDIT 2: I made a new sheet >> Only added ONE term >> I export replace >> it adds 473 terms. What is going on with this sync?
     
    Last edited: Dec 17, 2018
  11. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Hi,
    The button is not broken, it just doesn't allow adding terms with those characters. Only letters, numbers and '_' is allowed.
    I see you are using 2.8.10a1 in that example. As you can notice, in 2.8.10a1 made a fix for not allowing weird characters as it can create problem with exporting and in general. Then, in 2.8.10a2, that was even extended so that the characters are never detected (that way, the "Add Term to Source" will now show "<< Chat? Questions" in your example, but "Chat Questions").

    2.8.10f1 is now live in the AssetStore, if you should not get any weird character. (But notice that you will have to delete the bad terms from your source and add them again for them to be right)

    As some of your terms had '/' in their name, the plugin assumed you wanted to set them as categories (e.g. "Tutorial/Title") so it created a tab for each category.
    In your case, you created terms like "<b><u>Experiment</b> xxx" and the plugin created a category "<b><u>Experiment</" with a term in there "b> xxx".

    Now with 2.8.10f1 those characters are discarded so, shouldn't create the categories.

    If you open you LanguageSource and delete the "Languages", you are still holding ALL your terms, you just made them not translated to any language.
    To delete the term, you need to select ALL your terms and click delete. No need to delete the Languages.

    That is the expected behavior as no term was deleted.

    Hope that helps,
    Frank
     
  12. tazerg

    tazerg

    Joined:
    Oct 21, 2017
    Posts:
    2
    Hello,
    I use version 2.8.9 f1 and sometimes I need to set the <none> term. Above it was said that you can use SetTerm(null) but now it does not work. Tell me what can I use?
     
  13. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Hi,
    What do you mean by SetTerm(null) doesn't work?

    When you set the <none> as a term, you are actually setting the term "-" which indicates the plugin to ignore that term and not localize that (Primary or Secondary) target.

    If you instead, want the plugin to discard the term and infer a new one from the label's text, then you should use "" or null. (In the Localize inspector it will show as "<Infer term from target>"

    that way:
    cmp.SetTerm("-"); // Ignores the term and skip localization of this target
    cmp.SetTerm(null); // reads the label's text and tries to find a term that matches that text, then use that term from now on

    Is that not working as expected?
    If not, can you please, list the steps you are using the reproduce the issue. I will try it on my end and let you know why its happening.

    Hope that helps,
    Frank
     
  14. hammertime2014

    hammertime2014

    Joined:
    Jan 16, 2014
    Posts:
    6
    Just bought this asset today, found a possible compile issue when using NGUI (we have a legacy project)

    In NGUI_LanguagePopup.cs
    Code (CSharp):
    1. public LanguageSource Source;
    2.     void Start ()
    3.         {
    4.             UIPopupList mList = GetComponent<UIPopupList>();
    5.             mList.items = Source.GetLanguages();  // PROBLEM HERE  
    LanguageSource does not implement the function GetLanguages()

    Is there a patch or an update please?
    thanks
    amir
     
  15. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Hi, sorry about that, There is indeed an issue with NGUI and I2Localization. Will submit a fix for that later today to the beta folder.
    In the meantime, you can fix that popup by changing the line to:
    Code (csharp):
    1. mList.items = Source.mSource.GetLanguages();
    Hope that helps,
    Frank
     
    SweatyChair, clobo and hammertime2014 like this.
  16. hammertime2014

    hammertime2014

    Joined:
    Jan 16, 2014
    Posts:
    6
    Perfect Frank, was just in the middle of fixing it myself, thanks dude.
     
  17. Alex3333

    Alex3333

    Joined:
    Dec 29, 2014
    Posts:
    339
    Good afternoon. I have real-time generated objects in the boxes. And I get bursts (screen). If a large number of boxes, the game just freezes for a very long time. how to solve it?
     

    Attached Files:

  18. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Hi Alex,
    One thing I see strange is that the function LocalizeAll is been called.
    When an object having a Localize object is instantiated, that component calls Localize in the OnEnable or OnAwake (depending on the settings), but not LocalizeAll.
    Are you calling that function from any of your scripts? (e.g. LocalizationManager.LocalizeAll()) ?

    If you are not calling that directly, is this happening only once, when you enter the game? I'm thinking that it maybe cause by the plugin downloading data from google (if Google Update Frequency is set to anything other than NEVER). When the plugin finishes downloading the new data, it calls LocalizeAll so that every Localize component in the scene gets updated.

    If thats the case, you may want to extend your loading screen until that function is already called. You can use the following event to know when the data is already downloaded and applied:
    LocalizationManager.Sources[0].mSource.Event_OnSourceUpdateFromGoogle

    If this happens all the time you instantiate a new object. Can you please let me know what exactly are you localizing in the instantiated objects? Are there UI texts, Prefabs, MeshRenderers? Are you just changing the text or also fonts, images, meshes?

    What version of I2 Localization and Unity are you using? In the latest release there is a tweak to avoid releasing resources after every LocalizeAll and only do it while loading a new scene unless manually called.
     
  19. Alex3333

    Alex3333

    Joined:
    Dec 29, 2014
    Posts:
    339
    Can you help by Skype? I cannot solve this problem for several months. I translate only the text that is in the prefab.
     
  20. Alex3333

    Alex3333

    Joined:
    Dec 29, 2014
    Posts:
    339
  21. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Hi,
    There is a solution in both, my previous post here and in the one you are referencing
    (http://inter-illusion.com/forum/i2-localization/1223-performance-hits-when-updating-from-google#3356)

    What seems to be happening (at least in the post you mentioned), its that the Google Live Synchronization is enabled, and after the game is running, the plugin finishes downloading the Spreadsheet and has to Localize everything in the scene.
    Localizing all is very light and should cause no hitches by itself, BUT, depending on the targets used, it can get quite expensive given that unity may have to be loaded and if using Unity UI Texts, there can be new characters that need to be baked by Unity in the font atlas, so it has to regenerate it).

    To solve that hitch, you can do either of the following two things:
    1- Disable Google Live Synchronization by setting the update frequency in the Google Tab to NEVER. Or make it happen infrequently (e.g. WEEKLY instead of ALWAYS)

    or

    2- Don't start the game until the plugin finishes downloading the data and localizing all. You can hide that in your Loading Screen and as soon as the following event is called, hide the loading screen and start the game.
    LocalizationManager.Sources[0].mSource.Event_OnSourceUpdateFromGoogle


    My advice is to try first to disable Google Live Synchronization (i.e. make the update frequency NEVER). Then, if that fixes the problem, set it to WEEKLY.

    Another thing to notice, if you are not using the latest AssetStore version (v2.8.10), you should as it removed one Resources cleaning call that was causing a hitch if materials or fonts were loaded. That could also be the source of your hitch if using an earlier version.

    Now, said all that. I'm finishing a new feature for the next release that exposes a parameter to control when the LocalizeAll is called after the data is downloaded (e.g. As soon as it finishes, While a new scene is loaded, Only when manually requested).
    That way it can be easy to delay the hitch of switching to the new data to the moment when the game is not running and the game is loading the new level.

    I'm hoping to have that feature finished in the next few days after I get back from the holidays. I will try to upload it to the beta folder as by the end of the week or the weekend.

    Hope that helps,
    Frank
     
  22. 5argon

    5argon

    Joined:
    Jun 10, 2013
    Posts:
    1,267
    Could previewing also preview "Secondary" changes? Currently to localize a TextMeshProUGUI, I would put the terms on the first tab and different TMP asset on the Secondary tab.

    Clicking the language name would preview the localization and that's nice, but the secondary tab is not taking effect making it previews into a bunch of rectangles as the font texture do not get switched.

    Only way to enable preview in all languages is to use just one TMP asset and use fallback font system when the character is missing, so it go to other TMP asset automatically even when the connected asset is not the one.

    But I believe falling back is not an approach to localization as fallback TMP asset inherit line height from the root asset. If I use TMP asset in Thai language with line height and ascender to support the language and have it fallback to English, I would get a too-spaced out when the game is in only English. That means falling back is for supporting "occasional missing texture" like emoji, or some number letters when the root asset does not have it. Like a safety net. Not as a localization. Like, intentionally miss the Japanese character in this font, in order to have it choose the other font. That will make the proper line height of that Japanese font ineffective.

    Thus, what I2Loc can do (changing the font field, and not relying on fallback, so that line height also changes according to language) is the solution. Only if it can preview the secondary tab everything would be perfect!
     
  23. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Hi,
    I just tried previewing TMP texts and it does seem to change the Font as well.
    To try it, I opened the Example scene and switched between the languages to verify that both the text and the font was been changed.
    TMPFontChange.gif

    Can you please make an example scene that reproduces the issue you are experiencing and email it to me? Or list here steps I could use to reproduce the problem.

    Thanks,
    Frank
     
    5argon likes this.
  24. 5argon

    5argon

    Joined:
    Jun 10, 2013
    Posts:
    1,267
    Oh.. after closing and open Unity it does change the secondary as well. Nice!

    Also I would like to ask where is the settings for default language that I2Loc seems to keep reverting to? Mine is currently Japanese, but I can't remember I have set that up somewhere. (Like, when you preview some languages and you are done, you click on other things and it seems to changes to Japanese automatically.)
     
  25. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
  26. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    BTW, I made the change and uploaded the new version to the beta folder. (2.8.11a3)
    Now there is an option to control when to apply the downloaded changes)
    upload_2018-12-26_17-16-36.png

    By default is OnSceneLoaded, which will hide the lag produced by applying all the translation to a point when the loading screen is shown or a loading lag is expected as part of loading a new level.

    When setting to Manual, the user full control to when applying the downloaded data, it has to call LocalizationManager.ApplyDownloadedDataFromGoogle()

    Hope that helps,
    Frank
     
    Alex3333 likes this.
  27. 5argon

    5argon

    Joined:
    Jun 10, 2013
    Posts:
    1,267
    In v2.8.11 a3 with 2018.3.0f2, the Open Source does not work.. because the file is LanguageSourceAsset and not LanguageSource.

    Screenshot 2018-12-27 15.16.25.png

    Localize.cs
    Line 44: Change to LanguageSourceAsset

    LocalizeInspector.cs
    Line 706, 727, 745 : Change to LanguageSourceAsset
     
    Alex3333 likes this.
  28. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Sadly, its a bit more complicated than that.

    The source can either be a LanguageSource component or a LanguageSourceAsset scriptableObject. The current solution worked fine for when the source was pointing to a LanguageSource object in your scene (which is mostly when only you should set it in that field).

    Said that, it was bothering me as well, that when set to none, it was not opening the I2Languages asset as in the releases before the new Prefab system. So, I went and refactor the code there to handle both cases.

    The new changes can be downloaded now (v2.8.11a4)

    Hope that helps,
    Frank
     
    5argon likes this.
  29. 5argon

    5argon

    Joined:
    Jun 10, 2013
    Posts:
    1,267
    Thanks, one more question about reference localization.

    For example my secondary tab has TMP font localization. When I want to reuse that terms on an another text, the asset fields are empty but with little names nearby. I need to reassign the font for every place I want to reuse the term with reference. Is this normal? I notice that when I put back the font in English font, the Thai font also resolve itself because it use the same thing.

    Screenshot 2018-12-29 10.05.12.png

    I kind of get it if the references are scene objects, because that would be scene-dependent and better you have to store references (in the References box below) per Localize game object. But in this case all the references are Assets from the project folder, it would be great if the localization can remember the asset. (Like keeping the GUID of the asset ?)
     
  30. Alex3333

    Alex3333

    Joined:
    Dec 29, 2014
    Posts:
    339
    You wrote that you can download the new version. but the store is still the old version. Where is the link to the new version ??(v2.8.11a4)
     
  31. Alex3333

    Alex3333

    Joined:
    Dec 29, 2014
    Posts:
    339
    Who can tell? where can I download besides the store a new version(v2.8.11a4)? somewhere you need to register or on some kind of closed forum?
     
  32. 5argon

    5argon

    Joined:
    Jun 10, 2013
    Posts:
    1,267
    Alex3333 likes this.
  33. 5argon

    5argon

    Joined:
    Jun 10, 2013
    Posts:
    1,267
    I have yet another question. I notice that I2Loc put a "supported language list" on the storefront automatically at some stage when I build the game. However for example I have added Korean localization as a placeholder not an official supported language yet (in the game you cannot select Korean) but in app stores it shows in the download page as supporting Korean which could be misleading. How can I tweak this behaviour?
     
  34. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    As part of the build process, all ENABLED languages are added to the localized values (in Android) or the plist (in IOS) so that the store description show the game as supporting those languages.

    If you added a language to your game (even if there is no button or popup to change to that language), it will still be reported to the Stores.

    To avoid that, you need to disable the languages. See in the next image that Hebrew is disabled and so it will not be reported to the Store.
    upload_2019-1-9_13-8-46.png

    Hope that helps,
    Frank
     
    5argon likes this.
  35. Philkrom

    Philkrom

    Joined:
    Dec 26, 2015
    Posts:
    41
    Hi
    Is there anyway to update I2 translations from a spreadsheet with a PC (build) version (with the computer connected to Internet of course) ?
    Thanks for your fantastic asset !
     
  36. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    The plugin does that automatically.

    If you place your translations in a Google Spreadsheet, and enable Google Live Synchronization in the plugin, then, any change made to the spreadsheet will be automatically downloaded into your players devices (PC, Android, IOS, etc).
    http://inter-illusion.com/assets/I2LocalizationManual/GoogleLiveSynchronization.html
    Here is a video showing this is action:


    If instead of using a Google Spreadsheet, you want to store your all your translations in a CSV Spreadsheet and place it in your own servers, then you can use an script similar to this one to download it at runtime.
    http://inter-illusion.com/assets/I2LocalizationManual/ImportingaCSVfile.html

    Hope that helps,
    Frank
     
  37. justtime

    justtime

    Joined:
    Oct 6, 2013
    Posts:
    304
    Hi there! After adding new lang, i clicked translate, but nothing happens. It's 251 rows to translate, may be too much?
     
  38. diegoadrada

    diegoadrada

    Joined:
    Nov 27, 2014
    Posts:
    53
    Hi, for some reason I had some term like:
    "(Ringing...) Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua."
    That is something that I can not change.

    Since I updated the plugin to 2.8.11 f1, I'm not being able to access that term :

    Code (CSharp):
    1. I2.Loc.LocalizationManager.GetTranslation("(Ringing...) Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.");  
    This returns null.

    I have changed the term key in Google Spreadsheet to something like "lorem", in that case it works just fine, the problem is when the term is that long. Any idea what is happening? Thanks!
     
    Last edited: Feb 3, 2019
  39. IronHelmet

    IronHelmet

    Joined:
    May 2, 2017
    Posts:
    19
    Hello Frank!

    This week I noticed that when I create a Game Object in a canvas with a Text Mesh Pro UGUI component and then add the Localize component, I get a warning in the console..

    "The referenced script on this Behaviour (Game Object '<null>') is missing!"

    (The TMP component without localize doesn't produce the warning)

    We are on Unity 2017.4.3.f1 and I2v2.8.10f1
     
  40. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Yes, the problem is that terms are not allowed to have the comma symbol. Recently I changed the symbols allowed in the term's name, because there were cases where new lines, control characters and other bad unicode chars were getting added which was breaking import/export from spreadsheets.
    Terms can have any letter or digit, plus the following symbols .-_$#@*()[]{}+:
    But that is too restrictive, so in the next update I have added more valid symbols.

    In the meantime, you can change that by adding the ones you need to the ValidNameSymbols array in the
    Assets\I2\Localization\Scripts\Utils\I2Utils.cs file line 14


    Just to check: Is TextMeshPro enabled as a target?
    http://inter-illusion.com/assets/I2LocalizationManual/EnablingLocalizationTargets.html
     
    diegoadrada likes this.
  41. diegoadrada

    diegoadrada

    Joined:
    Nov 27, 2014
    Posts:
    53
    Thanks for your help, with this I'm able to work with that term, but now I have problem with terms that has "..." for example "Right now… Do it now!".
    At some point the plugin is removing the "..." and this is replaced by a single space " ", if I do a Debug, that term is now: "Right now Do it now!".
    Should I do a downgrade to an older version of the plugin?
     
  42. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Hi,
    I just verified that changing the ValidNameSymbols prevents the ... from being converted to spaces (just be sure there is a point (.) in that array.

    I change the code to have correct settings and upload v2.8.11f2 to the beta folder (you can download it from there right now). I'm also going to send it to the AssetStore but it can take a few days for the update to be reviewed and approved.
     
    Last edited: Feb 4, 2019
    diegoadrada likes this.
  43. IronHelmet

    IronHelmet

    Joined:
    May 2, 2017
    Posts:
    19
    Hey, I'm just following up on my issue,

    Yesterday I was getting the following warnings when attempting to localize a TMP UGUI

    "No script asset for LocalizeTarget_TextMeshPro_UGUI. Check that the definition is in a file of the same name." and "The referenced script on this Behaviour (Game Object '<null>') is missing!"

    I read some previous posts about the LocalizeTarget_TextMeshPro_UGUI and found that we did not have that class in our project.

    I have tried updating i2 via the asset store but this completely broke i2 with a lot of warnings.

    When trying to restore what we had from source control I found that i2 is still broken in my local protect

    Assets/I2/Localization/Examples/Targets/2DToolKit/tk2dChangeLanguage.cs(5,15): error CS0101: The namespace `I2.Loc' already contains a definition for `Example_ChangeLanguage'

    Assets/I2/Localization/Scripts/LanguageSource/LanguageSource.cs(11,15): error CS0101: The namespace `I2.Loc' already contains a definition for `LanguageSource'


    ---

    What is the correct and recommended way to update my project to the latest plugin?

    We are on Unity 2017.4.3.f1 and I2v2.8.10f1
     
  44. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    The recommended approach for updating is to always do a "clean update".
    In the previous version of I2 Localization all your localization data was moved outside of the I2 folder (e.g. I2Languages.asset and ScriptLocalization.cs if used). So, its safe to delete the I2 folder everytime you need to update the plugin:

    1- Delete the I2 folder
    2- Download and install the plugin
    3- Once it compiles, very that all your targets are enabled in the Scripting Define Symbols.

    Hope that helps,
    Frank
     
    IronHelmet likes this.
  45. jnroesch

    jnroesch

    Joined:
    Feb 2, 2018
    Posts:
    5
    Hey there,

    i am importing a CSV from the resources folder using the following comand:

    LocalizationManager.Sources[0].Import_CSV(string.Empty, CSVfile, eSpreadsheetUpdateMode.Replace, ',');

    I have English (en) and German (de) language set up. When I play the game the first time this seems to work fine and all texts get localized to German correctly. When I start the game a second time I can see that the "code" field in the language source for the German language is empty. All texts show the English translation as fallback.

    When building the game for mobile I have to set all language-codes before building since otherwise the loca does not work which is annoying.

    I also always get the following error message in the editor (doesn't matter if I import the file or not)


    Error saving file 'C:/Users/jnroe/AppData/Local/Temp/asgdsdfg/LocaTest/LangSource_I2Languages_German.loc'
    System.ArgumentException: Illegal characters in path.
    <…>
    I2.Loc.I2BasePersistentStorage:SaveFile(eFileType, String, String, Boolean) (at Assets/I2/Localization/Scripts/Configurables/PersistentStorage.cs:207)
    I2.Loc.PersistentStorage:SaveFile(eFileType, String, String, Boolean) (at Assets/I2/Localization/Scripts/Configurables/PersistentStorage.cs:56)
    I2.Loc.LanguageSourceData:SaveLanguages(Boolean, eFileType) (at Assets/I2/Localization/Scripts/LanguageSource/LanguageSourceData_Languages.cs:310)
    I2.Loc.LanguageSourceData:UpdateDictionary(Boolean) (at Assets/I2/Localization/Scripts/LanguageSource/LanguageSourceData_Terms.cs:35)
    I2.Loc.LocalizationManager:AddSource(LanguageSourceData) (at Assets/I2/Localization/Scripts/Manager/LocalizationManager_Sources.cs:95)
    I2.Loc.LocalizationManager:RegisterSourceInResources() (at Assets/I2/Localization/Scripts/Manager/LocalizationManager_Sources.cs:62)
    I2.Loc.LocalizationManager:UpdateSources() (at Assets/I2/Localization/Scripts/Manager/LocalizationManager_Sources.cs:25)
    I2.Loc.LocalizationEditor:Custom_OnEnable(LanguageSourceData, SerializedProperty) (at Assets/I2/Localization/Scripts/Editor/Inspectors/LocalizationEditor.cs:64)
    I2.Loc.LanguageSourceAssetInspector:OnEnable() (at Assets/I2/Localization/Scripts/Editor/Inspectors/LanguageSourceAssetInspector.cs:14)

     
  46. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Hi,
    Sorry for the late reply.
    The issue you are seeing is related to the Auto Unloading of Languages features.
    That tries to remove from memory all languages except for the current one. Then, as you switch langauges, the old one is unloaded and the new one is loaded. (thats why its ok to have empty codes/languages when running the game in the editor with that feature enabled)
    To do so, on startup, it saves into disk all the languages.

    But it seems that either the your Path, Language name or Code has an invalid character so, it fails to save the language, and so, it can't recover it once you need it.

    I'm going to release a proper fix for that in the next release.
    But in the meantime, you could disable the Unloading of languages. Unless you have thousands of big texts, it wont make a big difference anyway.
    To disable the feature, just open the source (e.g. I2Languages.asset) and in the Languages tab, set the Unload Languages to NEVER.

    Hope that helps,
    Frank
     
  47. Demanuele

    Demanuele

    Joined:
    Sep 18, 2015
    Posts:
    20
    I'm trying to update to latest version and getting error:

    Assets/I2/Localization/Scripts/LanguageSource/LanguageSource.cs(11,15): error CS0101: The namespace `I2.Loc' already contains a definition for `LanguageSource'

    Any ideas?
     
  48. Inter-Illusion

    Inter-Illusion

    Joined:
    Jan 5, 2014
    Posts:
    470
    Hi,
    Depending on which version you had installed before, sometimes the package installer leaves some left over files.
    Thats why its recommended to do a clean install:
    - Delete the I2 folder
    - Install the plugin again
    (All your localization data is outside of the I2 folder, so you wont loose any data)

    Hope that helps,
    Frank
     
  49. Demanuele

    Demanuele

    Joined:
    Sep 18, 2015
    Posts:
    20
    Thanks resolved by deleting previous plugin version.
     
  50. JohnnyFactor

    JohnnyFactor

    Joined:
    May 18, 2018
    Posts:
    146
    I tried pasting my privacy policy text into I2 and discovered it doesn't like so much text (11,000 characters). What's the limit on how much text is allowed?