コード例 #1
0
        private void ShowDirections()
        {
            Handles.color = Color.green;
            Vector3 point = m_Spline.GetPoint(0f);

            Handles.DrawLine(point, point + m_Spline.GetDirection(0f) * c_DirectionScale);

            int steps = c_LineStepsPerCurve * m_Spline.GetCurveCount();

            for (int i = 1; i <= steps; i++)
            {
                point = m_Spline.GetPoint(i / (float)steps);
                Handles.DrawLine(point, point + m_Spline.GetDirection(i / (float)steps) * c_DirectionScale);
            }
        }