summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYuri Rubinsky <chaosus89@gmail.com>2024-03-08 21:28:05 +0300
committerYuri Rubinsky <chaosus89@gmail.com>2024-03-08 21:28:05 +0300
commitd9292ea51efa4f3f22dd86254b5cb11f742565b6 (patch)
tree217231d0d224b4246b86ec0267cb6fa29f4e5656
parentffc41fb76df5922321cdd98cce12715a039629b0 (diff)
downloadredot-engine-d9292ea51efa4f3f22dd86254b5cb11f742565b6.tar.gz
Fix possible crash when converting a node to other in visual shader
-rw-r--r--editor/plugins/visual_shader_editor_plugin.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/editor/plugins/visual_shader_editor_plugin.cpp b/editor/plugins/visual_shader_editor_plugin.cpp
index 02e2a9f487..b6a4a14117 100644
--- a/editor/plugins/visual_shader_editor_plugin.cpp
+++ b/editor/plugins/visual_shader_editor_plugin.cpp
@@ -482,6 +482,7 @@ void VisualShaderGraphPlugin::add_node(VisualShader::Type p_type, int p_id, bool
if (p_just_update) {
Link &link = links[p_id];
+ link.visual_node = vsnode.ptr();
link.graph_element = node;
link.preview_box = nullptr;
link.preview_pos = -1;