{"name":"GDShader","scopeName":"source.gdshader","patterns":[{"include":"#any"}],"repository":{"any":{"patterns":[{"include":"#comment"},{"include":"#enclosed"},{"include":"#classifier"},{"include":"#definition"},{"include":"#keyword"},{"include":"#element"},{"include":"#separator"},{"include":"#operator"}]},"arraySize":{"name":"meta.array-size.gdshader","begin":"\\[","end":"\\]","patterns":[{"include":"#comment"},{"include":"#keyword"},{"include":"#element"},{"include":"#separator"}],"captures":{"0":{"name":"punctuation.bracket.gdshader"}}},"classifier":{"name":"meta.classifier.gdshader","begin":"(?=\\b(?:shader_type|render_mode)\\b)","end":"(?\u003c=;)","patterns":[{"include":"#comment"},{"include":"#keyword"},{"include":"#identifierClassification"},{"include":"#separator"}]},"classifierKeyword":{"name":"keyword.language.classifier.gdshader","match":"\\b(?:shader_type|render_mode)\\b"},"comment":{"patterns":[{"include":"#commentLine"},{"include":"#commentBlock"}]},"commentBlock":{"name":"comment.block.gdshader","begin":"/\\*","end":"\\*/"},"commentLine":{"name":"comment.line.double-slash.gdshader","begin":"//","end":"$"},"constantFloat":{"name":"constant.language.float.gdshader","match":"\\b(?:E|PI|TAU)\\b"},"constructor":{"name":"entity.name.type.constructor.gdshader","match":"\\b[a-zA-Z_]\\w*(?=\\s*\\[\\s*\\w*\\s*\\]\\s*[(])|\\b[A-Z]\\w*(?=\\s*[(])"},"controlKeyword":{"name":"keyword.control.gdshader","match":"\\b(?:if|else|do|while|for|continue|break|switch|case|default|return|discard)\\b"},"definition":{"patterns":[{"include":"#structDefinition"}]},"element":{"patterns":[{"include":"#literalFloat"},{"include":"#literalInt"},{"include":"#literalBool"},{"include":"#identifierType"},{"include":"#constructor"},{"include":"#processorFunction"},{"include":"#identifierFunction"},{"include":"#swizzling"},{"include":"#identifierField"},{"include":"#constantFloat"},{"include":"#languageVariable"},{"include":"#identifierVariable"}]},"enclosed":{"name":"meta.parenthesis.gdshader","begin":"\\(","end":"\\)","patterns":[{"include":"#any"}],"captures":{"0":{"name":"punctuation.parenthesis.gdshader"}}},"fieldDefinition":{"name":"meta.definition.field.gdshader","begin":"\\b[a-zA-Z_]\\w*\\b","end":"(?\u003c=;)","patterns":[{"include":"#comment"},{"include":"#keyword"},{"include":"#arraySize"},{"include":"#fieldName"},{"include":"#any"}],"beginCaptures":{"0":{"patterns":[{"include":"#typeKeyword"},{"name":"entity.name.type.gdshader","match":".+"}]}}},"fieldName":{"name":"entity.name.variable.field.gdshader","match":"\\b[a-zA-Z_]\\w*\\b"},"hintKeyword":{"name":"support.type.annotation.gdshader","match":"\\b(?:source_color|hint_(?:color|range|(?:black_)?albedo|normal|(?:default_)?(?:white|black)|aniso|anisotropy|roughness_(?:[rgba]|normal|gray))|filter_(?:nearest|linear)(?:_mipmap(?:_anisotropic)?)?|repeat_(?:en|dis)able)\\b"},"identifierClassification":{"name":"entity.other.inherited-class.gdshader","match":"\\b[a-z_]+\\b"},"identifierField":{"match":"([.])\\s*([a-zA-Z_]\\w*)\\b(?!\\s*\\()","captures":{"1":{"name":"punctuation.accessor.gdshader"},"2":{"name":"entity.name.variable.field.gdshader"}}},"identifierFunction":{"name":"entity.name.function.gdshader","match":"\\b[a-zA-Z_]\\w*(?=(?:\\s|/\\*(?:\\*(?!/)|[^*])*\\*/)*[(])"},"identifierType":{"name":"entity.name.type.gdshader","match":"\\b[a-zA-Z_]\\w*(?=(?:\\s*\\[\\s*\\w*\\s*\\])?\\s+[a-zA-Z_]\\w*\\b)"},"identifierVariable":{"name":"variable.name.gdshader","match":"\\b[a-zA-Z_]\\w*\\b"},"keyword":{"patterns":[{"include":"#classifierKeyword"},{"include":"#structKeyword"},{"include":"#controlKeyword"},{"include":"#modifierKeyword"},{"include":"#precisionKeyword"},{"include":"#typeKeyword"},{"include":"#hintKeyword"}]},"languageVariable":{"name":"variable.language.gdshader","match":"\\b(?:[A-Z][A-Z_0-9]*)\\b"},"literalBool":{"name":"constant.language.boolean.gdshader","match":"\\b(?:false|true)\\b"},"literalFloat":{"name":"constant.numeric.float.gdshader","match":"\\b(?:\\d+[eE][-+]?\\d+|(?:\\d*[.]\\d+|\\d+[.])(?:[eE][-+]?\\d+)?)[fF]?"},"literalInt":{"name":"constant.numeric.integer.gdshader","match":"\\b(?:0[xX][0-9A-Fa-f]+|\\d+[uU]?)\\b"},"modifierKeyword":{"name":"storage.modifier.gdshader","match":"\\b(?:const|global|instance|uniform|varying|in|out|inout|flat|smooth)\\b"},"operator":{"name":"keyword.operator.gdshader","match":"\\\u003c\\\u003c\\=?|\\\u003e\\\u003e\\=?|[-+*/\u0026|\u003c\u003e=!]\\=|\\\u0026\\\u0026|[|][|]|[-+~!*/%\u003c\u003e\u0026^|=]"},"precisionKeyword":{"name":"storage.type.built-in.primitive.precision.gdshader","match":"\\b(?:low|medium|high)p\\b"},"processorFunction":{"name":"support.function.gdshader","match":"\\b(?:vertex|fragment|light|start|process|sky|fog)(?=(?:\\s|/\\*(?:\\*(?!/)|[^*])*\\*/)*[(])"},"separator":{"patterns":[{"name":"punctuation.accessor.gdshader","match":"[.]"},{"include":"#separatorComma"},{"name":"punctuation.terminator.statement.gdshader","match":"[;]"},{"name":"keyword.operator.type.annotation.gdshader","match":"[:]"}]},"separatorComma":{"name":"punctuation.separator.comma.gdshader","match":"[,]"},"structDefinition":{"begin":"(?=\\b(?:struct)\\b)","end":"(?\u003c=;)","patterns":[{"include":"#comment"},{"include":"#keyword"},{"include":"#structName"},{"include":"#structDefinitionBlock"},{"include":"#separator"}]},"structDefinitionBlock":{"name":"meta.definition.block.struct.gdshader","begin":"\\{","end":"\\}","patterns":[{"include":"#comment"},{"include":"#precisionKeyword"},{"include":"#fieldDefinition"},{"include":"#keyword"},{"include":"#any"}],"captures":{"0":{"name":"punctuation.definition.block.struct.gdshader"}}},"structKeyword":{"name":"keyword.other.struct.gdshader","match":"\\b(?:struct)\\b"},"structName":{"name":"entity.name.type.struct.gdshader","match":"\\b[a-zA-Z_]\\w*\\b"},"swizzling":{"match":"([.])\\s*([xyzw]{2,4}|[rgba]{2,4}|[stpq]{2,4})\\b","captures":{"1":{"name":"punctuation.accessor.gdshader"},"2":{"name":"variable.other.property.gdshader"}}},"typeKeyword":{"name":"support.type.gdshader","match":"\\b(?:void|bool|[biu]?vec[234]|u?int|float|mat[234]|[iu]?sampler(?:3D|2D(?:Array)?)|samplerCube)\\b"}}}