How can I move a 3D KinematicBody to random positions avoiding a NavigationMeshInstance:

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

Look at the title. I have an enemy that is a KinematicBody and I want to move it to random positions, one and then another one, without being killed, but avoiding the map hosted on a NavigationMeshInstance using GDScript on a 3D space.
How can I do it?

Thanks in advanced.