-1

I (on MacBook Pro M1 on Ventura 13.2.1) am using Unity's (2021.3.14f) to build a WebGL project using "Build And Run", but when the game launches, it gets stuck on the loading screen with Unity Logo and an empty bar. Using Safari and Chrome give the same error in the inspector:

[Error] Failed to load resource: the server responded with a status of 404 (Not Found) ([SceneName].loader.js, line 0)

Is this file included in the build, or am I missing a line in the code? If I test in the editor via Play button, it launches (in editor) just fine. The download from Unity Cloud Build works as well (booting my own python web server):

[myBuildFolder] % python3 -m http.server --cgi 52000

I have the following settings:

Player Settings

  • Compression Format: Gzip
  • Name Files as Hashes: Unchecked
  • Data Caching: Checked
  • Debug Symbols: Embedded
  • Decompression Fallback: Checked
  • Power Preference: High Performance

Build Settings

  • Texture Compression: Use Default Format (DXT)
  • Development Build: Unchecked
  • Code Optimization: Size
  • (Disabled) Autoconnect Profiler: Unchecked
  • (Disabled) Deep Profiling: Unchecked
  • IL2CPP Code Generation: Faster runtime

1 Answers1

0

Naming my build the same as my project name fixes the issue.

When using Servez to host my project, it showed

ERROR: GET /Build/[ProjectName].loader.js [404: does not exist]

Looking for this in my build folders, I found those files were named after my build name:

/Build/[BuildName].loader.js

Changing my build name to match my project name fixed this issue.