Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by gigos22 · Jan 12, 2021 at 02:48 PM · buildwebgl

WebGL builds in version 2020.2.1f1 are not working?

As the title suggests, I've previously built a game for WebGL in a 2019 version and it was alright. I've updated to the latest version of 2020 and it simply seems that the build operation for WebGL in this version is screwed up..


First I get an error on the web page that says: WebGL builds are not supported on mobile devices.

But it's on a browser on my computer.. It's not from my smart phone...


Secondly I get this warning: The script from “http://mygame.me/Build/MyGame%20Build.framework.js.gz” was loaded even though its MIME type (“application/x-gzip”) is not a valid JavaScript MIME type.


At last, I get 2 console errors:

Uncaught SyntaxError: illegal character U+001F

Uncaught ReferenceError: unityFramework is not defined.


What can I do to solve this?

Is this a known issue?

Is there a workaround for this?

Am I really restricted to build WebGL games only from 2019 versions?

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

4 Replies

· Add your reply
  • Sort: 
avatar image
2
Best Answer

Answer by Qhuhuit · Jan 17, 2021 at 09:38 PM

I also cannot run my game build with 2020.2.1f1


I have this warning:

 WebGL.framework.js:2 WebGL: INVALID_ENUM: getInternalformatParameter: invalid internalformat
 _glGetInternalformativ @ WebGL.framework.js:2

Followed by

 Exception at: 
 Error
     at jsStackTrace (http://localhost:52008/Build/WebGL.framework.js:2:16493)
     at stackTrace (http://localhost:52008/Build/WebGL.framework.js:2:16664)
     at http://localhost:52008/Build/WebGL.framework.js:2:3544
     at http://localhost:52008/Build/WebGL.wasm:wasm-function[102515]:0x1f56d07
     ... a tone of unreadable stacktrace

And two errors:

 exception thrown: undefined - Exception catching is disabled, this exception cannot be caught. Compile with -s DISABLE_EXCEPTION_CATCHING=0 or DISABLE_EXCEPTION_CATCHING=2 to catch. WebGL.loader.js:1:4256
 
 Uncaught undefined - Exception catching is disabled, this exception cannot be caught. Compile with -s DISABLE_EXCEPTION_CATCHING=0 or DISABLE_EXCEPTION_CATCHING=2 to catch. WebGL.framework.js.gz:2:563707

Only way I found after a day trying, was enabling all debug options, full stacktrace and everything. Ok it showed some warnings I've fixed, but still not playable in release, and unplayable in this debug condition...


EDIT: checking "Data caching" & "Decompression Fallback", and unchecking "Prebake Collision Meshes" & "Optimize Mesh Data" made my build run !

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image gigos22 · Jan 20, 2021 at 09:22 AM 0
Share

Thank you for the info. I'll try it when I get the chance..

For now I simply downgraded to some 2019 version...

I really don't like the path they go with Unity 2020..

It seems that they are solely focusing about changing instead of

improving.. With each new update of 2020 things gets worse and worse..

avatar image
4

Answer by syeddaniyalrizvi · Mar 13, 2021 at 12:12 PM

What worked for me: Player Settings -> Publish Settings -> Compression Format, Select Disabled.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image snowinrain · Mar 25 at 09:09 AM 0
Share

this comment should be the best answer here

avatar image
0

Answer by Charles_Games · Jan 14, 2021 at 04:40 PM

I have the same problem, its only in FF though I found this (https://forum.unity.com/threads/illegal-character-error-in-firefox.404224/) but was enable to make the .htaccess work

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image gigos22 · Jan 17, 2021 at 07:45 AM 0
Share

I've read that thread, though I have no idea what is that .htaccess..

Is that a file? If so, I don't find it.. In the build folder there is only 4 files, 3 of which are zipped.

avatar image
0

Answer by DouLiu2021 · Aug 19, 2021 at 12:44 PM

Hello, I also meet the same error when try to run the project on web page using flask. May I know how did you solve this? By downgrading the unity or some other solution? Thanks!

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Bunny83 · Aug 19, 2021 at 12:53 PM 0
Share

To quote the last bit of the accepted answer:

checking "Data caching" & "Decompression Fallback", and unchecking "Prebake Collision Meshes" & "Optimize Mesh Data" made my build run !

In most cases when a build doesn't load it's due to wrong server configuration. Nobody seems to read the documentation on that topic. If you serve pre-compressed content, your server has to provide the correct "Content-Encoding" header in the response.

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

133 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Distribute terrain in zones 3 Answers

WebGl build throw numbers (maybe assembly pointers) 0 Answers

How to use Webgl Debug Symbols? 0 Answers

Blank screen on WebGL (Lighting) 0 Answers

Cant build on WebGL 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges