Language Source resets to default on load

More
8 years 6 months ago #1054 by whipexx
Sometimes when loading the game the language source deletes all terms and languages, causing all texts that get set from script to disappear.
To go back to the previous state I have to re-Import everything from the google spreadsheets backup.

Any insight on this problem? Does anyone know how to solve it?

Cheers.

Please Log in or Create an account to join the conversation.

More
8 years 6 months ago #1055 by Frank
Hi,
If your LanguageSource is linked to a Google Spreadsheet (i.e. has a webservice URL and a spreadsheet selected on the popup), it will regularly try getting all from google. The exact time between downloads its determined by the popup that it's at the bottom of the Google tab in the editor. (Never, Daily, Weekly, Monthly, etc)

If you have selected anything other than "Never". Then, it will download all the data, and reset the terms / languages if they have changed. While doing it, it will delete any term you added with code at runtime or if you manually loaded a CSV file.

Can that be the issue you are seeing? If so, you should set the download time to Never so the added terms don't get deleted.
Another option, its to duplicate the I2Languages.prefab. And add all your runtime terms to the second prefab while keeping the I2Languages synchronized from google.
If you create a second prefab you need to add it to the LocalizationManager code so that it gets loaded as well. Just look for the GlobalSources variable and add your new prefab.
If for instance, you named it RuntimeLanguages.prefab, then just open LocalizationManager and modify the GlobalSources array to look like:
public static string[] GlobalSources = new string[]{"I2Languages", "RuntimeLanguages"};

Also, on v2.6.0f1 there was a bug that was completely wiping out the terms and languages if when downloading from google the internet connection failed. That was fixed on v2.6.0f2. Can you verify you are running the latest update?

Hope that helps,
Frank

Are you :-) Give I2L 5 stars!
Are you :-( Please lets us know how to improve it!
To get the betas as soon as they are ready, check this out

Please Log in or Create an account to join the conversation.

More
8 years 6 months ago #1056 by whipexx
My current version is in fact 2.6.0 f1, so I think it's a combination of both issues.

I've tried setting the update frequency to never and it hasn't failed since then.

Thanks.

Please Log in or Create an account to join the conversation.

Time to create page: 0.342 seconds
Template by JoomlaShine