From 70e04ae26f23cb3cef687fa12906c2097549efff Mon Sep 17 00:00:00 2001 From: volzhs Date: Wed, 23 May 2018 23:43:47 +0900 Subject: [PATCH] Use relative node path when assigning a node on inspector --- editor/editor_properties.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/editor/editor_properties.cpp b/editor/editor_properties.cpp index 0625aeee54a..d1968468f84 100644 --- a/editor/editor_properties.cpp +++ b/editor/editor_properties.cpp @@ -1522,7 +1522,8 @@ EditorPropertyColor::EditorPropertyColor() { void EditorPropertyNodePath::_node_selected(const NodePath &p_path) { - emit_signal("property_changed", get_edited_property(), p_path); + Node *base_node = Object::cast_to(get_edited_object()); + emit_signal("property_changed", get_edited_property(), base_node->get_path().rel_path_to(p_path)); update_property(); }