# Filename: pl_point_inside.py
# Purpose: Returns true if a point is inside the polyline.
# Returns: Bool.

from maptek import vulcan_gui

# use dynamic selection to select correct line object
sel = vulcan_gui.selection("Select layer object to connect points.")
sel.criteria = ["LINE", "POLYGON"]  # limit selection to a polyline object
sel.single_object = True  # prevents selection prompt from asking more than once

pt = [79577.67779822588,4890.435805968996,0.0,0.0,0,'']

for obj in sel:
    obj_name = obj.get_name()  # get name of object
    loc = obj.point_inside(pt)  # check location of point 
    print(f"Point inside {obj_name}: {loc}")