private void RecursiveDrawSegment(SplineSegment segment) { foreach (SplineSegment child in segment.Children) { RecursiveDrawSegment(child); } int depth = segment.Depth(); Vector3 gPosition = segment.GlobalPosition(); Vector3 gScale = segment.GlobalPosition(); Quaternion gRotation = segment.GlobalRotation(); if (depth == _depth | viewAllNodes) { Gizmos.color = Palette.ColorWheel(segment.Depth(), 6); UnityEditor.Handles.color = Gizmos.color; UnityEditor.Handles.DrawWireDisc(gPosition, gRotation * Vector3.forward, 7f - depth); UnityEditor.Handles.DrawLine(gPosition, gPosition + segment.GlobalRotation() * (Vector3.forward * (depth + 1) * 5f)); //UnityEditor.Handles.Label(compareLocalGlobal ? segment.LocalPosition : segment.GlobalPosition(), segment.Depth().ToString()); UnityEditor.Handles.Label(segment.GlobalPosition() + Vector3.down * segment.Depth() * 10, "L:" + segment.LocalScale.ToString() + " G:" + segment.GlobalScale()); } }