Something went wrong. Try again.
Starship Simulator Controls thoriumsim.com
Something went wrong. Try again.
15 kB · 791 lines
JSON
at develop
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792{ "$schema": "https://raw.githubusercontent.com/martinring/tmlanguage/master/tmlanguage.json", "name": "ink", "scopeName": "source.ink", "patterns": [ { "include": "#comments" }, { "include": "#tags" }, { "include": "#todo" }, { "include": "#includeStatements" }, { "include": "#multilineBlocks" }, { "include": "#conditionalBlocks" }, { "include": "#conditionalChoices" }, { "include": "#conditionalText" }, { "include": "#variableText" }, { "include": "#printingVariables" }, { "include": "#functionDeclarations" }, { "include": "#knotDeclarations" }, { "include": "#knots" }, { "include": "#glue" }, { "include": "#alternatives" }, { "include": "#labelledGathersChoices" }, { "include": "#choices" }, { "include": "#gathers" }, { "include": "#declarations" }, { "include": "#tildeLogic" } ], "repository": { "comments": { "patterns": [ { "name": "comment.line.double-slash.ink", "match": "//.*$" }, { "name": "comment.block.ink", "begin": "/\\*", "end": "\\*/" } ] }, "todo": { "patterns": [ { "name": "keyword.other.todo.ink", "match": "\\bTODO:.*$" } ] }, "choices": { "patterns": [ { "name": "keyword.other.choice.ink", "match": "^\\s*([\\*\\+]\\s*)+" }, { "name": "keyword.other.brackets.choice.ink", "match": "(?<!\\\\)[\\[\\]]" } ] }, "gathers": { "patterns": [ { "name": "keyword.other.gather.ink", "match": "^\\s*-(?!\\s*>)(\\s*-)*" } ] }, "labelledGathersChoices": { "patterns": [ { "begin": "^\\s*([-*+])(\\s*[-*+])*\\s*(?=\\()", "beginCaptures": { "1": { "name": "keyword.other.gather.ink" } }, "end": "(?=\\s|$)", "patterns": [ { "name": "entity.name.function.ink", "begin": "\\(", "end": "\\)", "patterns": [ { "name": "entity.name.function.ink", "match": "[^()]+" } ] } ] } ] }, "knots": { "patterns": [ { "name": "keyword.control.return.ink", "match": "(?<=->\\s*)(END|DONE)" }, { "name": "keyword.other.divert.ink", "match": "->" }, { "name": "entity.name.function.divert.ink", "match": "(?<=->\\s*)[a-zA-Z0-9_]+(?:\\.[a-zA-Z0-9_]+)?" }, { "name": "keyword.other.thread.ink", "match": "<-" }, { "name": "entity.name.function.thread.ink", "match": "(?<=<-\\s*)[a-zA-Z0-9_]+(?:\\.[a-zA-Z0-9_]+)?" }, { "name": "meta.function.divert.call.ink", "begin": "(?<=->\\s*[a-zA-Z0-9_]+)\\s*\\(", "end": "\\)", "patterns": [ { "include": "#knots" }, { "include": "#logic" } ] }, { "name": "meta.function.thread.call.ink", "begin": "(?<=<-\\s*[a-zA-Z0-9_]+)\\s*\\(", "end": "\\)", "patterns": [ { "include": "#knots" }, { "include": "#logic" } ] } ] }, "knotDeclarations": { "patterns": [ { "name": "meta.knot.declaration.ink", "begin": "^(?:\\s*)(=+)\\s*", "beginCaptures": { "1": { "name": "keyword.other.knot.ink" } }, "end": "\\s*(=+)?(?=\\s*(//|/\\*|$))", "endCaptures": { "1": { "name": "keyword.other.knot.ink" } }, "patterns": [ { "name": "entity.name.function.ink", "match": "[a-zA-Z0-9_]+" }, { "name": "meta.function.parameters.ink", "begin": "\\(", "end": "\\)", "patterns": [ { "include": "#knots" }, { "include": "#logic" } ] }, { "include": "#comments" }, { "include": "#tags" } ] } ] }, "functionDeclarations": { "patterns": [ { "name": "meta.function.declaration.ink", "begin": "^(?:\\s*)(=+)(\\s*)(function)(\\s+)", "beginCaptures": { "1": { "name": "keyword.other.knot.ink" }, "3": { "name": "keyword.other.function.ink" } }, "end": "$", "patterns": [ { "name": "entity.name.function.ink", "match": "[a-zA-Z0-9_]+" }, { "name": "meta.function.parameters.ink", "begin": "\\(", "end": "\\)", "patterns": [ { "include": "#knots" }, { "include": "#logic" } ] }, { "name": "keyword.other.knot.ink", "match": "=+(?=\\s*$)" } ] } ] }, "glue": { "patterns": [ { "name": "keyword.other.glue.ink", "match": "<>" } ] }, "variableText": { "patterns": [ { "name": "meta.brace.curly.variableText.ink", "begin": "(?<!\\\\)\\{(?=[^}]*\\|)", "beginCaptures": { "0": { "name": "keyword.other.ink" } }, "end": "(?<!\\\\)\\}", "endCaptures": { "0": { "name": "keyword.other.ink" } }, "patterns": [ { "name": "keyword.other.ink", "match": "(?<=\\{)\\s*[&!~]" }, { "name": "keyword.other.ink", "match": "(?<!\\\\)\\|" }, { "include": "#knots" }, { "include": "#glue" }, { "include": "#choices" } ] } ] }, "conditionalChoices": { "patterns": [ { "name": "meta.brace.curly.conditionalChoice.ink", "begin": "(?<=^\\s*[\\*\\+]\\s*)(\\{)(?=[^\\n}]*\\})", "beginCaptures": { "1": { "name": "keyword.other.brackets.conditional.ink" } }, "end": "(?<!\\\\)(\\})", "endCaptures": { "1": { "name": "keyword.other.brackets.conditional.ink" } }, "patterns": [ { "include": "#logic" } ] } ] }, "conditionalText": { "patterns": [ { "name": "meta.brace.curly.conditionalText.ink", "begin": "(?<!\\\\)(\\{)(?=[^\\n}]*:)", "beginCaptures": { "1": { "name": "keyword.other.brackets.conditional.ink" } }, "end": "(?<!\\\\)(\\})", "endCaptures": { "1": { "name": "keyword.other.brackets.conditional.ink" } }, "patterns": [ { "name": "keyword.other.conditional.ink", "begin": "(?<=\\{)\\s*", "end": ":", "patterns": [ { "include": "#logic" } ] }, { "name": "keyword.other.conditional.ink", "match": ":" }, { "name": "meta.conditional.text.ink", "begin": "(?<=:)", "end": "(?=\\})", "patterns": [ { "name": "keyword.other.alternative.ink", "match": "(?<!\\\\)\\|" }, { "include": "#multilineBlocks" }, { "include": "#conditionalBlocks" }, { "include": "#conditionalChoices" }, { "include": "#conditionalText" }, { "include": "#variableText" }, { "include": "#printingVariables" } ] } ] } ] }, "conditionalBlocks": { "patterns": [ { "name": "meta.conditional.block.ink", "begin": "(?<!\\\\)(\\{)(?=[^}]*\\n)", "beginCaptures": { "1": { "name": "keyword.other.brackets.conditional.ink" } }, "end": "(?<!\\\\)(\\})", "endCaptures": { "1": { "name": "keyword.other.brackets.conditional.ink" } }, "patterns": [ { "name": "meta.conditional.firstline.no-dash.ink", "begin": "(?<=\\{)\\s*(-)?\\s*(?!(->))", "beginCaptures": { "1": { "name": "keyword.other.conditional.ink" } }, "end": "$", "patterns": [ { "include": "#logic" }, { "name": "keyword.other.conditional.ink", "match": ":" } ] }, { "name": "meta.conditional.branch.ink", "begin": "^(?!\\s*->)(\\s*-\\s*)(else)?", "beginCaptures": { "1": { "name": "keyword.other.conditional.ink" }, "2": { "name": "keyword.control.else.ink" } }, "end": ":", "endCaptures": { "0": { "name": "keyword.other.conditional.ink" } }, "patterns": [ { "include": "#logic" } ] }, { "name": "text.plain.ink", "patterns": [ { "include": "#tildeLogic" }, { "include": "#knots" }, { "include": "#glue" }, { "include": "#choices" }, { "include": "#comments" }, { "include": "#tags" } ] } ] } ] }, "multilineBlocks": { "patterns": [ { "name": "meta.multiline.block.ink", "begin": "(?<!\\\\)(\\{)\\s*(stopping|shuffle(?:\\s+(?:once|stopping))?|cycle|once)\\s*:", "beginCaptures": { "1": { "name": "keyword.other.brackets.conditional.ink" }, "2": { "name": "keyword.other.multiline-type.ink" } }, "end": "(?<!\\\\)(\\})", "endCaptures": { "1": { "name": "keyword.other.brackets.conditional.ink" } }, "patterns": [ { "name": "meta.multiline.line.ink", "begin": "^\\s*-\\s*", "beginCaptures": { "0": { "name": "keyword.other.multiline-line.ink" } }, "end": "$", "patterns": [ { "include": "#tildeLogic" }, { "include": "#knots" }, { "include": "#glue" }, { "include": "#choices" }, { "include": "#comments" }, { "include": "#tags" } ] }, { "match": ".+", "name": "text.plain.ink", "patterns": [ { "include": "#tildeLogic" }, { "include": "#knots" }, { "include": "#glue" }, { "include": "#choices" }, { "include": "#comments" }, { "include": "#tags" } ] } ] } ] }, "printingVariables": { "patterns": [ { "name": "meta.printing.variable.ink", "begin": "(?<!\\\\)(\\{)", "beginCaptures": { "1": { "name": "keyword.other.brackets.conditional.ink" } }, "end": "(?<!\\\\)(\\})", "endCaptures": { "1": { "name": "keyword.other.brackets.conditional.ink" } }, "patterns": [ { "include": "#logic" } ] } ] }, "logic": { "patterns": [ { "include": "#comments" }, { "include": "#tags" }, { "include": "#knots" }, { "name": "keyword.control.return.ink", "match": "\\breturn\\b" }, { "name": "storage.type.temp.ink", "match": "\\btemp\\b" }, { "name": "variable.other.local.ink", "match": "(?<=\\btemp\\s+)[a-zA-Z_][a-zA-Z0-9_]*" }, { "name": "keyword.operator.arithmetic.ink", "match": "\\+|-|\\*|/|%|\\bmod\\b" }, { "name": "keyword.operator.comparison.ink", "match": "==|!=|<=|>=|<|>|\\?" }, { "name": "constant.language.boolean.ink", "match": "\\b(not|or)\\b" }, { "name": "support.function.math.ink", "match": "\\b(POW|RANDOM|INT|FLOOR|FLOAT)\\b" }, { "name": "constant.language.boolean.ink", "match": "\\b(true|false)\\b" }, { "name": "constant.numeric.ink", "match": "\\b\\d+(?:\\.\\d+)?\\b" }, { "name": "string.quoted.double.ink", "begin": "\"", "end": "\"", "patterns": [ { "name": "constant.character.escape.ink", "match": "\\\\." }, { "include": "#variableText" }, { "include": "#printingVariables" } ] }, { "name": "entity.name.function.ink", "match": "\\b[a-zA-Z_][a-zA-Z0-9_]*(?=\\s*\\()" }, { "name": "variable.other.global.ink", "match": "\\b[a-zA-Z_][a-zA-Z0-9_]*\\b" } ] }, "alternatives": { "patterns": [ { "name": "keyword.other.alternative.ink", "match": "(?<!\\\\)\\|" } ] }, "declarations": { "patterns": [ { "name": "meta.declaration.ink", "begin": "^\\s*(VAR|CONST|LIST)\\b", "beginCaptures": { "1": { "name": "storage.type.ink" } }, "end": "$", "patterns": [ { "name": "variable.other.global.ink", "match": "(?<=VAR\\s+)[a-zA-Z_][a-zA-Z0-9_]*" }, { "name": "variable.other.constant.ink", "match": "(?<=CONST\\s+)[a-zA-Z_][a-zA-Z0-9_]*" }, { "name": "variable.other.list.ink", "match": "(?<=LIST\\s+)[a-zA-Z_][a-zA-Z0-9_]*" }, { "name": "keyword.operator.assignment.ink", "match": "=" }, { "begin": "(?<=\\=)", "end": "$", "patterns": [ { "include": "#knots" }, { "include": "#logic" } ] } ] } ] }, "tildeLogic": { "patterns": [ { "name": "meta.tilde.logic.ink", "begin": "~", "beginCaptures": { "0": { "name": "keyword.other.tilde.ink" } }, "end": "$", "patterns": [ { "include": "#logic" } ] } ] }, "includeStatements": { "patterns": [ { "name": "meta.include.line.ink", "begin": "^\\s*(INCLUDE)\\b", "beginCaptures": { "1": { "name": "keyword.control.include.ink" } }, "end": "$", "patterns": [ { "name": "string.unquoted.filename.ink", "match": "[a-zA-Z0-9_./\\\\-]+(?:\\.ink)?" } ] } ] }, "tags": { "patterns": [ { "name": "punctuation.definition.tag.ink", "begin": "#", "beginCaptures": { "0": { "name": "punctuation.definition.tag.ink" } }, "end": "$", "patterns": [ { "include": "#multilineBlocks" }, { "include": "#conditionalBlocks" }, { "include": "#conditionalChoices" }, { "include": "#conditionalText" }, { "include": "#variableText" }, { "include": "#printingVariables" } ] } ] } }}