I get errors whenam encountering an extremely absurd phenomenon. When I run this code: on my smartphone Input.GetMouseButtonDown (0).position because apparentlyvia Unity Remote or even on the computer, it does not existworks as expected. How canBut when I detectinstall the position ofAPK on the mouse press?
I want to publish for smartphonesdevice and run it, the touch devices so I can't use Input.mousePositiondistance changes! Does this have something to do with resolution and Vector3.Distance?
distance = Vector3.Distance (Input.mousePosition, button.position); Debug.Log (distance); if (Input.GetMouseButton (0) && distance > 55) { // do something }