6/20/2019 12:14:03 PM
Piyush Duggal1 Answer
New AnswerCheck out the example provided in Unity's API on Input.getTouch https://docs.unity3d.com/ScriptReference/Input.GetTouch.html There is a Touch struct that handles device screen touches. Input.touchCount -> Returns the number of 'touches' on the screen (finger or stylus). Then, Input.getTouch, gives us that Touch struct. The Touch struct has attributes like the position, angle, action (is it moving?) Etc.. on the screen. Touch struct: https://docs.unity3d.com/ScriptReference/Touch.html
Sololearn Inc.
535 Mission Street, Suite 1591Send us a message