Merge pull request #20477 from swarnimarun/vs_duplicate_fix

Fix Visual Script duplicate issue
This commit is contained in:
Rémi Verschelde 2018-07-26 12:57:55 +02:00 committed by GitHub
commit 10af1b3444
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -1295,7 +1295,7 @@ void VisualScriptEditor::_on_nodes_duplicate() {
Ref<VisualScriptNode> node = script->get_node(edited_func, F->get());
Ref<VisualScriptNode> dupe = node->duplicate();
Ref<VisualScriptNode> dupe = node->duplicate(true);
int new_id = idc++;
to_select.insert(new_id);
@ -3170,7 +3170,7 @@ void VisualScriptEditor::_menu_option(int p_what) {
return;
}
if (node.is_valid()) {
clipboard->nodes[id] = node->duplicate();
clipboard->nodes[id] = node->duplicate(true);
clipboard->nodes_positions[id] = script->get_node_position(edited_func, id);
}
}