示例#1
0
        private void DistributeConnections()
        {
            int connectionNumber = Mathf.Min(controller.GetNodeNeighbours(CentralNode).ToArray().Length, distribution.MaxVisibleNumber);
            int totalNumber      = connectionNumber + distribution.ChangeBy;
            int firstRowNumber   = Mathf.Min(totalNumber, Mathf.RoundToInt(distribution.MaxVisibleNumber * .75f));

            DistributeAtElevation(firstRowNumber, distribution.RingAngleSpan.y);
            if (totalNumber > firstRowNumber)
            {
                DistributeAtElevation(totalNumber - firstRowNumber, distribution.RingAngleSpan.x, 180f / firstRowNumber);
            }
        }