Welcome, Guest
Username: Password: Remember me

TOPIC: Having trouble setting language [solved]

Having trouble setting language [solved] 2 weeks 1 day ago #3018

  • cephalo
  • cephalo's Avatar
  • Offline
  • New Member
  • Posts: 2
  • Karma: 0
Using

LocalizationManager.CurrentLanguageCode = "fr";

does not change the language in my game. Am I supposed to do something else to update scenes with the new language?
Last Edit: 2 weeks 1 day ago by cephalo.
The administrator has disabled public write access.

Having trouble setting language 2 weeks 1 day ago #3020

  • Frank
  • Frank's Avatar
  • Offline
  • Administrator
  • Posts: 1059
  • Thank you received: 229
  • Karma: 66
Just to be sure:
- Does your I2Languages.prefab has a language with the code "fr"?
- Is the only language source you are using the I2Languages.prefab or do you have any source instantiated in your scene?
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
The administrator has disabled public write access.

Having trouble setting language 2 weeks 1 day ago #3021

  • cephalo
  • cephalo's Avatar
  • Offline
  • New Member
  • Posts: 2
  • Karma: 0
Yes, the language is called 'French' with code 'fr'.

I have six languages, French being one of those, and none of them change the language.

I am using only the one Language Source in the recommended place in I2>Resources. I did recently update I2, but I did not find another one with the new package.

I am running that code in a button, one for each language, and the code is executing as I can print to the debug log inside the button handler that contains the change language code.
    public void OnFrench()
    {
        print("switching to French");
        LocalizationManager.CurrentLanguageCode = "fr";
    }

EDIT: It's working now! I believe it wasn't working because I had recently added all the languages. Now that I have shut down the Unity editor and reloaded the project it is working.
Last Edit: 2 weeks 1 day ago by cephalo.
The administrator has disabled public write access.

Having trouble setting language 2 weeks 1 day ago #3022

  • Frank
  • Frank's Avatar
  • Offline
  • Administrator
  • Posts: 1059
  • Thank you received: 229
  • Karma: 66
weird! haha.
Please, let me know if the problem continue!

Thanks,
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
The administrator has disabled public write access.
Time to create page: 0.191 seconds
Colors