summaryrefslogtreecommitdiff
path: root/scene/2d/collision_polygon_2d.cpp
diff options
context:
space:
mode:
authorGilles Roudière <gilles.roudiere@gmail.com>2019-10-21 23:37:07 +0200
committerGilles Roudière <gilles.roudiere@gmail.com>2020-01-09 22:15:48 +0100
commitb5251eb00f7daa339ad61923f16608432a902f46 (patch)
treedc8034fc276d71436ef611ff392a56297e64cadc /scene/2d/collision_polygon_2d.cpp
parent76678b2609921f27f52c1a2e2bd62b8d2a27bb4b (diff)
Don't compile editor-only function when tools=no
Diffstat (limited to 'scene/2d/collision_polygon_2d.cpp')
-rw-r--r--scene/2d/collision_polygon_2d.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/scene/2d/collision_polygon_2d.cpp b/scene/2d/collision_polygon_2d.cpp
index 3090c9956e..d9cc94c6eb 100644
--- a/scene/2d/collision_polygon_2d.cpp
+++ b/scene/2d/collision_polygon_2d.cpp
@@ -227,6 +227,7 @@ CollisionPolygon2D::BuildMode CollisionPolygon2D::get_build_mode() const {
return build_mode;
}
+#ifdef TOOLS_ENABLED
Rect2 CollisionPolygon2D::_edit_get_rect() const {
return aabb;
@@ -240,6 +241,7 @@ bool CollisionPolygon2D::_edit_is_selected_on_click(const Point2 &p_point, doubl
return Geometry::is_point_in_polygon(p_point, Variant(polygon));
}
+#endif
String CollisionPolygon2D::get_configuration_warning() const {