summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYuri Roubinsky <chaosus89@gmail.com>2019-09-04 17:18:06 +0300
committerGitHub <noreply@github.com>2019-09-04 17:18:06 +0300
commitb25b1fb6008b32810af56e7033d915fa9f3ca677 (patch)
tree49aac960ba8eaccfd51da22b248ee5f58b9b579b
parent1046a9d143f56db7783ed6c6c674d93904c9bcb8 (diff)
parent54f0889f205cb3e34e368a1b35657acf2acc37f7 (diff)
Fix parsing array indexing symbol in visual shader expression (#31958)
Fix parsing array indexing symbol in visual shader expression
-rw-r--r--scene/resources/visual_shader.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/scene/resources/visual_shader.cpp b/scene/resources/visual_shader.cpp
index e85609468b..361aaa6745 100644
--- a/scene/resources/visual_shader.cpp
+++ b/scene/resources/visual_shader.cpp
@@ -2466,6 +2466,7 @@ String VisualShaderNodeExpression::generate_code(Shader::Mode p_mode, VisualShad
pre_symbols.push_back(";");
pre_symbols.push_back("{");
pre_symbols.push_back("[");
+ pre_symbols.push_back("]");
pre_symbols.push_back("(");
pre_symbols.push_back(" ");
pre_symbols.push_back("-");
@@ -2485,6 +2486,7 @@ String VisualShaderNodeExpression::generate_code(Shader::Mode p_mode, VisualShad
post_symbols.push_back(",");
post_symbols.push_back(";");
post_symbols.push_back("}");
+ post_symbols.push_back("[");
post_symbols.push_back("]");
post_symbols.push_back(")");
post_symbols.push_back(" ");