diff options
Diffstat (limited to 'modules/gdscript/gdscript_analyzer.cpp')
| -rw-r--r-- | modules/gdscript/gdscript_analyzer.cpp | 6 | 
1 files changed, 6 insertions, 0 deletions
diff --git a/modules/gdscript/gdscript_analyzer.cpp b/modules/gdscript/gdscript_analyzer.cpp index 8b4c245bf6..7ed440929c 100644 --- a/modules/gdscript/gdscript_analyzer.cpp +++ b/modules/gdscript/gdscript_analyzer.cpp @@ -3329,8 +3329,11 @@ void GDScriptAnalyzer::reduce_subscript(GDScriptParser::SubscriptNode *p_subscri  							case Variant::VECTOR2I:  							case Variant::VECTOR3:  							case Variant::VECTOR3I: +							case Variant::VECTOR4: +							case Variant::VECTOR4I:  							case Variant::TRANSFORM2D:  							case Variant::TRANSFORM3D: +							case Variant::PROJECTION:  								error = index_type.builtin_type != Variant::INT && index_type.builtin_type != Variant::FLOAT &&  										index_type.builtin_type != Variant::STRING;  								break; @@ -3393,6 +3396,7 @@ void GDScriptAnalyzer::reduce_subscript(GDScriptParser::SubscriptNode *p_subscri  					case Variant::PACKED_INT64_ARRAY:  					case Variant::VECTOR2I:  					case Variant::VECTOR3I: +					case Variant::VECTOR4I:  						result_type.builtin_type = Variant::INT;  						break;  					// Return float. @@ -3400,6 +3404,7 @@ void GDScriptAnalyzer::reduce_subscript(GDScriptParser::SubscriptNode *p_subscri  					case Variant::PACKED_FLOAT64_ARRAY:  					case Variant::VECTOR2:  					case Variant::VECTOR3: +					case Variant::VECTOR4:  					case Variant::QUATERNION:  						result_type.builtin_type = Variant::FLOAT;  						break; @@ -3430,6 +3435,7 @@ void GDScriptAnalyzer::reduce_subscript(GDScriptParser::SubscriptNode *p_subscri  						break;  					// Depends on the index.  					case Variant::TRANSFORM3D: +					case Variant::PROJECTION:  					case Variant::PLANE:  					case Variant::COLOR:  					case Variant::DICTIONARY:  |