Esempio n. 1
0
        private EdgeRenderer GetEdgeRenderer(int fromNode)
        {
            EdgeRenderer edgeRenderer = Points[fromNode].GetComponent <EdgeRenderer>();

            if (!edgeRenderer)
            {
                edgeRenderer           = Points[fromNode].AddComponent <EdgeRenderer>();
                edgeRenderer.StartNode = Points[fromNode].transform.position;
            }

            return(edgeRenderer);
        }
Esempio n. 2
0
 private void AddPointToRenderer(EdgeRenderer edgeRenderer, int toNode)
 {
     edgeRenderer.TargetNodes.Add(Points[toNode].transform.position);
 }