Is there any way to retrieve the position of any point in a Path2D? I designed them manually (I don't know if they can be coded too)

  • xyz replied to this.
  • Catapult Sure. You can use get_point_position() method of path's curve object. There are similar methods for control points. Check the scripting reference for the Curve object.

    for i in range($Path2D.curve.point_count):
    	print($Path2D.curve.get_point_position(i))

    Catapult Sure. You can use get_point_position() method of path's curve object. There are similar methods for control points. Check the scripting reference for the Curve object.

    for i in range($Path2D.curve.point_count):
    	print($Path2D.curve.get_point_position(i))

      xyz First of all, thanks. I was looking in the wrong direction, that is: I was looking for an imaginary method get_point_positions(), directly returning an array of points. Or for the possibiliy to have points with a string name. :-)