private void DrawCapsule2DSegments(Vector3 center) { float height = 1.0f + 0.2f * Mathf.Sin(m_phase); float radius = 0.5f - 0.2f * Mathf.Cos(m_phase); int capSegments = (int)Mathf.Floor(2.0f + 4.0f * (1.0f + Mathf.Sin(m_phase))); Color color = (m_style == DebugUtil.Style.Wireframe ? m_wireframeColor : new Color(0.5f, 0.1f, 0.7f)); DebugUtil.DrawCapsule2D(center + m_basePos, m_baseRotDeg, height, radius, capSegments, color, true, m_style); }