Hello,
I am trying to get Babylon working using this template, but for some reason, I am unable to move the camera with the arrow keys.
I am unable to access any keyboard input without the following code:
src/BabylonScene/index.js line 86:
<canvas
{...opts}
ref={this.onCanvasLoaded}
role="image"
>
<button>Focus button</button>
</canvas>
src/Viewer/index.js, line 26:
canvas.addEventListener("keydown", e=>{
if(e.key === "f") console.log(camera.position)
})
With the above code I can get "f" to work and log the camera.position, but none of the arrow keys work.
Are you able to reproduce this?
I opened an issue on the forums, but there has been no solution yet.
Hello,
I am trying to get Babylon working using this template, but for some reason, I am unable to move the camera with the arrow keys.
I am unable to access any keyboard input without the following code:
src/BabylonScene/index.js line 86:
src/Viewer/index.js, line 26:
With the above code I can get "f" to work and log the camera.position, but none of the arrow keys work.
Are you able to reproduce this?
I opened an issue on the forums, but there has been no solution yet.