drawGizmos() public static method

helper for drawing gizmos in the editor
public static drawGizmos ( Vector3 path, float resolution = 50 ) : void
path Vector3
resolution float
return void
示例#1
0
    /// <summary>
    /// helper for drawing gizmos in the editor
    /// </summary>
    public static void drawGizmos(Vector3[] path, float resolution = 50)
    {
        // horribly inefficient but it only runs in the editor
        var spline = new GoSpline(path);

        spline.drawGizmos(resolution);
    }
 void OnDrawGizmos()
 {
     if (eventPath.Count > 0)
     {
         var spline = new GoSpline(eventPath);
         Gizmos.color = Color.magenta;
         spline.drawGizmos(50f);
     }
 }
 public void OnDrawGizmos()
 {
     if (!forceStraightLinePath)
     {
         GoSpline goSpline = new GoSpline(nodes);
         Gizmos.color = pathColor;
         goSpline.drawGizmos(pathResolution);
     }
 }
示例#4
0
 public void OnDrawGizmos ()
 {
     // the editor will draw paths when force straight line is on
     if ( !forceStraightLinePath )
     {
         var spline = new GoSpline( nodes );
         Gizmos.color = pathColor;
         spline.drawGizmos( pathResolution );
     }
 }
示例#5
0
 public void OnDrawGizmos()
 {
     // the editor will draw paths when force straight line is on
     if (!forceStraightLinePath)
     {
         var spline = new GoSpline(nodes);
         Gizmos.color = pathColor;
         spline.drawGizmos(pathResolution);
     }
 }
示例#6
0
 static public int drawGizmos(IntPtr l)
 {
     try {
         GoSpline      self = (GoSpline)checkSelf(l);
         System.Single a1;
         checkType(l, 2, out a1);
         self.drawGizmos(a1);
         return(0);
     }
     catch (Exception e) {
         return(error(l, e));
     }
 }
示例#7
0
 static public int drawGizmos_s(IntPtr l)
 {
     try {
         UnityEngine.Vector3[] a1;
         checkType(l, 1, out a1);
         System.Single a2;
         checkType(l, 2, out a2);
         GoSpline.drawGizmos(a1, a2);
         return(0);
     }
     catch (Exception e) {
         return(error(l, e));
     }
 }
示例#8
0
 public void OnDrawGizmos()
 {
     if (displayInEditor && nodes != null && nodes.Count > 1)
     {
         Gizmos.color = lineColor;
         if (forceStraightLinePath)
         {
             for (int i = 0; i < nodes.Count - 1; i++)
             {
                 Gizmos.DrawLine(nodes[i], nodes[i + 1]);
             }
         }
         else
         {
             var spline = new GoSpline(nodes);
             spline.drawGizmos(50);
         }
     }
 }
 void OnDrawGizmos()
 {
     if(eventPath.Count > 0) {
         var spline = new GoSpline(eventPath);
         Gizmos.color = Color.magenta;
         spline.drawGizmos(50f);
     }
 }
示例#10
0
	/// <summary>
	/// helper for drawing gizmos in the editor
	/// </summary>
	public static void drawGizmos( Vector3[] path, float resolution = 50 )
	{
		// horribly inefficient but it only runs in the editor
		var spline = new GoSpline( path );
		spline.drawGizmos( resolution );
	}
示例#11
0
    public static void drawGizmos(Vector3[] path, float resolution = 50f)
    {
        GoSpline goSpline = new GoSpline(path);

        goSpline.drawGizmos(resolution);
    }