diff options
Diffstat (limited to 'scene/2d/navigation_polygon.h')
-rw-r--r-- | scene/2d/navigation_polygon.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/scene/2d/navigation_polygon.h b/scene/2d/navigation_polygon.h index cbc1711a32..92cfc8f5e6 100644 --- a/scene/2d/navigation_polygon.h +++ b/scene/2d/navigation_polygon.h @@ -32,6 +32,9 @@ #define NAVIGATION_POLYGON_H #include "scene/2d/node_2d.h" +#include "scene/resources/navigation_mesh.h" + +class Mutex; class NavigationPolygon : public Resource { @@ -47,6 +50,10 @@ class NavigationPolygon : public Resource { mutable Rect2 item_rect; mutable bool rect_cache_dirty; + Mutex *navmesh_generation; + // Navigation mesh + Ref<NavigationMesh> navmesh; + protected: static void _bind_methods(); @@ -81,6 +88,8 @@ public: Vector<int> get_polygon(int p_idx); void clear_polygons(); + Ref<NavigationMesh> get_mesh(); + NavigationPolygon(); }; @@ -91,7 +100,7 @@ class NavigationPolygonInstance : public Node2D { GDCLASS(NavigationPolygonInstance, Node2D); bool enabled; - int nav_id; + RID region; Navigation2D *navigation; Ref<NavigationPolygon> navpoly; @@ -116,6 +125,7 @@ public: String get_configuration_warning() const; NavigationPolygonInstance(); + ~NavigationPolygonInstance(); }; #endif // NAVIGATIONPOLYGON_H |