From 34591f94515f3ced1448686b729c2ed8cccebd1d Mon Sep 17 00:00:00 2001 From: Gilles Roudiere Date: Thu, 22 Feb 2018 20:46:53 +0100 Subject: [PATCH] Fixes collisions shape selection (cherry picked from commit c250a9a9f9e3af665daf89c0cbbdaa4cea2a6a83) --- scene/resources/shape_2d.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scene/resources/shape_2d.h b/scene/resources/shape_2d.h index ed655b8a930..7eb0406bd85 100644 --- a/scene/resources/shape_2d.h +++ b/scene/resources/shape_2d.h @@ -45,7 +45,7 @@ protected: Shape2D(const RID &p_rid); public: - virtual bool _edit_is_selected_on_click(const Point2 &p_point, double p_tolerance) const { return true; } + virtual bool _edit_is_selected_on_click(const Point2 &p_point, double p_tolerance) const { return get_rect().has_point(p_point); } void set_custom_solver_bias(real_t p_bias); real_t get_custom_solver_bias() const;