This is due to a change we made in 5.1 regarding input handling. To fix it, there will be a new API that will allow you to change this behavior, so that Unity WebGL does not capture all keyboard inputs. This will be available in 5.2, however, since this is an issue, we will look at making it available in 5.1 as well.
doNotCaptureKeyboard is critical to all our WebGL projects. We can’t update to 5.1 until this is resolved, which is unfortunate. Please include something equivalent in a patch release.
The new API is available in the latest patch. You need to look for WebGLInput.captureAllKeyboardInput. It’s a property that you can change at runtime (via script) to control whether all keyboard inputs should only be consumed by the WebGL canvas or not.
Just downloaded the patch, but it is not there. All I get is The name `WebGLInput’ does not exist in the current context
The docs say, that it should be right inside the UnityEngine namespace, but when I inspect the dll with monos Assembly-Browser it can not be found.
@Macro Trivellato , thank u dude and i have one major issue i am working on Web GL game and thats is taking some time to load so what is requirement to run the WebGL game , any graphics card or ram size should be upgarded.please help me …
@wurzel-digital : I appreciate you posting in the forums about this, but raising the issue on top of a 5 year old forum post is quite counterproductive, especially since you already posted about this issue in another forum thread How to get rid of Unity canvas collecting all keyboard input , which also was several years old.
Simply stating that “it does not work for me” in several threads will not get much help, since there are no leads to go on. Can you instead open a new forum thread, with a zip of a small test project of your WebGL template where you are seeing the issue, along with the relevant details like the Unity version you are using, and browser and OS.