コード例 #1
0
 private void setChildren(Tech parent)
 {
     Debug.Log("setting Children");
     foreach (Tech tech in ttree)
     {
         //Debug.Log(tech.name + " testing if is child of " + parent.name);
         if (tech.GetPrereq() == parent)
         {
             //Debug.Log("set " + tech.name + " as child of " + parent.name);
             parent.AddChild(tech);
             setChildren(tech);
         }
     }
 }