Search Unity

Question Localization and Addressables not loading on Play Unity plateform

Discussion in 'Web' started by BigzCramillet, Jun 30, 2021.

  1. BigzCramillet

    BigzCramillet

    Joined:
    Mar 31, 2020
    Posts:
    9
    Hello there !

    I'm attempting to upload my game on the https://play.unity.com/ plateform but I'm having a hard time making localization work on WebGL.
    Everything works perfectly on other plateforms (Windows standalone, MacOS standalone, iOS, Android and Unity Editor).

    Unfortunatly, my WebGL build can not load any Locale. As I understand the error messages in the console, the main problem comes from the Addressables not able to be loaded.

    I'm surely missing something in the addressables configuration for WebGL build but can't figure out what.

    You can see the errors I got in console here:



    I'm using:
    - Unity 2021.1.12f1
    - Localization 1.0.0-pre.9
    - Addressables 1.18.2
    -Scriptable Build Pipeline 1.18.0

    All of thoses are versions I upgraded after having the same problem with
    - Unity 2020.3.7f1
    - Localization 0.11.0-preview
    - Addressables 1.18.9
    - Scriptable Build Pipeline 1.17.1

    Thanks for the help !
     
  2. unityruba

    unityruba

    Unity Technologies

    Joined:
    Nov 6, 2020
    Posts:
    273
    Hi!

    Thank you for providing all this info :)

    Does your game work locally on WebGL when you do a Build And Run?
     
  3. BigzCramillet

    BigzCramillet

    Joined:
    Mar 31, 2020
    Posts:
    9
    Hi again !

    I have a similar result with a slightly different error when I do a Build and Run.

    Here is the error log:
     
  4. unityruba

    unityruba

    Unity Technologies

    Joined:
    Nov 6, 2020
    Posts:
    273
    Kuriuslee likes this.
  5. BigzCramillet

    BigzCramillet

    Joined:
    Mar 31, 2020
    Posts:
    9
    Yes this is a process I'm familiar with as I had to do it for all the other platforms :)

    I didn't mentioned that the resulting build is composed of a StreamingAssets folder and the file StreamingAssets/aa/settings.json is in it.

    To provide more info, here is the configuration of my Localization-Locales addressable Group:


    Two things here are different from a default configuration:
    - Use UnityWebRequest for Local Asset Bundles is checked (same result if unchecked)
    - Bundle Naming Mode set as "Append Hash to Filename" (same result with default mode)

    I suspect there is something to do with the RemoteBuildPath and RemoteLoadPath option but I can't figure out how to make it work for the Unity Play platform :oops:
     
    travlake and DrViJ like this.
  6. Labaze

    Labaze

    Joined:
    Aug 15, 2017
    Posts:
    2
    Hi,
    I have the same issue.
    I want to make a light version of my game in WebGL to make a web demo.
    But my WebGL build can not load any Locale.
    Did you have any updates?
     

    Attached Files:

  7. BigzCramillet

    BigzCramillet

    Joined:
    Mar 31, 2020
    Posts:
    9
    Unfortunatly I didn't ...
    I completely gave up as my WebGL version was just a demo so I went full English on it.

    Let's hope Unity guys are working on a fix.
    Good luck on your project. If you can update this post with any solutions you may found, it could be of great help for others =)
     
  8. travlake

    travlake

    Joined:
    Oct 4, 2019
    Posts:
    50
    Any updates on this? I followed the steps you suggested, did a "Build and Run" and get the same error as BigzCramillet:

    "RemoteProviderException : TextDataProvider : unable to load from url : http://localhost:56937/StreamingAssets/aa/settings.json"

    True enough, there is no settings.json file in the StreamingAssets/aa folder of the build.

    EDIT: Fixed for me by updating Addressables from 1.19.9 to 1.19.17, cleaning the addressables build cache, and doing a new addressables build followed by a project build. Not sure why it wasn't making the settings.json, catalog.json, and a bunch of other files before.
     
    Last edited: Jan 11, 2022
  9. BigzCramillet

    BigzCramillet

    Joined:
    Mar 31, 2020
    Posts:
    9
    Thanks for you reply. I guess there was indeed a little bug somewhere and it has been fixed in latest version of the Addressables !