// Return a List of Locations representing the found path
public List <CubeIndex> FindPath()
{
List <CubeIndex> path = new List <CubeIndex>();
CubeIndex current = goal;
// path.Add(current);
while (!current.Equals(start))
{
if (!cameFrom.ContainsKey(current))
{
MonoBehaviour.print("cameFrom does not contain current.");
return(new List <CubeIndex>());
}
path.Add(current);
current = cameFrom[current];
}
// path.Add(start);
path.Reverse();
return(path);
}