Click or drag to resize

NavigationGetClosestPointToSegment Method

Returns the navigation point closest to the given line segment. When enabling use_collision, only considers intersection points between segment and navigation meshes. If multiple intersection points are found, the one closest to the segment start point is returned.

Namespace:  Godot
Assembly:  GodotSharp (in GodotSharp.dll) Version: 1.0.0
Syntax
C#
public Vector3 GetClosestPointToSegment(
	Vector3 start,
	Vector3 end,
	bool useCollision = false
)

Parameters

start
Type: GodotVector3

[Missing <param name="start"/> documentation for "M:Godot.Navigation.GetClosestPointToSegment(Godot.Vector3,Godot.Vector3,System.Boolean)"]

end
Type: GodotVector3

[Missing <param name="end"/> documentation for "M:Godot.Navigation.GetClosestPointToSegment(Godot.Vector3,Godot.Vector3,System.Boolean)"]

useCollision (Optional)
Type: SystemBoolean

[Missing <param name="useCollision"/> documentation for "M:Godot.Navigation.GetClosestPointToSegment(Godot.Vector3,Godot.Vector3,System.Boolean)"]

Return Value

Type: Vector3

[Missing <returns> documentation for "M:Godot.Navigation.GetClosestPointToSegment(Godot.Vector3,Godot.Vector3,System.Boolean)"]

See Also