【What we want to achieve】
I want to display a WebGL Build screen in a browser using Localization.
【Version】
Unity2020.3.8f1LTS
Localization1.3.2
【Contents】
I cannot display WebGL Build using Localization in a browser.
How to solve this problem?
(1)When I start WebGL Build with Localization in a browser, the following error message appears on the browser and I cannot display the screen.
I get the following error message:
「do you wish to make the asset the active localization settings?
The active localization settings will be included into any builds and preloaded at the start this can be changed at edit/project settings/localization」
(2)If you delete the LocalizationSettings file, you will be able to see
(3)In LocalizationSettings
LocaleSelectors > Command Line Artumetnt
Change the following to
-language=
↓
-language=en
The error message will change to
「an error occurred running the uinty content on this page
see your browser javascript console for more into
the error was abort101 at error」
【UnityEditor】
On UnityEditor, localization switching works normally, but the following log message appears
「Locales PreloadOperation has not been initialized, can not return the available locales.
LocalesProvider:get_Locales ()
VketAvatarMaker.LocalizationController:Localization () (at Assets/VketAvatarMaker/Scripts/Common/LocalizationController.cs:39)
VketAvatarMaker.LocalizationController:b__1_0 (long) (at Assets/VketAvatarMaker/Scripts/Common/LocalizationController.cs:30)
UniRx.Observer/Subscribe`1:OnNext (long) (at Library/PackageCache/com.neuecc.unirx@284d5c50d3/Observer.cs:165)
UniRx.Operators.TimerObservable/Timer:OnNext () (at Library/PackageCache/com.neuecc.unirx@284d5c50d3/Operators/Timer.cs:97)
UniRx.Operators.TimerObservable/<>c__DisplayClass6_2:b__1 () (at Library/PackageCache/com.neuecc.unirx@284d5c50d3/Operators/Timer.cs:62)
UniRx.MainThreadDispatcher:UnsafeSend (System.Action) (at Library/PackageCache/com.neuecc.unirx@284d5c50d3/UnityEngineBridge/MainThreadDispatcher.cs:269)
UniRx.Scheduler/MainThreadScheduler/d__2:MoveNext () (at Library/PackageCache/com.neuecc.unirx@284d5c50d3/UnityEngineBridge/MainThreadScheduler.cs:102)
UnityEngine.SetupCoroutine:InvokeMoveNext (System.Collections.IEnumerator,intptr)」
【実現したい事】
Localizationを使用してWebGL Buildをブラウザで画面を表示させたいです
【Version】
Unity2020.3.8f1LTS
Localization1.3.2
【内容】
Localizationを使用してWebGL Buildをブラウザで画面が表示できない
対応方法を教えて下さい
LocalizationのWebGL Buildをブラウザで起動時にブラウザ上で下記エラーが出力されて画面が表示できません
「do you wish to make the asset the active localization settings?
the active localizaation settings will be included into any builds and preloaded at the start this can be changed at edit/project settings/localization」
LocalizationSettingsファイルを削除すれば表示可能です
LocalizationSettings内の
LocaleSelectors > Command Line Artumetnt
下記に変更すると
-language=
↓
-language=ja
エラー内容は下記に変化します
「an error occurred running the uinty content on this page
see your browser javascript console for more into
the error was abort101 at error」
【UnityEditor】
UnityEditor上では正常にローカライズ切替が動作しますが、下記ログが表示されます
「Locales PreloadOperation has not been initialized, can not return the available locales.
UnityEngine.Localization.Settings.LocalesProvider:get_Locales ()
VketAvatarMaker.LocalizationController:Localization () (at Assets/VketAvatarMaker/Scripts/Common/LocalizationController.cs:39)
VketAvatarMaker.LocalizationController:b__1_0 (long) (at Assets/VketAvatarMaker/Scripts/Common/LocalizationController.cs:30)
UniRx.Observer/Subscribe`1:OnNext (long) (at Library/PackageCache/com.neuecc.unirx@284d5c50d3/Observer.cs:165)
UniRx.Operators.TimerObservable/Timer:OnNext () (at Library/PackageCache/com.neuecc.unirx@284d5c50d3/Operators/Timer.cs:97)
UniRx.Operators.TimerObservable/<>c__DisplayClass6_2:b__1 () (at Library/PackageCache/com.neuecc.unirx@284d5c50d3/Operators/Timer.cs:62)
UniRx.MainThreadDispatcher:UnsafeSend (System.Action) (at Library/PackageCache/com.neuecc.unirx@284d5c50d3/UnityEngineBridge/MainThreadDispatcher.cs:269)
UniRx.Scheduler/MainThreadScheduler/d__2:MoveNext () (at Library/PackageCache/com.neuecc.unirx@284d5c50d3/UnityEngineBridge/MainThreadScheduler.cs:102)
UnityEngine.SetupCoroutine:InvokeMoveNext (System.Collections.IEnumerator,intptr)」