Detecting mouse location

I am trying to determan the point that the mouse is clicked but for every click it always comes up (0,0,0) any help

if(Input.GetMouseButtonDown(1))
	{
		var ray = Camera.main.ScreenPointToRay(Input.mousePosition);
		var rayHit : RaycastHit;
		testSelect.GetComponent("Character").destination =  rayHit.point;
		Debug.Log (rayHit.point);
	}

you need to add

if (Physics.Raycast (ray , rayHit , 100))

to actually cast a ray and hit something. Also you need to have a collider attached to the objects you want to hit.

here you go → Unity - Scripting API: Input.mousePosition