How to set navigation shape for tilemap with script

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By po2009n

polygon.add_outline(PoolVector2Array(outline))
polygon.make_polygons_from_outlines()
tuj.tile_set_navigation_polygon(le, polygon)

How to implement in 4.0 according to the 3.0 method