Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Question Is there a way to globally disable multi-touch input, just for buttons?

Discussion in 'UGUI & TextMesh Pro' started by sfallier_scopely, Apr 14, 2023.

  1. sfallier_scopely

    sfallier_scopely

    Joined:
    Aug 24, 2020
    Posts:
    7
    So, it's possible to register button clicks for multiple buttons at the same time if a player uses multiple fingers. This has the ability to cause complete chaos with your average UI & code design.

    I've dealt with lots of other UI systems, and built them from scratch myself - and the typical solution to this is to only consider touch index 0 for purposes of button clicks. Is there a setting somewhere that enforces this for UGUI? There's places in our game that require multi-touch (UI that supports zooming), so just doing
    Input.multiTouchEnabled = false;
    is not viable.