Search code examples
unity-game-engineunity-webgl

SceneManager.LoadScene/LoadSceneAsync loads empty scene (WebGL) Unity 5.6


After update 5.6.1f my WebGL build can't load scene correctly. Develop build and DebugSumbols activated - same result. No errors, no warnings.

Always was load empty scene, but with NotDestroyOnLoad objects after prevois scene.

Same problem, but no answer. https://forum.unity3d.com/threads/black-screen-when-changing-scene-in-webgl-using-unity-5-6.473367/


Solution

  • When creating the build for Android we used the option "Split Application Binary" at the Player settings. Of course this setting is stored in the project. It just happens to be the setting that makes scene switching in WebGL impossible! After some hard work in stripping down our project it occurs that this is the only setting that causes the bug. I really don't know why an Android setting ends up having a major impact on a WebGL build. Something Unity should investigate! (using Unity 5.6.1f1)

    https://forum.unity3d.com/threads/black-screen-when-changing-scene-in-webgl-using-unity-5-6.473367/