After
another fix it Friday session we have now integrated click to move with A* path-finding.
We are now slicker than Diablo I. Code snippet shows the core functioality.
void Start ()
{
seeker = GetComponent<Seeker> ();
}
void Update ()
{
//Start a new path to the targetPosition, return the result to the OnPathComplete function
seeker.StartPath (transform.position, target.position, OnPathComplete);
}
No comments:
Post a Comment