Lecture: “Unit Movement”
Reason (that i think):
Physics.Raycast(mainCamera.ScreenPointToRay(Input.mousePosition), out RaycastHit hit, maxDistanceForRayCast, NavMesh.AllAreas)
in the above line i used the new input system code and that caused the issue.
!Physics.Raycast(mainCamera.ScreenPointToRay(Mouse.current.position.ReadValue()), out RaycastHit hit, maxDistanceForRayCast, NavMesh.AllAreas)
please guide.