|
|
|
@ -297,7 +297,7 @@ namespace Fungus
|
|
|
|
|
* Scan a localization CSV file and copies the strings for the specified language code |
|
|
|
|
* into the text properties of the appropriate scene objects. |
|
|
|
|
*/ |
|
|
|
|
public virtual void SetActiveLanguage(string languageCode) |
|
|
|
|
public virtual void SetActiveLanguage(string languageCode, bool forceUpdateSceneText = false) |
|
|
|
|
{ |
|
|
|
|
if (!Application.isPlaying) |
|
|
|
|
{ |
|
|
|
@ -357,8 +357,14 @@ namespace Fungus
|
|
|
|
|
|
|
|
|
|
localizedStrings[fields[0]] = fields[languageIndex]; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// Early out unless we've been told to force the scene text to update. |
|
|
|
|
// This happens when the Set Language command is used to reset back to the standard language. |
|
|
|
|
if (!forceUpdateSceneText) |
|
|
|
|
{ |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// Using a localized language text column |
|
|
|
|
// 1. Add all localized text to the localized strings dict |
|
|
|
|