diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2016-10-09 14:34:26 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-10-09 14:34:26 +0200 |
commit | 59d92d82a71428f86931a6331fad882d4d2bcc85 (patch) | |
tree | f319bd093769abf3255445c5df3628ed5fd630fc /tools | |
parent | fda72354c99d03dfdd34a072fdeae9877f49eee3 (diff) | |
parent | ced8fb480600b9b64e0c82735e592c2103accb3f (diff) |
Merge pull request #6703 from razvanc-r/fix_node_path
fixes #6695 - MultiNodeEdit edit path in exported NodePath
Diffstat (limited to 'tools')
-rw-r--r-- | tools/editor/multi_node_edit.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/tools/editor/multi_node_edit.cpp b/tools/editor/multi_node_edit.cpp index 4d27b8e349..e4ceaf4a8b 100644 --- a/tools/editor/multi_node_edit.cpp +++ b/tools/editor/multi_node_edit.cpp @@ -53,7 +53,14 @@ bool MultiNodeEdit::_set(const StringName& p_name, const Variant& p_value){ if (!n) continue; - ur->add_do_property(n,name,p_value); + if (p_value.get_type() == Variant::NODE_PATH) { + Node *tonode = n->get_node(p_value); + NodePath p_path = n->get_path_to(tonode); + ur->add_do_property(n,name,p_path); + } else { + ur->add_do_property(n,name,p_value); + } + ur->add_undo_property(n,name,n->get(name)); |