Cannot move camera


I have this perplexing problem, the camera won’t move as expected when I use the mouse or keyboard.

In my scene I create a UniversalCamera and I attach it to the render canvas. Somthing like this:

val camera = new UniversalCamera(“sceneCamera”, new Vector3(0, 1, -15), scene)

I have no mouse or keyboard handler registered in my code. Not sure where to start to debug this problem.

Running in latest Chromium, served from localhost, Babylon 4.2.

Hi @olof and welcome to the forum.

Unfortunately we are not able to help since code needs to be precise. No way to tell if you are missing the namespace BABYLON on purpose to shorten your typing or its is missing because you do not realize it is needed.

Please see if you can reproduce the issue in a playground.

Unfortunately, I cannot repeat this in the playground.

Do you know at what point BabylonJs attach handlers for the mouse and keyboard?

I think it does it when you call attachControl.