Get mouse position in world space
问题 I'm making a game using Unity and I have a little issue, I need to know the mouse position in world space, for that I try to set a GameObject at the mouse position using this code : Vector3 p = Input.mousePosition; Vector3 pos = Camera.main.ScreenToWorldPoint( p); testGameObject.transform.position = pos; It works like a charm in Editor but in exe / apk, the GameObject dosn't follow the mouse: Example 1 Example 2 The GameObject that is supposed to follow the mouse is the "1" inside a circle