Differnt Screen Pos, But Same World Pos

Hi there,
I am using a NavMeshAgent and NavMesh to move my player about. UI is such, I tap screen and convert screen pos to world pos, However, this works only for one z direction. My naveMeshAgent, agent, only moves in one Z direction. If I tap up, where I would expect him to move away from the camera, he does. But if I tap down, where I would expect him to move toward the camera, he does not.

Any ideas??
Thanks

    void setMoveToPos(Vector2 moveToPos){
////moveToPos = screen tap pos
///-18.6 z distance of camera to 0
        Vector3 worldPos = Cam_Main.ScreenToWorldPoint(new Vector3(moveToPos.x, moveToPos.y, -18.6f));
        targetPoint = new Vector3(-worldPos.x, worldPos.y, agent.transform.position.z);
        moveActive = true;
       
    }

With the posted you, you are basically guessing what the z coordinate might be. You need to have the correct z coordinate, without guessing. Otherwise you won’t get the correct result.

You could alternatively use a raycast to get the correct world position. Without that, you it is often pretty complex to get the correct world position, or you can easily break the computation.

Thanks. Yes, I swapped to cast ray, hit.point. That works.
Cheers!