ToTree() public method

public ToTree ( ) : TreeNode
return System.Windows.Forms.TreeNode
Exemplo n.º 1
0
        public TreeNode ChildrenToTree()
        {
            TreeNode res = new TreeNode("Children");

            for (int i = 0; i < Children.Count; i++)
            {
                int      idx = Children[i].Anim;
                TreeNode t   = new TreeNode(i.ToString());
                t.Nodes.Add("Name : " + Children[i].Name);
                t.Nodes.Add("Weight : " + Children[i].Weight);
                t.Nodes.Add("Anim : " + Children[i].Anim);
                if (pcc.isExport(idx))
                {
                    switch (pcc.Exports[idx].ClassName)
                    {
                    case "AnimNodeSlot":
                        AnimNodeSlot ans = new AnimNodeSlot(pcc, idx);
                        t.Nodes.Add(ans.ToTree());
                        break;
                    }
                }
                t.Nodes.Add("bIsMirrorSkeleton : " + Children[i].bMirrorSkeleton);
                t.Nodes.Add("bIsAdditive : " + Children[i].bIsAdditive);
                res.Nodes.Add(t);
            }
            return(res);
        }
Exemplo n.º 2
0
 public TreeNode ChildrenToTree()
 {
     TreeNode res = new TreeNode("Children");
     for (int i = 0; i < Children.Count; i++)
     {
         int idx = Children[i].Anim;
         TreeNode t = new TreeNode(i.ToString());
         t.Nodes.Add("Name : " + Children[i].Name);
         t.Nodes.Add("Weight : " + Children[i].Weight);
         t.Nodes.Add("Anim : " + Children[i].Anim);
         if (pcc.isExport(idx))
             switch (pcc.Exports[idx].ClassName)
             {
                 case "AnimNodeSlot":
                     AnimNodeSlot ans = new AnimNodeSlot(pcc, idx);
                     t.Nodes.Add(ans.ToTree());
                     break;
             }
         t.Nodes.Add("bIsMirrorSkeleton : " + Children[i].bMirrorSkeleton);
         t.Nodes.Add("bIsAdditive : " + Children[i].bIsAdditive);
         res.Nodes.Add(t);
     }
     return res;
 }