I haven't come across the moveto target and the scripting Unity manual also doesnt show up anything like that, but theres a different way you can do it.
Heres something in JS:
var target : Transform;
var speed : int;
function Update(){
transform.position = Vector3.MoveTowards(transform.position, target.position, Time.deltaTime * speed);
}
just save this and add it to the ball. Once the script is compiled, drag the cube from the heirarchy to the 'target' variable.
↧