Example #1
0
 public void initVals()
 {
     startnodename = "";
     endnodename   = "";
     pathRadius    = 0.03f;
     pathNodeSize  = 3 * pathRadius;
     visible       = true;
     status        = PathStatusE.Initializing;
 }
Example #2
0
 public void GenAstarPath(LcCapType captype = LcCapType.anything)
 {
     if (startnodename == "")
     {
         var sp = sman.linkcloudman.GetNode(0);
         startnodename = sp.name;
     }
     if (endnodename == "")
     {
         var ep = sman.linkcloudman.GetNode(-1); // last point
         endnodename = ep.name;
     }
     path = sman.linkcloudman.GenAstar(startnodename, endnodename, captype);
     if (path == null)
     {
         Debug.LogWarning("A * path was not found for captype " + captype);
         status = PathStatusE.AstarNotFound;
     }
     else
     {
         status = PathStatusE.AstarOk;
         //Debug.Log("A * path length:" + _path.waypts.Count + " len:" + _path.pathLength+" captype:"+captype);
     }
 }