Skip to content

Commit

Permalink
Merge pull request #92151 from timothyqiu/frame-dup
Browse files Browse the repository at this point in the history
Fix error when duplicating visual shader node inside a Frame
  • Loading branch information
akien-mga committed May 20, 2024
2 parents eef7e29 + becc981 commit 40b4130
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions editor/plugins/visual_shader_editor_plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@
#include "scene/gui/view_panner.h"
#include "scene/main/window.h"
#include "scene/resources/curve_texture.h"
#include "scene/resources/image_texture.h"
#include "scene/resources/style_box_flat.h"
#include "scene/resources/visual_shader_nodes.h"
#include "scene/resources/visual_shader_particle_nodes.h"
Expand Down Expand Up @@ -5135,7 +5134,7 @@ void VisualShaderEditor::_dup_paste_nodes(int p_type, List<CopyItem> &r_items, c
}

int new_node_id = connection_remap[item.id];
int new_frame_id = connection_remap[node->get_frame()];
int new_frame_id = node->get_frame();
undo_redo->add_do_method(visual_shader.ptr(), "attach_node_to_frame", type, new_node_id, new_frame_id);
undo_redo->add_do_method(graph_plugin.ptr(), "attach_node_to_frame", type, new_node_id, new_frame_id);
}
Expand Down

0 comments on commit 40b4130

Please sign in to comment.