3 questions related to input controls

  • In PC is there any way to identify if the TAP has been triggered by the left or right mouse button?

  • How can I disable the right mouse button over the 3D viewport as is done in the playground itself, I know that this doesn’t protect nothing but I consider avoiding the menu pretty elegant.

  • Is there any example about two finger drag in tactil screens?

Thank you for any tip!

  • In PC is there any way to identify if the TAP has been triggered by the left or right mouse button?
    on the scene and other classes related to controls you often find the event being passed to the pointer related callbacks like scene.onPointerUp,… Then you can rely on event.button to know which have been pressed.

  • How can I disable the right mouse button over the 3D viewport as is done in the playground itself, I know that this doesn’t protect nothing but I consider avoiding the menu pretty elegant.
    usually oncontextmenu = function() { return false; } can be sufficient: contextmenu - How to disable right-click context-menu in JavaScript - Stack Overflow

  • Is there any example about two finger drag in tactil screens?
    Did you look a the gizmo and dragBehavior in the documentation maybe you could control it like this ?