Bug description
Currently, netplay URLs do not load on desktop web and mobile web.
Reproduce
On any computer browser (e.g. chrome), visit a wasm4 game (e.g. https://wasm4.org/play/kittygame) and press enter->copy netplay URL. Now open another tab and paste. Observe a black screen. Open developer console and see the error:
Uncaught (in promise) TypeError: set WebAssembly.Global.value): Can't set the value of an immutable global.
at Ct.write (wasm4.js:50:9105)
at RTCDataChannel.<anonymous> (wasm4.js:50:20165)
Fix exploration
Now observe that if you use devtool source overrides (https://stackoverflow.com/a/61377922), comment out the problematic line (wasm4.js line 50), save, and reload, netplay functions as normal.
This appears to be caused by #715 with this specific change. @JerwuQu any ideas for a fix? I could look myself but I don't want to jump in and break global patching, as I don't know how that part of the codebase works just yet.
Bug description
Currently, netplay URLs do not load on desktop web and mobile web.
Reproduce
On any computer browser (e.g. chrome), visit a wasm4 game (e.g. https://wasm4.org/play/kittygame) and press
enter->copy netplay URL. Now open another tab and paste. Observe a black screen. Open developer console and see the error:Fix exploration
Now observe that if you use devtool source overrides (https://stackoverflow.com/a/61377922), comment out the problematic line (wasm4.js line 50), save, and reload, netplay functions as normal.
This appears to be caused by #715 with this specific change. @JerwuQu any ideas for a fix? I could look myself but I don't want to jump in and break global patching, as I don't know how that part of the codebase works just yet.