How can i disable right click on Mesh Builder Planes button?

Hello

What is happening now is that if someone clicks the button with the left click, then the same thing is happening with the right click But I don’t like this: Click only with left click, button not click with right click

How can i disable right click in Meshbuilder Plane button??

You can disable rightclick altogether if you change the camera’s mouse input’s buttons to [0] instead of [0, 1, 2] . 0 is the right click. 2 is the right click. This array tells babylon what buttons are allowed to be used for interaction.

It really depends on the camera you are using, but here is an example of such an array for the arc rotate mouse input:

Acutally i want to disable right click of this

BABYLON.GUI.Button.CreateSimpleButton

how can i disable i dont want to disable camera things?

You can see here a example

Button | Babylon.js Playground (babylonjs.com)

If u click button with right click they also work but i dont want this i only want to click this button with left not right.

Hope you understand

@msDestiny14 will be able to help here :slight_smile:

On the click observable you should be able to check the event to get the mouse button input.