Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if (Input.touchCount > 0 && Input.GetTouch(0).phase == TouchPhase.Began)
- {
- // Check if finger is over a UI element
- if (EventSystem.current.IsPointerOverGameObject (Input.GetTouch (0).fingerId))
- {
- Debug.Log ("Touched the UI");
- }
- else
- {
- GetInteraction();
- }
- }
Advertisement