Deactive some Camera inputs

Hi, I’m trying to play, testing with the preset camera “ArcRotateCamera”. But now I’m solving how to disable inputs from the keyboard and input from the right mouse button. So, I was trying to use this code:

         camera.inputs.clear();
         camera.inputs.addMouseWheel();

Most of work is ok, for example keyboard is disabled. The problem is that I was looking for a function to add the left mouse button, so something like “addLeftMuseButton()” but there is no such method. So how to solve the problem and disable the right mouse button. In short, I need: the user to click the right mouse button and nothing happens.

I used the help text here:

Thanks for your time, your response.

Hey there, the pointer input class has a property called buttons that controls which buttons are enabled. By default it’s set to [0, 1, 2]. You can remove the 2 like below to disable right click input. :slight_smile:

2 Likes