diff --git a/servers/rendering/shader_language.cpp b/servers/rendering/shader_language.cpp index 41f2fbb03f56..a2da26eb65e9 100644 --- a/servers/rendering/shader_language.cpp +++ b/servers/rendering/shader_language.cpp @@ -4639,6 +4639,10 @@ bool ShaderLanguage::_validate_assign(Node *p_node, const FunctionInfo &p_functi return false; } + if (shader->varyings.has(var->name)) { + return _validate_varying_assign(shader->varyings[var->name], r_message); + } + if (!(p_function_info.built_ins.has(var->name) && p_function_info.built_ins[var->name].constant)) { return true; }