Cannot build MLAPI WebGL project
See original GitHub issueDescribe the bug After adding MLAPI to my project, WebGL builds fail.
To Reproduce Steps to reproduce the behavior:
- Create a new Unity project (3D).
- Add the MLAPI project via the package manager (git).
- File->Build Settings->WebGL->Switch Platform->Build
Expected behavior Project builds successfully.
Screenshots See below.
Environment (please complete the following information):
- OS: Windows 10
- Unity Version: 2019.4.21f1 Personal
- MLAPI Version: 0.10.0
- MLAPI Commit:https://github.com/Unity-Technologies/com.unity.multiplayer.mlapi/commit/3e3aef6aa02c2a25359898319e5bd49d3518b57b
Additional context Errors (for searchability):
Library\PackageCache\com.unity.multiplayer.mlapi@3e3aef6aa0\Runtime\Transports\UNET\RelayTransport.cs(251,74): error CS0117: 'NetworkTransport' does not contain a definition for 'QueueMessageForSending'
Library\PackageCache\com.unity.multiplayer.mlapi@3e3aef6aa0\Runtime\Transports\UNET\RelayTransport.cs(266,60): error CS0117: 'NetworkTransport' does not contain a definition for 'QueueMessageForSending'
Library\PackageCache\com.unity.multiplayer.mlapi@3e3aef6aa0\Runtime\Transports\UNET\RelayTransport.cs(271,74): error CS0117: 'NetworkTransport' does not contain a definition for 'SendQueuedMessages'
Library\PackageCache\com.unity.multiplayer.mlapi@3e3aef6aa0\Runtime\Transports\UNET\RelayTransport.cs(273,60): error CS0117: 'NetworkTransport' does not contain a definition for 'SendQueuedMessages'
Error building Player because scripts had compiler errors
Build completed with a result of 'Failed' in 1 seconds (1391 ms)
UnityEngine.GUIUtility:ProcessEvent (int,intptr)
UnityEditor.BuildPlayerWindow+BuildMethodException: 5 errors
at UnityEditor.BuildPlayerWindow+DefaultBuildMethods.BuildPlayer (UnityEditor.BuildPlayerOptions options) [0x002bf] in <208995a09fe148f5a6f6c571838c154f>:0
at UnityEditor.BuildPlayerWindow.CallBuildMethods (System.Boolean askForBuildLocation, UnityEditor.BuildOptions defaultBuildOptions) [0x00080] in <208995a09fe148f5a6f6c571838c154f>:0
UnityEngine.GUIUtility:ProcessEvent (int,intptr)
Issue Analytics
- State:
- Created 2 years ago
- Reactions:6
- Comments:12 (3 by maintainers)
Top Results From Across the Web
Unable to make WebGL development builds
To work around this, click on a different platform in the Build Player window, uncheck the "Script Debugging" checkbox, and click on WebGL...
Read more >MLAPI, Proton or Mirror for multiplayer in WEBGL? : r/Unity3D
Hey everyone, I'm working on a project that needs to support >10 players on it at a time, the docs on MLAPI seem...
Read more >WebGL Networking
You can't use any .NET networking classes within the WebGL platform because JavaScript code doesn't have direct access to internet protocol (IP) sockets...
Read more >Cannot build WebGL - Ask
I can build a Linux platform solution, but WebGL build always fails. I recently did a new install, but I'm using Unity 2019.4.18f1....
Read more >Unity WebGL Game Not Working? This Should Fix it - YouTube
Your browser can't play this video. Learn more. Open App. Quickly fix any Unity web versions of your game if it is not...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi, is there a possibility you could create a release version with this commit added only? This is a pretty important bug and I should not have to use the development branch to compile for WebGL.
Netcode for GameObjects building on WebGL is now possible, after https://github.com/Unity-Technologies/com.unity.netcode.gameobjects/pull/2199