├── CHANGELOG.md ├── LICENSE ├── README.md ├── img ├── .DS_Store ├── code1.png ├── code2.png ├── completion.gif ├── hover.gif └── icon.png ├── language-configuration.json ├── package.json ├── src ├── .DS_Store ├── completion.js ├── extension.js ├── hover.js └── util.js └── syntaxes └── stonescript.tmLanguage.json /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # Changelog 2 | 3 | ## 1.0.16 (2 May 2025) 4 | * `BigNumber.ToInt()`, `BigNumber.ToFloat()` 5 | * `glitch` item type 6 | * `buffs.GetCount()`, `debuffs.GetCount()` 7 | * `foe.buffs.GetCount()`, `foe.debuffs.GetCount()` 8 | * `buffs.GetTime()`, `debuffs.GetTime()` 9 | * `foe.buffs.GetTime()` and `foe.debuffs.GetTime()` 10 | 11 | ## 1.0.15 (10 July 2024) 12 | * `event.GetObjectiveId()`, `event.GetObjectiveProgress()` and `event.GetObjectiveGoal()` 13 | * `encounter.isElite`, `encounter.eliteMod` 14 | * `item.left.gp`, `item.right.gp` 15 | 16 | ## 1.0.14 (4 June 2024) 17 | * undocumented `loc.nextGoalId`, `loc.nextGoalName` and `loc.nextGoalStars` 18 | 19 | ## 1.0.13 (4 April 2024) 20 | * fixed `sys.isPC` constant 21 | * `big_tomb` foe suggestion 22 | * `tower shield` item suggestion 23 | 24 | ## 1.0.12 (7 February 2024) 25 | * added `continue` keyword 26 | 27 | ## 1.0.11 (7 February 2024) 28 | * added `break` keyword (LOL) 29 | 30 | ## 1.0.10 (30 November 2023) 31 | * added `ui.openInv()` and `ui.openMind()` 32 | * added `draw.Player(x, y)` info 33 | 34 | ## 1.0.9 (26 October 2023) 35 | * BigNumber variable type and their function completion 36 | * added `time.msbn` and removed `time.ms` 37 | * fidex `math.pi` coloring 38 | * added `math.e`, `math.Exp()` and `math.Atan()` 39 | * added Known issues in README 40 | * added herobrine 41 | 42 | ## 1.0.8 (14 October 2023) 43 | * added `foe.GetCount()` function 44 | * added `item.GetLoadoutL()` and `item.GetLoadoutR()` functions 45 | * added `sys.os`, `sys.isMobile`, `sys.isPC` and `sys.isConsole` constants 46 | 47 | ## 1.0.7 (12 September 2023) 48 | * item's `state` and `time` completion 49 | 50 | ## 1.0.6 (26 August 2023) 51 | * talismans in `item.GetCooldown()` function 52 | 53 | ## 1.0.5 (25 August 2023) 54 | * `key` namespace 55 | * `buffs.oldest` and `debuffs.oldest` 56 | 57 | ## 1.0.4 (13 August 2023) 58 | * `summon` namespace 59 | * `talisman` item in equip completion 60 | * fixed `sys.fileUrl` and `sys.cacheRemoteFiles` coloring 61 | * fixed `stonescript` namespace coloring 62 | 63 | ## 1.0.3 (3 August 2023) 64 | * equip `gold` weapon coloring and completion 65 | * equip `heavy hammer` weapon completion and coloring 66 | * `sys.` constants and functions completion 67 | * `stonescript.SetMaxExecutionTime()` function completion 68 | * updated `disable hud` info and added `pfarbu` options coloring 69 | * fixed `disable` completion suggestions 70 | 71 | ## 1.0.2 (21 August 2022) 72 | * equip `shiny` weapon coloring and completion 73 | * `item.left` / `item.right` weapon classes (dI dF F...) 74 | * weapon classes fix (some classes were not displayed correctly) 75 | 76 | ## 1.0.1 (30 June 2022) 77 | * `item.left` & `item.right` suggestions 78 | * `arm` instead of `skeleton arm` in weapons suggestions 79 | * `[].` array suggestions 80 | * weapons effect coloring (D, dp, dP, dh, dL, du, dU, df, dF, di, dI, A, ap, aP, ah, aL, au, aU, af, aF, ai, aI) 81 | * `input-filters` coloring only after key... sequence (key = D) 82 | * Link to GitHub Repo in extension page 83 | * Removed tooltips during the creation of a new variable / function name (var ... / func ...) 84 | * More illustrations in the README file 85 | 86 | ## 1.0.0 (10 May 2022) 87 | * Initial release! 88 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2023 Catalyst-42 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Stonescript language support 2 | This is a stonescript language support extension. Created to make it easier to write scripts for the [Stone Story RPG](https://stonestoryrpg.com/stonescript/manual.html) game. 3 | 4 | ## Features 5 | + Syntax highlighting 6 | + Docstrings on hover 7 | + Code completion 8 | + Parameter suggestions 9 | 10 | ## Samples 11 | Theme: [Material Dark](https://marketplace.visualstudio.com/items?itemName=romanrei.material-dark) 12 | Coloring 13 | ![code sample 1](https://raw.githubusercontent.com/Catalyst-42/stonescript/main/img/code1.png) 14 | 15 | Simple script 16 | ![code sample 2](https://raw.githubusercontent.com/Catalyst-42/stonescript/main/img/code2.png) 17 | 18 | Hover 19 | ![hover](https://raw.githubusercontent.com/Catalyst-42/stonescript/main/img/hover.gif) 20 | 21 | Completion 22 | ![completion gif](https://raw.githubusercontent.com/Catalyst-42/stonescript/main/img/completion.gif) 23 | 24 | ## Known issues 25 | + This is not an actual Lexer / Parser, all code checking based on many regex expressions 26 | + Somethimes docstring does not match to actual function (especially for variable with ui / BigNumber data types) 27 | 28 | 29 | -------------------------------------------------------------------------------- /img/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Catalyst-42/stonescript/2878c1e47e03e32ccf84cf87438f571cb3230290/img/.DS_Store -------------------------------------------------------------------------------- /img/code1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Catalyst-42/stonescript/2878c1e47e03e32ccf84cf87438f571cb3230290/img/code1.png -------------------------------------------------------------------------------- /img/code2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Catalyst-42/stonescript/2878c1e47e03e32ccf84cf87438f571cb3230290/img/code2.png -------------------------------------------------------------------------------- /img/completion.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Catalyst-42/stonescript/2878c1e47e03e32ccf84cf87438f571cb3230290/img/completion.gif -------------------------------------------------------------------------------- /img/hover.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Catalyst-42/stonescript/2878c1e47e03e32ccf84cf87438f571cb3230290/img/hover.gif -------------------------------------------------------------------------------- /img/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Catalyst-42/stonescript/2878c1e47e03e32ccf84cf87438f571cb3230290/img/icon.png -------------------------------------------------------------------------------- /language-configuration.json: -------------------------------------------------------------------------------- 1 | { 2 | "comments": { 3 | "lineComment": "//", 4 | "blockComment": ["/*", "*/"] 5 | }, 6 | "brackets": [ 7 | ["{", "}"], 8 | ["[", "]"], 9 | ["(", ")"] 10 | ], 11 | "autoClosingPairs": [ 12 | { "open": "{", "close": "}" }, 13 | { "open": "[", "close": "]" }, 14 | { "open": "(", "close": ")" }, 15 | { "open": "'", "close": "'", "notIn": ["string", "comment"] }, 16 | { "open": "\"", "close": "\"", "notIn": ["string"] }, 17 | ], 18 | "autoCloseBefore": ";:.,=}])>@` \n\t", 19 | "surroundingPairs": [ 20 | ["{", "}"], 21 | ["[", "]"], 22 | ["(", ")"], 23 | ["'", "'"], 24 | ["@", "@"], 25 | ["\"", "\""], 26 | ], 27 | "folding": { 28 | "offSide": true, 29 | "markers": { 30 | "start": "^\\s*//\\s*(#?region\\b)|(/\\*)", 31 | "end": "^\\s*//\\s*(#?endregion\\b)|(\\*/)", 32 | } 33 | }, 34 | "wordPattern": "(-?\\d*\\.\\d\\w*)|([^\\`\\~\\!\\@\\#\\%\\^\\&\\*\\(\\)\\-\\=\\+\\[\\{\\]\\}\\\\\\|\\;\\:\\'\\\"\\,\\.\\<\\>\\/\\?\\s]+)", 35 | "onEnterRules": [ 36 | { 37 | "beforeText": "^ *(?:\\?|:\\?|:|func|for).*$", 38 | "action": { "indent": "indent" } 39 | } 40 | ] 41 | } 42 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "c42-stonescript", 3 | "displayName": "Stonescript", 4 | "description": "Syntax highlighting for Stonescript", 5 | "version": "1.0.16", 6 | "publisher": "Catalyst-42", 7 | "repository": { 8 | "type": "git", 9 | "url": "https://github.com/Catalyst-42/stonescript" 10 | }, 11 | "engines": { 12 | "vscode": "^1.50.0" 13 | }, 14 | "activationEvents": [ 15 | "onLanguage:stonescript" 16 | ], 17 | "icon": "img/icon.png", 18 | "main": "src/extension.js", 19 | "scripts": { 20 | "build": "js-yaml syntaxes/stonescript.tmLanguage.yaml > syntaxes/stonescript.tmLanguage.json" 21 | }, 22 | "categories": [ 23 | "Programming Languages" 24 | ], 25 | "contributes": { 26 | "languages": [ 27 | { 28 | "id": "stonescript", 29 | "aliases": [ 30 | "Stonescript", 31 | "stonescript" 32 | ], 33 | "extensions": [ 34 | ".txt" 35 | ], 36 | "configuration": "./language-configuration.json" 37 | } 38 | ], 39 | "grammars": [ 40 | { 41 | "language": "stonescript", 42 | "scopeName": "source.txt", 43 | "path": "./syntaxes/stonescript.tmLanguage.json" 44 | } 45 | ] 46 | }, 47 | "devDependencies": { 48 | "js-yaml": "^3.14.0" 49 | }, 50 | "__metadata": { 51 | "id": "0a8b8e8d-c23c-456f-9b08-f94824116fcc", 52 | "publisherDisplayName": "Catalyst-42", 53 | "publisherId": "49804593-0790-4ba7-8fb5-5c54fa99e66d", 54 | "isPreReleaseVersion": false 55 | } 56 | } -------------------------------------------------------------------------------- /src/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Catalyst-42/stonescript/2878c1e47e03e32ccf84cf87438f571cb3230290/src/.DS_Store -------------------------------------------------------------------------------- /src/completion.js: -------------------------------------------------------------------------------- 1 | const vscode = require('vscode') 2 | const util = require('./util') 3 | 4 | /** 5 | * @param {*} document 6 | * @param {*} position 7 | * @param {*} token 8 | * @param {*} context 9 | */ 10 | function provideCompletionItems(document, position, token, context) { 11 | const line = document.lineAt(position) 12 | const lineText = line.text.substring(0, position.character) 13 | let str = lineText.substring(lineText.length - 1, lineText.length) 14 | 15 | let dependencies = [] 16 | if (str != '.' && lineText.indexOf('//') == -1 && /(\b\w+\.\w+$|\b\w+\.$)/g.test(lineText) == false) { 17 | dependencies = [ 18 | 'true', 19 | 'false', 20 | 'none', 21 | 'loc', 22 | 'foe', 23 | 'item', 24 | 'harvest', 25 | 'pickup', 26 | 'armor', 27 | 'buffs', 28 | 'debuffs', 29 | 'hp', 30 | 'maxhp', 31 | 'maxarmor', 32 | 'pos', 33 | 'ai', 34 | 'face', 35 | 'key', 36 | 'res', 37 | 'player', 38 | 'totalgp', 39 | 'rng', 40 | 'rngf', 41 | 'input', 42 | 'screen', 43 | 'sys', 44 | 'stonescript', 45 | 'summon', 46 | 'time', 47 | 'totaltime', 48 | 'utc', 49 | 'activate', 50 | 'brew', 51 | 'equip', 52 | 'equipL', 53 | 'equipR', 54 | 'loadout', 55 | 'var', 56 | 'func', 57 | 'return', 58 | 'break', 59 | 'continue', 60 | 'for', 61 | 'import', 62 | 'new', 63 | 'disable', 64 | 'enable', 65 | 'play', 66 | 'ambient', 67 | 'draw', 68 | 'int', 69 | 'math', 70 | 'music', 71 | 'storage', 72 | 'string', 73 | 'te', 74 | 'ui', 75 | 'color', 76 | 'button', 77 | 'encounter', 78 | 'event', 79 | { name: 'Type()', snippet: 'Type($0)', type: vscode.CompletionItemKind.Function }, 80 | { name: 'ascii ... asciiend', snippet: 'ascii $0 asciiend', type: vscode.CompletionItemKind.Keyword }, 81 | // Resources 82 | 'potion', 83 | 'empty', 84 | ] 85 | } 86 | 87 | if (/\bkey *(=|!) *(\w+)?$/g.test(lineText)) { 88 | dependencies = [ 89 | 'left', 90 | 'right', 91 | 'up', 92 | 'down', 93 | 'primary', 94 | 'back', 95 | 'ability1', 96 | 'ability2', 97 | 'bumpL', 98 | 'bumpR', 99 | 'leftBegin', 100 | 'rightBegin', 101 | 'upBegin', 102 | 'downBegin', 103 | 'primaryBegin', 104 | 'backBegin', 105 | 'ability1Begin', 106 | 'ability2Begin', 107 | 'bumpLBegin', 108 | 'bumpRBegin', 109 | 'leftEnd', 110 | 'rightEnd', 111 | 'upEnd', 112 | 'downEnd', 113 | 'primaryEnd', 114 | 'backEnd', 115 | 'ability1End', 116 | 'ability2End', 117 | 'bumpLEnd', 118 | 'bumpREnd', 119 | '←', 120 | '→', 121 | '↑', 122 | '↓', 123 | 'A', 124 | 'D', 125 | 'W', 126 | 'S', 127 | 'LMB', 128 | 'Return', 129 | 'X', 130 | 'Shift', 131 | 'Control', 132 | 'Z', 133 | 'C', 134 | ] 135 | } 136 | 137 | if (/\bfoe *(=|!) *(\w+)?$/g.test(lineText)) { 138 | dependencies = [ 139 | // Enemies 140 | 'target', 141 | 'waypoint', 142 | 'acronian_scout', 143 | 'dysangelos', 144 | 'dysangelos_bearer', 145 | 'dysangelos_elementalist', 146 | 'dysangelos_perfected', 147 | 'scarab', 148 | 'flesh_scarab', 149 | 'mosquito', 150 | 'huge_mosquito', 151 | 'wasp', 152 | 'wasp_nest', 153 | 'tree_boss', 154 | 'poena', 155 | 'tiny_spider', 156 | 'small_spider', 157 | 'spider_eggs', 158 | 'small_bat', 159 | 'medium_bat', 160 | 'scorpion', 161 | 'cool_bat', 162 | 'spider_boss', 163 | 'ant', 164 | 'ant_hill', 165 | 'epic_snail', 166 | 'colossal_snail', 167 | 'fluff', 168 | 'mushroom_boss', 169 | 'mushroom_boss_fat', 170 | 'mushroom_boss_skinny', 171 | 'ghost', 172 | 'large_ghost', 173 | 'small_skeleton', 174 | 'large_skeleton', 175 | 'big_tomb', 176 | 'ghost_tomb', 177 | 'pallas', 178 | 'skeleton_boss', 179 | 'skeleton_boss_stage_2', 180 | 'mine_walker', 181 | 'fire_elemental', 182 | 'flame_geyser', 183 | 'slave_master', 184 | 'big_slave_master', 185 | 'bomb_cart', 186 | 'bronze_guardian', 187 | 'ice_elemental_elite', 188 | 'pillar', 189 | 'ice_pillar', 190 | 'ki_eater', 191 | 'ki_slerper', 192 | 'ki_globbler', 193 | 'elite', 194 | 'ice_elemental_elite', 195 | 'yeti', 196 | 'slying_serpent', 197 | 'ground_serpent', 198 | 'worm_rider', 199 | 'cult_guard', 200 | 'cult_sorcerer', 201 | 'cult_marksman', 202 | 'heavy_hitter', 203 | 'poison_adept', 204 | 'acronian_cultist', 205 | 'nagaraja', 206 | // Search filters 207 | 'arachnid', 208 | 'serpent', 209 | 'insect', 210 | 'machine', 211 | 'humanoid', 212 | 'elemental', 213 | 'boss', 214 | 'phase1', 215 | 'phase2', 216 | 'phase3', 217 | 'spawner', 218 | 'flying', 219 | 'slow', 220 | 'ranged', 221 | 'explode', 222 | 'swarm', 223 | 'unpushable', 224 | 'undamageable', 225 | 'magic_resist', 226 | 'magic_vulnerability', 227 | 'immune_to_stun', 228 | 'immune_to_ranged', 229 | 'immune_to_debuff_damage', 230 | 'immune_to_physical', 231 | ] 232 | } 233 | 234 | if (/\bloc *(=|!) *(\w+)?$/g.test(lineText)) { 235 | dependencies = [ 236 | // Locations 237 | 'Rocky', 238 | 'Deadwood', 239 | 'Caves', 240 | 'Waterfall', 241 | 'Mushroom', 242 | 'Halls', 243 | 'Mine', 244 | 'Ridge', 245 | 'Temple', 246 | 'Shop', 247 | 'Gate', 248 | ] 249 | } 250 | 251 | if (/(\bbuffs\.$|\bbuffs\.\w+$)/g.test(lineText)) { 252 | dependencies = [ 253 | 'count', 254 | 'string', 255 | 'oldest' 256 | ] 257 | } 258 | 259 | if (/(\bdebuffs\.$|\bdebuffs\.\w+$)/g.test(lineText)) { 260 | dependencies = [ 261 | 'count', 262 | 'string', 263 | 'oldest' 264 | ] 265 | } 266 | 267 | if (/buffs.string *(=|!) *(\w+)?$/g.test(lineText)) { 268 | dependencies = [ 269 | // De/Buffs search filters 270 | 'buff_protection', 271 | 'protection', 272 | 'stun', 273 | 'debuff_dot', 274 | 'dot', 275 | 'debuff_dot_2', 276 | 'debuff_damage', 277 | 'damage', 278 | 'debuff_chill', 279 | 'chill', 280 | 'bardiche', 281 | 'smite', 282 | 'berserk', 283 | 'lucky_crit', 284 | 'crit', 285 | 'lucky_mult', 286 | 'multi', 287 | 'strength', 288 | 'invisibility', 289 | 'vampiric', 290 | 'experience', 291 | ] 292 | } 293 | 294 | if (/(\bdraw\.$|\bdraw\.\w+$)/g.test(lineText)) { 295 | dependencies = [ 296 | { name: 'Bg()', snippet: 'Bg($0)', type: vscode.CompletionItemKind.Function }, 297 | { name: 'Box()', snippet: 'Box($0)', type: vscode.CompletionItemKind.Function }, 298 | { name: 'Clear()', snippet: 'Clear()', type: vscode.CompletionItemKind.Function }, 299 | { name: 'GetSymbol()', snippet: 'GetSymbol($0)', type: vscode.CompletionItemKind.Function }, 300 | { name: 'Player()', snippet: 'Player()', type: vscode.CompletionItemKind.Function } 301 | ] 302 | } 303 | 304 | if (/(equip(L|R)?)|(item\.(left|right) *) *(=|!) */g.test(lineText)) { 305 | dependencies = [ 306 | // Weapons 307 | 'poison', 308 | 'vigor', 309 | 'aether', 310 | 'fire', 311 | 'air', 312 | 'ice', 313 | 'sword', 314 | 'long', 315 | 'wand', 316 | 'talisman', 317 | 'shield', 318 | 'dashing shield', 319 | 'bashing shield', 320 | 'compound shield', 321 | 'tower shield', 322 | 'bardiche', 323 | 'crossbow', 324 | 'heavy crossbow', 325 | 'repeating crossbow', 326 | 'hammer', 327 | 'heavy hammer', 328 | 'staff', 329 | 'quarterstaff', 330 | 'socketed staff', 331 | 'arm', 332 | 'blade', 333 | 'mask', 334 | 'mind', 335 | 'stones', 336 | 'hatchet', 337 | 'shovel', 338 | 'grappling', 339 | 'hook', 340 | 'stones', 341 | 'runestone', 342 | 'moon', 343 | 'mind', 344 | 'triskelion', 345 | 'fissure', 346 | 'quest', 347 | 'ouroboros', 348 | 'xp', 349 | 'xi', 350 | 'star', 351 | 'sight', 352 | 'shiny', 353 | 'gold', 354 | 'glitch', 355 | ] 356 | } 357 | 358 | if (/brew +/g.test(lineText)) { 359 | dependencies = [ 360 | 'stone', 361 | 'wood', 362 | 'tar', 363 | 'bronze', 364 | 'ki', 365 | ] 366 | } 367 | 368 | if (/(\bplay )/g.test(lineText)) { 369 | dependencies = [ 370 | 'buy', 371 | 'click', 372 | 'confirm', 373 | 'soul_stone', 374 | 'sword_cast', 375 | 'sword_hit', 376 | 'wand_cast', 377 | 'wand_hit', 378 | 'player_kick', 379 | 'player_punch', 380 | 'stone_throw_cast', 381 | 'stone_throw_hit', 382 | 'grappling_cast', 383 | 'grappling_hit', 384 | 'grappling_idle', 385 | 'hatchet_cast', 386 | 'hatchet_hit', 387 | 'shovel_cast', 388 | 'torch_cast', 389 | 'torch_hit', 390 | 'torch_idle', 391 | 'pickup_stone', 392 | 'pickup_wood', 393 | 'pickup_tar', 394 | 'pickup_success', 395 | 'soul_stone_drop', 396 | 'wand_drop', 397 | 'key_drop', 398 | 'cross_deadwood_bump', 399 | 'cross_deadwood_row', 400 | 'cross_deadwood_splash', 401 | 'ui_starfirst', 402 | 'ui_starnew', 403 | 'ui_starold1', 404 | 'ui_starold2', 405 | 'ui_starold3', 406 | 'ui_starold4', 407 | 'bronze_gate_open', 408 | 'prompt_choice', 409 | 'waterfall_hook_hit', 410 | 'waterfall_splash', 411 | 'haunted_gate_key_bounce_1', 412 | 'haunted_gate_key_bounce_2', 413 | 'haunted_gate_key_bounce_3', 414 | 'haunted_gate_opening', 415 | 'haunted_gate_point_lost', 416 | 'haunted_gate_key_into_gate', 417 | 'haunted_gate_shuffle', 418 | 'haunted_gate_shuffle_fast', 419 | 'haunted_gate_torch_off', 420 | 'haunted_gate_torch_on', 421 | 'haunted_gate_try_to_open', 422 | 'paint_splat', 423 | 'waterfall_land', 424 | 'waterfall_rope_grab', 425 | 'waterfall_rope_swing', 426 | 'skeleton_boss_death', 427 | 'skeleton_boss_legs_die', 428 | 'spider_boss_death', 429 | 'tree_boss_death', 430 | 'mushroom_boss_death', 431 | 'tree_boss_attack', 432 | 'tree_boss_awake', 433 | 'tree_boss_idle', 434 | 'tree_boss_spike', 435 | 'spider_boss_attack', 436 | 'player_hit', 437 | 'mushroom_boss_awake', 438 | 'mushroom_boss_punch', 439 | 'mushroom_boss_shoot', 440 | 'skeleton_boss_arm1', 441 | 'skeleton_boss_arm2', 442 | 'skeleton_boss_attack', 443 | 'skeleton_boss_idle', 444 | 'skeleton_boss_bone_bounce', 445 | 'skeleton_boss_arm_woosh', 446 | 'equip', 447 | 'unequip', 448 | 'bat_attack_small', 449 | 'bat_death_small', 450 | 'bat_wing', 451 | 'bat_wing_small', 452 | 'spider_attack', 453 | 'spider_death', 454 | 'spider_death_small', 455 | 'spider_eggs_spawn', 456 | 'spider_walk', 457 | 'scarab_awake', 458 | 'scarab_bite', 459 | 'scarab_death', 460 | 'scarab_horn', 461 | 'scarab_wings', 462 | 'mosquito_attack', 463 | 'mosquito_death', 464 | 'mosquito_loop', 465 | 'bronze_gate_locked', 466 | 'bat_attack', 467 | 'bat_death', 468 | 'progress_1', 469 | 'progress_2', 470 | 'progress_3', 471 | 'progress_4', 472 | 'progress_5', 473 | 'progress_6', 474 | 'progress_7', 475 | 'progress_8', 476 | 'progress_9', 477 | 'life_gain', 478 | 'player_death', 479 | 'logo_full', 480 | 'logo_short', 481 | 'smithy_hammer', 482 | 'sightstone_cast', 483 | 'error', 484 | 'ranting_tree_halt', 485 | 'treasure_close', 486 | 'treasure_item_pop', 487 | 'treasure_item_show', 488 | 'treasure_open', 489 | 'skeleton_boss_awake', 490 | 'skeleton_boss_hand_slam', 491 | 'level_up', 492 | 'insta_kill', 493 | 'spider_boss_awake', 494 | 'metal_drop', 495 | 'treasure_drop', 496 | 'smithy_hammer_fail', 497 | 'xp_tick', 498 | 'crossbow_cast', 499 | 'crossbow_hit', 500 | 'wand_aether_cast', 501 | 'wand_aether_hit', 502 | 'wand_air_cast', 503 | 'wand_air_hit', 504 | 'wand_fire_cast', 505 | 'wand_fire_hit', 506 | 'wand_ice_cast', 507 | 'wand_ice_hit', 508 | 'wand_poison_cast', 509 | 'wand_poison_hit', 510 | 'wand_vigor_cast', 511 | 'wand_vigor_hit', 512 | 'skeleton_boss_arm_reconnect', 513 | 'skeleton_boss_summon_minions', 514 | 'mushroom_boss_fat_slam', 515 | 'pickup_bronze', 516 | 'temple_npc_chant', 517 | 'temple_npc_clear_throat', 518 | 'temple_npc_talk', 519 | 'first_controller', 520 | 'slave_npc', 521 | 'slave_outro_chatter', 522 | 'slave_outro_voice', 523 | 'haunted_gate_npc_voice', 524 | 'slave_outro_transition', 525 | 'bronze_guardian_attack1', 526 | 'bronze_guardian_attack2', 527 | 'bronze_guardian_attack3', 528 | 'bronze_guardian_death', 529 | 'bronze_guardian_helmet', 530 | 'bronze_guardian_power_up', 531 | 'bronze_guardian_steps', 532 | 'ant_attack', 533 | 'ant_death', 534 | 'ant_walk', 535 | 'snail_attack', 536 | 'snail_attack_small', 537 | 'snail_death', 538 | 'snail_death_small', 539 | 'snail_walk', 540 | 'ghost_death', 541 | 'ghost_death_small', 542 | 'skeletimmy_death', 543 | 'skeletony_death', 544 | 'skeletimmy_attack', 545 | 'skeletony_attack', 546 | 'skeletony_awake_a', 547 | 'skeletony_awake_b', 548 | 'skeletony_walk', 549 | 'ghost_loop', 550 | 'ghost_loop_small', 551 | 'ghost_attack', 552 | 'ghost_attack_small', 553 | 'controller_death', 554 | 'controller_whip_attack', 555 | 'controller_whip_hit', 556 | 'dominotaur_death', 557 | 'dominotaur_whip_attack', 558 | 'dominotaur_whip_hit', 559 | 'mine_walker_death', 560 | 'mine_walker_attack_a', 561 | 'mine_walker_attack_b', 562 | 'mine_walker_attack_hit', 563 | 'mine_walker_awake', 564 | 'mine_walker_step', 565 | 'fire_elemental_attack', 566 | 'fire_elemental_attack_hit', 567 | 'fire_elemental_awake', 568 | 'fire_elemental_death', 569 | 'mine_walker_helmet_break', 570 | 'ice_elemental_attack', 571 | 'ice_elemental_attack_hit', 572 | 'ice_elemental_awake', 573 | 'ice_elemental_death', 574 | 'ki_eater_attack', 575 | 'ki_eater_attack_hit', 576 | 'ki_eater_awake', 577 | 'ki_eater_death', 578 | 'ki_gobbler_attack', 579 | 'ki_gobbler_attack_hit', 580 | 'ki_gobbler_awake', 581 | 'ki_gobbler_death', 582 | 'ki_slerper_attack', 583 | 'ki_slerper_attack_hit', 584 | 'ki_slerper_awake', 585 | 'ki_slerper_death', 586 | 'bell_ringer_attack', 587 | 'bell_ringer_attack_hit', 588 | 'cult_guard_attack', 589 | 'cult_guard_attack_hit', 590 | 'cult_marksman_attack', 591 | 'cult_marksman_attack_hit', 592 | 'cult_sorcerer_attack', 593 | 'cult_sorcerer_attack_hit', 594 | 'cultist_death', 595 | 'flying_serpent_loop', 596 | 'poison_adept_attack', 597 | 'poison_adept_attack_hit', 598 | 'serpent_attack', 599 | 'serpent_death', 600 | 'serpent_handler_release', 601 | 'serpent_hiss', 602 | 'serpent_slither', 603 | 'worm_rider_hop', 604 | 'booklet_open', 605 | 'booklet_turn_page', 606 | 'booklet_close', 607 | 'hammer_cast', 608 | 'hammer_hit', 609 | 'shield_dash', 610 | 'fissure_break_apart', 611 | 'fissure_unmake', 612 | 'mindstone_off', 613 | 'mindstone_on', 614 | 'triskelion_fuse', 615 | 'potion_berserk', 616 | 'potion_cleansing', 617 | 'potion_defensive', 618 | 'potion_experience', 619 | 'potion_healing', 620 | 'potion_invisibility', 621 | 'potion_lightning', 622 | 'potion_lucky', 623 | 'potion_strength', 624 | 'potion_vampiric', 625 | 'bronze_guardian_pulling_hammer', 626 | 'bronze_guardian_removing_hammer', 627 | 'bronze_guardian_turbine', 628 | 'bronze_guardian_ears_ring', 629 | 'bronze_guardian_fuse', 630 | 'bronze_guardian_attack4', 631 | 'yeti_attack', 632 | 'yeti_attack_flick', 633 | 'yeti_attack_hit', 634 | 'yeti_awake_blow', 635 | 'yeti_awake_explosion', 636 | 'yeti_awake_inhale', 637 | 'yeti_awake_lick', 638 | 'yeti_blow', 639 | 'yeti_blow_ice_wall', 640 | 'yeti_death', 641 | 'yeti_inhale', 642 | 'yeti_inhale_lick', 643 | 'nagaraja_awake_roar', 644 | 'nagaraja_awake_swallow', 645 | 'nagaraja_awake_tongue_1', 646 | 'nagaraja_awake_tongue_2', 647 | 'nagaraja_dead', 648 | 'nagaraja_poison_attack', 649 | 'nagaraja_poison_attack_hit', 650 | 'nagaraja_wail', 651 | 'nagaraja_wail_brick', 652 | 'nagaraja_attack_eat', 653 | 'nagaraja_attack_lick', 654 | 'nagaraja_attack_swallow', 655 | 'nagaraja_tongue_damaged', 656 | 'nagaraja_tongue_lift', 657 | 'nagaraja_tongue_smell', 658 | 'nagaraja_tongue_wrap', 659 | 'bearer3_talk', 660 | 'bearer_attack', 661 | 'bearer_attack_hit', 662 | 'bearer_death', 663 | 'bearer_stealing', 664 | 'bearer_super_attack', 665 | 'bearer_scream', 666 | 'bearer4_talk', 667 | 'bearer4_talk_evolving', 668 | 'bearer_evolving', 669 | 'elementalist_aether_attack', 670 | 'elementalist_aether_attack_hit', 671 | 'elementalist_aether_blink', 672 | 'elementalist_death', 673 | 'elementalist_fire_attack', 674 | 'elementalist_fire_attack_hit', 675 | 'elementalist_fire_blink', 676 | 'elementalist_ice_attack', 677 | 'elementalist_ice_attack_hit', 678 | 'elementalist_ice_blink', 679 | 'elementalist_poison_attack', 680 | 'elementalist_poison_attack_hit', 681 | 'elementalist_poison_blink', 682 | 'elementalist_vigor_attack', 683 | 'elementalist_vigor_attack_hit', 684 | 'elementalist_vigor_blink', 685 | 'bearer5_talk', 686 | 'elementalist_evolving', 687 | 'perfected_attack', 688 | 'perfected_attack_hit', 689 | 'perfected_death', 690 | 'perfected_defense', 691 | 'perfected_energy_ball', 692 | 'perfected_energy_ball_hit', 693 | 'perfected_summon', 694 | 'perfected_talk', 695 | 'epilogue_devolving', 696 | 'epliogue_player_evolves', 697 | 'epilogue_talk', 698 | 'devolved_talk', 699 | 'dysangelos_guidance', 700 | 'dysangelos_guidance_1', 701 | 'dysangelos_guidance_2', 702 | 'dysangelos_guidance_3', 703 | 'dysangelos_intro_talk', 704 | 'ranting_tree_talk_halt', 705 | 'ranting_tree_talk_again', 706 | 'ranting_tree_talk_how_dare', 707 | 'ranting_tree_talk_avenge', 708 | 'ranting_tree_talk_get_out', 709 | 'ranting_tree_talk_impressive', 710 | 'ranting_tree_talk_very_well', 711 | 'ranting_tree_talk_extra', 712 | 'hans_talk_intro', 713 | 'hans_talk_reward', 714 | 'scotty_a_pleasure', 715 | 'scotty_a_worthy_opponent', 716 | 'scotty_deuced', 717 | 'scotty_failte_back', 718 | 'scotty_getting_good', 719 | 'scotty_grr', 720 | 'scotty_guess_which', 721 | 'scotty_intro', 722 | 'scotty_lets_harden', 723 | 'scotty_make_ye_guess', 724 | 'scotty_noo_jist', 725 | 'scotty_perhaps_the_rules', 726 | 'scotty_pick_some_treasure', 727 | 'scotty_shall_we_up', 728 | 'scotty_we_have_wee_use', 729 | 'scotty_well_met', 730 | 'scotty_well_then', 731 | 'scotty_wizard', 732 | 'scotty_wrong_choice', 733 | 'scotty_hell_be_back', 734 | 'scotty_out_of_treasure', 735 | 'scotty_there_he_is', 736 | 'nagaraja_choir', 737 | 'mushroom_boss_split', 738 | 'ant_hill', 739 | 'treasure_drop_common', 740 | 'treasure_drop_epic', 741 | 'treasure_drop_giant', 742 | 'treasure_drop_humble', 743 | 'treasure_drop_rare', 744 | 'dominotaur_awake', 745 | 'fire_geyser', 746 | 'ice_pillar', 747 | 'treasure_item_cyan', 748 | 'treasure_item_yellow', 749 | 'treasure_item_green', 750 | 'treasure_item_blue', 751 | 'treasure_item_red', 752 | 'treasure_item_rainbow', 753 | 'ki_slerper_walk', 754 | 'mindstone_found', 755 | 'ghost_tomb_death', 756 | 'perfected_fly_start', 757 | 'perfected_fly_loop', 758 | 'perfected_fly_end', 759 | 'shop_door_open', 760 | 'shop_door_enter', 761 | 'scorpion_death', 762 | 'bomb_cart_explosion', 763 | 'bomb_cart_fuse', 764 | 'bomb_cart_move', 765 | 'bronze_gate_close', 766 | 'poison_powerup', 767 | 'acronian_cultist_power_up', 768 | 'giant_ice_elemental_attack', 769 | 'scout_dialog', 770 | 'morel_punch', 771 | 'falling_stonefolk', 772 | 'scout_arrives', 773 | 'scout_leaves', 774 | 'scout_wing', 775 | 'scout_focus', 776 | 'dog_bark', 777 | 'frog', 778 | 'lost_item_boost', 779 | 'treasure_item_lost', 780 | 'blade_glow', 781 | 'blade_pallas_attack', 782 | 'blade_raise', 783 | 'blade_drag', 784 | 'auggie_voice', 785 | 'pallas_voice', 786 | 'quest_stone_jump', 787 | 'quest_stone_unlock', 788 | 'bardiche_cast', 789 | 'boo_voice', 790 | 'quarterstaff_cast', 791 | 'air_hiss', 792 | 'bang_go_forward', 793 | 'fire_orbs', 794 | 'open_note', 795 | 'talisman_reveal', 796 | 'fire_beast_1', 797 | 'fire_beast_2', 798 | 'uulaa_voice', 799 | 'mask_summon_1' 800 | ] 801 | } 802 | 803 | if (/(\bmusic\.Play\()/g.test(lineText)) { 804 | dependencies = [ 805 | 'bronze_guardian_3', 806 | 'bronze_guardian_4', 807 | 'bronze_guardian_5', 808 | 'bronze_guardian_cyan', 809 | 'bronze_mine_0', 810 | 'bronze_mine_1', 811 | 'bronze_mine_2', 812 | 'bronze_mine_3', 813 | 'bronze_mine_4', 814 | 'bronze_mine_5', 815 | 'bronze_mine_cyan', 816 | 'slave_outro_climb', 817 | 'slave_outro_loop', 818 | 'caustic_caves', 819 | 'spider_boss', 820 | 'cross_deadwood_river', 821 | 'cross_deadwood_wind', 822 | 'deadwood_0', 823 | 'deadwood_1', 824 | 'deadwood_2', 825 | 'deadwood_3', 826 | 'deadwood_4', 827 | 'deadwood_5', 828 | 'deadwood_cyan', 829 | 'tree_boss', 830 | 'waterfall_descent', 831 | 'skeleton_boss', 832 | 'undead_crypt_0', 833 | 'undead_crypt_1', 834 | 'undead_crypt_2', 835 | 'undead_crypt_3', 836 | 'undead_crypt_4', 837 | 'undead_crypt_5', 838 | 'undead_crypt_cyan', 839 | 'undead_crypt_intro', 840 | 'bridge_broken', 841 | 'bridge_crossing', 842 | 'icy_ridge_0', 843 | 'icy_ridge_1', 844 | 'icy_ridge_2', 845 | 'icy_ridge_3', 846 | 'icy_ridge_4', 847 | 'icy_ridge_5', 848 | 'icy_ridge_cyan', 849 | 'yeti', 850 | 'fire_loop', 851 | 'fungus_forest_0', 852 | 'fungus_forest_1', 853 | 'fungus_forest_2', 854 | 'fungus_forest_3', 855 | 'fungus_forest_4', 856 | 'fungus_forest_5', 857 | 'fungus_forest_cyan', 858 | 'mushroom_boss', 859 | 'mushroom_boss_cyan', 860 | 'shop', 861 | 'rocky_plateau_0', 862 | 'rocky_plateau_1', 863 | 'rocky_plateau_2', 864 | 'rocky_plateau_3', 865 | 'rocky_plateau_4', 866 | 'rocky_plateau_5', 867 | 'rocky_plateau_epilogue', 868 | 'rocky_plateau_fight', 869 | 'rocky_plateau_talk', 870 | 'nagaraja', 871 | 'temple_0', 872 | 'temple_1', 873 | 'temple_2', 874 | 'temple_3', 875 | 'temple_4', 876 | 'temple_5', 877 | 'temple_cyan', 878 | 'event_fall', 879 | 'event_hamartia', 880 | 'event_spring', 881 | 'event_stonejam', 882 | 'event_summer', 883 | 'event_winter', 884 | 'credits', 885 | 'main_menu', 886 | 'bone_factory', 887 | 'osteophone', 888 | 'uulaa' 889 | ] 890 | } 891 | 892 | if (/(\bambient\.Add\()/g.test(lineText)) { 893 | dependencies = [ 894 | 'ambient_mines', 895 | 'ambient_caves', 896 | 'ambient_bronze_gate', 897 | 'ambient_deadwood', 898 | 'ambient_mushroom', 899 | 'ambient_bridge', 900 | 'ambient_icy', 901 | 'ambient_cave', 902 | 'ambient_rocky', 903 | 'ambient_temple', 904 | 'ambient_crypt', 905 | 'ambient_haunted_gate', 906 | 'ambient_pallas', 907 | 'waterfall_a', 908 | 'waterfall_b', 909 | 'waterfall_c', 910 | ] 911 | } 912 | 913 | if (/(\bloc\.$|\bloc\.\w+$)/g.test(lineText)) { 914 | dependencies = [ 915 | 'id', 916 | 'name', 917 | 'stars', 918 | 'begin', 919 | 'loop', 920 | 'isQuest', 921 | 'averageTime', 922 | 'bestTime', 923 | 'nextGoalId', 924 | 'nextGoalName', 925 | 'nextGoalStars', 926 | { name: 'Leave()', snippet: 'Leave()', type: vscode.CompletionItemKind.Function }, 927 | { name: 'Pause()', snippet: 'Pause()',type: vscode.CompletionItemKind.Function } 928 | ] 929 | } 930 | 931 | if (/(\bevent\.$|\bevent\.\w+$)/g.test(lineText)) { 932 | dependencies = [ 933 | { name: 'GetObjectiveId()', snippet: 'GetObjectiveId($0)', type: vscode.CompletionItemKind.Function }, 934 | { name: 'GetObjectiveProgress()', snippet: 'GetObjectiveProgress($0)', type: vscode.CompletionItemKind.Function }, 935 | { name: 'GetObjectiveGoal()', snippet: 'GetObjectiveGoal($0)',type: vscode.CompletionItemKind.Function } 936 | ] 937 | } 938 | 939 | if (/(\bencounter\.$|\bencounter\.\w+$)/g.test(lineText)) { 940 | dependencies = [ 941 | 'isElite', 942 | 'eliteMod', 943 | ] 944 | } 945 | 946 | if (/(\bui\.$|\bui\.\w+$)/g.test(lineText)) { 947 | dependencies = [ 948 | 'root', 949 | {name : 'AddAnim()', snippet: 'AddAnim($0)', type: vscode.CompletionItemKind.Function }, 950 | {name : 'AddButton()', snippet: 'AddButton()', type: vscode.CompletionItemKind.Function }, 951 | {name : 'AddPanel()', snippet: 'AddPanel()', type: vscode.CompletionItemKind.Function }, 952 | {name : 'AddStyle()', snippet: 'AddStyle($0)', type: vscode.CompletionItemKind.Function }, 953 | {name : 'AddText()', snippet: 'AddText($0)', type: vscode.CompletionItemKind.Function }, 954 | {name : 'AddCanvas()', snippet: 'AddCanvas()', type: vscode.CompletionItemKind.Function }, 955 | {name : 'Clear()', snippet: 'Clear()', type: vscode.CompletionItemKind.Function }, 956 | {name : 'ShowBanner()', snippet: 'ShowBanner($0)', type: vscode.CompletionItemKind.Function }, 957 | {name : 'OpenInv()', snippet: 'OpenInv()', type: vscode.CompletionItemKind.Function }, 958 | {name : 'OpenMind()', snippet: 'OpenMind()', type: vscode.CompletionItemKind.Function }, 959 | ] 960 | } 961 | 962 | if (/(\bsys\.$|\bsys\.\w+$)/g.test(lineText)) { 963 | dependencies = [ 964 | 'os', 965 | 'isMobile', 966 | 'isPC', 967 | 'isConsole', 968 | 'cacheRemoteFiles', 969 | 'fileUrl', 970 | {name : 'SetFileUrl()', snippet: 'SetFileUrl($0)', type: vscode.CompletionItemKind.Function }, 971 | ] 972 | } 973 | 974 | if (/(\bkey\.$|\bkey\.\w+$)/g.test(lineText)) { 975 | dependencies = [ 976 | {name : 'Bind()', snippet: 'Bind($0)', type: vscode.CompletionItemKind.Function }, 977 | {name : 'GetKeyAct()', snippet: 'GetKeyAct($0)', type: vscode.CompletionItemKind.Function }, 978 | {name : 'GetActKey()', snippet: 'GetActKey($0)', type: vscode.CompletionItemKind.Function }, 979 | {name : 'GetActKey2()', snippet: 'GetActKey2($0)', type: vscode.CompletionItemKind.Function }, 980 | {name : 'GetActLabel()', snippet: 'GetActLabel($0)', type: vscode.CompletionItemKind.Function }, 981 | {name : 'ResetBinds()', snippet: 'ResetBinds()', type: vscode.CompletionItemKind.Function }, 982 | ] 983 | } 984 | 985 | if (/(\bstonescript\.$|\bstonescript\.\w+$)/g.test(lineText)) { 986 | dependencies = [ 987 | {name : 'SetMaxExecutionTime()', snippet: 'SetMaxExecutionTime($0)', type: vscode.CompletionItemKind.Function }, 988 | ] 989 | } 990 | 991 | if (/(\bsummon\.$|\bsummon\.\w+$)/g.test(lineText)) { 992 | dependencies = [ 993 | 'count', 994 | {name : 'GetId()', snippet: 'GetId()', type: vscode.CompletionItemKind.Function }, 995 | {name : 'GetName()', snippet: 'GetName()', type: vscode.CompletionItemKind.Function }, 996 | {name : 'GetVar()', snippet: 'GetVar($0)', type: vscode.CompletionItemKind.Function }, 997 | {name : 'GetState()', snippet: 'GetState()', type: vscode.CompletionItemKind.Function }, 998 | {name : 'GetTime()', snippet: 'GetTime()', type: vscode.CompletionItemKind.Function } 999 | ] 1000 | } 1001 | 1002 | if (/\.(d|a)x/g.test(lineText)) { 1003 | dependencies = [ 1004 | 'center', 1005 | 'left', 1006 | 'right' 1007 | ] 1008 | } 1009 | 1010 | if (/\.(d|a)y/g.test(lineText)) { 1011 | dependencies = [ 1012 | 'center', 1013 | 'top', 1014 | 'bottom' 1015 | ] 1016 | } 1017 | 1018 | if (/\.(anchor|dock) *= */g.test(lineText)) { 1019 | dependencies = [ 1020 | 'top_left', 1021 | 'top_center', 1022 | 'top_right', 1023 | 'center_left', 1024 | 'center_center', 1025 | 'center_right', 1026 | 'bottom_left', 1027 | 'bottom_center', 1028 | 'bottom_right' 1029 | ] 1030 | } 1031 | 1032 | if (/\.visible/g.test(lineText)) { 1033 | dependencies = [ 1034 | 'true', 1035 | 'false', 1036 | 'inherit' 1037 | ] 1038 | } 1039 | 1040 | if (/(\bcolor\.$|\bcolor\.\w+$)/g.test(lineText)) { 1041 | dependencies = [ 1042 | {name : 'FromRGB()', snippet: 'FromRGB(${1:r}, ${2:g}, ${3:b})', type: vscode.CompletionItemKind.Function }, 1043 | {name : 'ToRGB()', snippet: 'ToRGB($0)', type: vscode.CompletionItemKind.Function }, 1044 | {name : 'Lerp()', snippet: 'Lerp(${1:c1}, ${2:c2}, ${3:t})', type: vscode.CompletionItemKind.Function }, 1045 | {name : 'Random()', snippet: 'Random()', type: vscode.CompletionItemKind.Function } 1046 | ] 1047 | } 1048 | 1049 | if (/(\bfoe\.$|\bfoe\.\w+$)/g.test(lineText)) { 1050 | dependencies = [ 1051 | 'name', 1052 | 'distance', 1053 | 'count', 1054 | 'hp', 1055 | 'maxhp', 1056 | 'armor', 1057 | 'maxarmor', 1058 | 'buffs', 1059 | 'debuffs', 1060 | 'state', 1061 | 'time', 1062 | 'level', 1063 | { name: 'GetCount()', snippet: 'GetCount($0)', type: vscode.CompletionItemKind.Function }, 1064 | ] 1065 | } 1066 | 1067 | if (/(\bitem\.$|\bitem\.\w+$)/g.test(lineText)) { 1068 | dependencies = [ 1069 | 'left', 1070 | 'right', 1071 | 'left.id', 1072 | 'right.id', 1073 | 'left.time', 1074 | 'right.time', 1075 | 'left.state', 1076 | 'right.state', 1077 | 'left.gp', 1078 | 'right.gp', 1079 | 'potion', 1080 | { name: 'CanActivate()', snippet: 'CanActivate($0)', type: vscode.CompletionItemKind.Function }, 1081 | { name: 'GetCooldown()', snippet: 'GetCooldown(${1|"aether_talisman","bardiche","bash","blade","cinderwisp","mask","dash","fire_talisman","hatchet","hammer","mind","quarterstaff","skeleton_arm","voidweaver"|})$0', type: vscode.CompletionItemKind.Function }, 1082 | { name: 'GetCount()', snippet: 'GetCount($0)', type: vscode.CompletionItemKind.Function }, 1083 | { name: 'GetLoadoutL()', snippet: 'GetLoadoutL($0)', type: vscode.CompletionItemKind.Function }, 1084 | { name: 'GetLoadoutR()', snippet: 'GetLoadoutR($0)', type: vscode.CompletionItemKind.Function } 1085 | ] 1086 | } 1087 | 1088 | if (/(\bint\.$|\bint\.\w+$)/g.test(lineText)) { 1089 | dependencies = [ 1090 | { name: 'Parse()', snippet: 'Parse($0)', type: vscode.CompletionItemKind.Function}, 1091 | ] 1092 | } 1093 | 1094 | if (/(\bharvest\.$|\bharvest\.\w+$)/g.test(lineText)) { 1095 | dependencies = ['distance'] 1096 | } 1097 | 1098 | if (/(\bpickup\.$|\bpickup\.\w+$)/g.test(lineText)) { 1099 | dependencies = ['distance'] 1100 | } 1101 | 1102 | if (/(\barmor\.$|\barmor\.\w+$)/g.test(lineText)) { 1103 | dependencies = ['f'] 1104 | } 1105 | 1106 | if (/(\bpos\.$|\bpos\.\w+$)/g.test(lineText)) { 1107 | dependencies = ['x', 'y', 'z'] 1108 | } 1109 | 1110 | if (/(\bai\.$|\bai\.\w+$)/g.test(lineText)) { 1111 | dependencies = ['enabled', 'paused', 'idle', 'walking'] 1112 | } 1113 | 1114 | if (/(\bres\.$|\bres\.\w+$)/g.test(lineText)) { 1115 | dependencies = ['stone', 'wood', 'tar', 'ki', 'bronze', 'crystals'] 1116 | } 1117 | 1118 | if (/(\bplayer\.$|\bplayer\.\w+$)/g.test(lineText)) { 1119 | dependencies = ['direction', 'name', { name: 'ShowScaredFace()', snippet: 'ShowScaredFace($0)', type: vscode.CompletionItemKind.Function }] 1120 | } 1121 | 1122 | if (/(\binput\.$|\binput\.\w+$)/g.test(lineText)) { 1123 | dependencies = ['x', 'y'] 1124 | } 1125 | 1126 | if (/(\bscreen\.$|\bscreen\.\w+$)/g.test(lineText)) { 1127 | dependencies = [ 1128 | 'i', 1129 | 'x', 1130 | 'w', 1131 | 'h', 1132 | { name: 'FromWorldX()', snippet: 'FromWorldX($0)', type: vscode.CompletionItemKind.Function }, 1133 | { name: 'FromWorldZ()', snippet: 'FromWorldX($0)', type: vscode.CompletionItemKind.Function }, 1134 | { name: 'ToWorldX()', snippet: 'ToWoldZ($0)', type: vscode.CompletionItemKind.Function }, 1135 | { name: 'ToWorldZ()', snippet: 'ToWorldZ($0)', type: vscode.CompletionItemKind.Function }, 1136 | { name: 'Next()', snippet: 'Next()', type: vscode.CompletionItemKind.Function }, 1137 | { name: 'Previous()', snippet: 'Previous()', type: vscode.CompletionItemKind.Function }, 1138 | { name: 'ResetOffset()', snippet: 'ResetOffset()', type: vscode.CompletionItemKind.Function } 1139 | ] 1140 | } 1141 | 1142 | if (/(\btime\.$|\btime\.\w+$)/g.test(lineText)) { 1143 | dependencies = [ 1144 | 'msbn', 1145 | 'year', 1146 | 'month', 1147 | 'day', 1148 | 'hour', 1149 | 'minute', 1150 | 'second', 1151 | { name: 'FormatCasual()', snippet: 'FormatCasual($0)', type: vscode.CompletionItemKind.Function }, 1152 | { name: 'FormatDigital()', snippet: 'FormatDigital($0)', type: vscode.CompletionItemKind.Function } 1153 | ] 1154 | } 1155 | 1156 | if (/(\butc\.$|\butc\.\w+$)/g.test(lineText)) { 1157 | dependencies = ['year', 'month', 'day', 'hour', 'minute', 'second'] 1158 | } 1159 | 1160 | if (/\b(enable|disable) \w+$/g.test(lineText)) { 1161 | dependencies = ['abilities', 'banner', 'hud', 'loadout input', 'loadout print', 'pause', 'player'] 1162 | } 1163 | 1164 | if (/(\bmath\.$|\bmath\.\w+$)/g.test(lineText)) { 1165 | dependencies = [ 1166 | 'e', 1167 | 'pi', 1168 | { name: 'BigNumber()', snippet: 'BigNumber($0)', type: vscode.CompletionItemKind.Function }, 1169 | { name: 'Exp()', snippet: 'Exp($0)', type: vscode.CompletionItemKind.Function }, 1170 | { name: 'Abs()', snippet: 'Abs($0)', type: vscode.CompletionItemKind.Function }, 1171 | { name: 'Sign()', snippet: 'Sign($0)', type: vscode.CompletionItemKind.Function }, 1172 | { name: 'Min()', snippet: 'Min(${1:num1}, ${2:num2})', type: vscode.CompletionItemKind.Function }, 1173 | { name: 'Max()', snippet: 'Max(${1:num1}, ${2:num2})', type: vscode.CompletionItemKind.Function }, 1174 | { name: 'Clamp()', snippet: 'Clamp(${1:num}, ${2:min}, ${3:max})', type: vscode.CompletionItemKind.Function }, 1175 | { name: 'Round()', snippet: 'Round($0)', type: vscode.CompletionItemKind.Function }, 1176 | { name: 'RoundToInt()', snippet: 'RoundToInt($0)', type: vscode.CompletionItemKind.Function }, 1177 | { name: 'Floor()', snippet: 'Floor($0)', type: vscode.CompletionItemKind.Function }, 1178 | { name: 'FloorToInt()', snippet: 'FloorToInt($0)', type: vscode.CompletionItemKind.Function }, 1179 | { name: 'Ceil()', snippet: 'Ceil($0)', type: vscode.CompletionItemKind.Function }, 1180 | { name: 'CeilToInt()', snippet: 'CeilToInt($0)', type: vscode.CompletionItemKind.Function }, 1181 | { name: 'Lerp()', snippet: 'Lerp(${1:a}, ${2:b}, ${3:t})', type: vscode.CompletionItemKind.Function }, 1182 | { name: 'Log()', snippet: 'Log(${1:num}, ${2:base})', type: vscode.CompletionItemKind.Function }, 1183 | { name: 'Pow()', snippet: 'Pow(${1:num}, ${2:p})', type: vscode.CompletionItemKind.Function }, 1184 | { name: 'Sqrt()', snippet: 'Sqrt($0)', type: vscode.CompletionItemKind.Function }, 1185 | { name: 'ToDeg()', snippet: 'ToDeg($0)', type: vscode.CompletionItemKind.Function }, 1186 | { name: 'ToRad()', snippet: 'ToRad($0)', type: vscode.CompletionItemKind.Function }, 1187 | { name: 'Acos()', snippet: 'Acos($0)', type: vscode.CompletionItemKind.Function }, 1188 | { name: 'Asin()', snippet: 'Asin($0)', type: vscode.CompletionItemKind.Function }, 1189 | { name: 'Atan()', snippet: 'Atan($0)', type: vscode.CompletionItemKind.Function }, 1190 | { name: 'Atan2()', snippet: 'Atan2($0)', type: vscode.CompletionItemKind.Function }, 1191 | { name: 'Cos()', snippet: 'Cos($0)', type: vscode.CompletionItemKind.Function }, 1192 | { name: 'Sin()', snippet: 'Sin($0)', type: vscode.CompletionItemKind.Function }, 1193 | { name: 'Tan()', snippet: 'Tan($0)', type: vscode.CompletionItemKind.Function } 1194 | ] 1195 | } 1196 | 1197 | if (/(\bmusic\.$|\bmusic\.\w+$)/g.test(lineText)) { 1198 | dependencies = [ 1199 | { name: 'Play()', snippet: 'Play($0)', type: vscode.CompletionItemKind.Function }, 1200 | { name: 'Stop()', snippet: 'Stop()', type: vscode.CompletionItemKind.Function } 1201 | ] 1202 | } 1203 | 1204 | if (/(\bambient\.$|\bambient\.\w+$)/g.test(lineText)) { 1205 | dependencies = [ 1206 | { name: 'Add()', snippet: 'Add($0)', type: vscode.CompletionItemKind.Function }, 1207 | { name: 'Stop()', snippet: 'Stop()', type: vscode.CompletionItemKind.Function } 1208 | ] 1209 | } 1210 | 1211 | if (/(\bstorage\.$|\bstorage\.\w+$)/g.test(lineText)) { 1212 | dependencies = [ 1213 | { name: 'Delete()', snippet: 'Delete($0)', type: vscode.CompletionItemKind.Function }, 1214 | { name: 'Get()', snippet: 'Get($0)', type: vscode.CompletionItemKind.Function }, 1215 | { name: 'Has()', snippet: 'Has($0)', type: vscode.CompletionItemKind.Function }, 1216 | { name: 'Keys()', snippet: 'Keys()', type: vscode.CompletionItemKind.Function }, 1217 | { name: 'Incr()', snippet: 'Incr($0)', type: vscode.CompletionItemKind.Function }, 1218 | { name: 'Set()', snippet: 'Set(${1:string}, ${2:value})', type: vscode.CompletionItemKind.Function } 1219 | ] 1220 | } 1221 | 1222 | if (/(\bstring\.$|\bstring\.\w+$)/g.test(lineText)) { 1223 | dependencies = [ 1224 | { name: 'Break()', snippet: 'Break(${1:str}, ${2:int})', type: vscode.CompletionItemKind.Function }, 1225 | { name: 'Capitalize()', snippet: 'Capitalize($0)', type: vscode.CompletionItemKind.Function }, 1226 | { name: 'Equals()', snippet: 'Equals(${1:str1}, ${2:str2})', type: vscode.CompletionItemKind.Function }, 1227 | { name: 'Format()', snippet: 'Format($0)', type: vscode.CompletionItemKind.Function }, 1228 | { name: 'IndexOf()', snippet: 'IndexOf(${1:str}, ${2:criteria})', type: vscode.CompletionItemKind.Function }, 1229 | { name: 'Join()', snippet: 'Join(${1:s}, ${2:arr})', type: vscode.CompletionItemKind.Function }, 1230 | { name: 'Size()', snippet: 'Size($0)', type: vscode.CompletionItemKind.Function }, 1231 | { name: 'Split()', snippet: 'Split($0)', type: vscode.CompletionItemKind.Function }, 1232 | { name: 'Sub()', snippet: 'Sub(${1:str}, ${2:startAt})', type: vscode.CompletionItemKind.Function }, 1233 | { name: 'ToLower()', snippet: 'ToLower($0)', type: vscode.CompletionItemKind.Function }, 1234 | { name: 'ToUpper()', snippet: 'ToUpper($0)', type: vscode.CompletionItemKind.Function } 1235 | ] 1236 | } 1237 | 1238 | if (/(\bte\.$|\bte\.\w+$)/g.test(lineText)) { 1239 | dependencies = [ 1240 | 'language', 1241 | { name: 'xt()', snippet: 'xt($0)', type: vscode.CompletionItemKind.Function }, 1242 | { name: 'GetTID()', snippet: 'GetTID($0)', type: vscode.CompletionItemKind.Function }, 1243 | { name: 'ToEnglish()', snippet: 'ToEnglish($0)', type: vscode.CompletionItemKind.Function } 1244 | ] 1245 | } 1246 | 1247 | if (/(\[.*\]\.$|\[.*\]\.\w+$)/g.test(lineText)) { 1248 | dependencies = [ 1249 | { name: 'Add()', snippet: 'Add($0)', type: vscode.CompletionItemKind.Function }, 1250 | { name: 'Clear()', snippet: 'Clear()', type: vscode.CompletionItemKind.Function }, 1251 | { name: 'Contains()', snippet: 'Contains($0)', type: vscode.CompletionItemKind.Function }, 1252 | { name: 'Count()', snippet: 'Count()', type: vscode.CompletionItemKind.Function }, 1253 | { name: 'Emplace()', snippet: 'Emplace($0)', type: vscode.CompletionItemKind.Function }, 1254 | { name: 'IndexOf()', snippet: 'IndexOf($0)', type: vscode.CompletionItemKind.Function }, 1255 | { name: 'Insert()', snippet: 'Insert($0)', type: vscode.CompletionItemKind.Function }, 1256 | { name: 'RemoveAt()', snippet: 'RemoveAt($0)', type: vscode.CompletionItemKind.Function }, 1257 | { name: 'Sort()', snippet: 'Sort()', type: vscode.CompletionItemKind.Function } 1258 | ] 1259 | } 1260 | 1261 | if (/\b(var|func)\b *(\w+)?$/g.test(lineText)) { 1262 | dependencies = [''] 1263 | } 1264 | 1265 | var clear_document 1266 | clear_document = document.getText().replace(/^ *\/\*(.|\n)*?\*\/|\/\/.+$/gm, '') 1267 | 1268 | // functions completion 1269 | functions = clear_document.match(/^ *func .+(?=\(|$)/gm) 1270 | if (functions != null && /\b(func)\b *(\w+)?$/g.test(lineText) == false) { 1271 | functions.map(i => { 1272 | func_name = i.split('func ')[1].replace(/\s/g, '') 1273 | func_content = func_name.split('(')[1] 1274 | func_name = func_name.split('(')[0] 1275 | 1276 | if (/(\w+\.\w+$|\w+\.$|\.\.$)/g.test(lineText) == false) { 1277 | if (func_content.indexOf(')') == 0) { 1278 | dependencies.push({ name: func_name + '()', snippet: func_name + '()', type: vscode.CompletionItemKind.Function }) 1279 | } else { 1280 | dependencies.push({ name: func_name + '()', snippet: func_name + '($0)', type: vscode.CompletionItemKind.Function }) 1281 | } 1282 | } 1283 | }) 1284 | } 1285 | 1286 | // variables completion and ui.Add... elements 1287 | variables = clear_document.match(/^ *var .+$/gm) 1288 | var re 1289 | if (variables != null && /\b(var)\b *(\w+)?$/g.test(lineText) == false) { 1290 | variables.map(i => { 1291 | var_name = i.split('var ')[1].replace(/\s/g, '') 1292 | var_content = var_name.split('=')[1] 1293 | var_name = var_name.split('=')[0] 1294 | 1295 | if (var_content == undefined) { 1296 | re = new RegExp('^ *' + var_name + ' *= *.*$', 'gm') 1297 | var_content = document.getText().match(re) 1298 | var_content = var_content[var_content.length-1].split('=')[1] 1299 | var_content = var_content.replace(/\s/g, '') 1300 | } 1301 | 1302 | re = new RegExp('(\\b' + var_name + '\\.$)|(\\b' + var_name + '\\.\\w+$)', 'g') 1303 | if (re.test(lineText)) { 1304 | if (var_content.indexOf('ui.Add') == 0) { 1305 | dependencies.push( 1306 | 'x', 1307 | 'y', 1308 | 'w', 1309 | 'h', 1310 | 'absoluteX', 1311 | 'absoluteY', 1312 | 'anchor', 1313 | 'dock', 1314 | 'ax', 1315 | 'ay', 1316 | 'dx', 1317 | 'dy', 1318 | 'parent', 1319 | 'visible', 1320 | { name: 'Recycle()', snippet: 'Recycle()', type: vscode.CompletionItemKind.Function } 1321 | ) 1322 | } 1323 | 1324 | if (var_content.indexOf('ui.AddPanel()') == 0) { 1325 | dependencies.push( 1326 | 'children', 1327 | 'clip', 1328 | 'color', 1329 | 'style', 1330 | { name: 'Add()', snippet: 'Add($0)', type: vscode.CompletionItemKind.Function }, 1331 | { name: 'Clear()', snippet: 'Clear()', type: vscode.CompletionItemKind.Function }, 1332 | { name: 'Remove()', snippet: 'Remove($0)', type: vscode.CompletionItemKind.Function } 1333 | ) 1334 | } 1335 | 1336 | if (var_content.indexOf('ui.AddText(') == 0) { 1337 | dependencies.push( 1338 | 'align', 1339 | 'color', 1340 | 'lines', 1341 | 'text' 1342 | ) 1343 | } 1344 | 1345 | if (var_content.indexOf('ui.AddButton()') == 0) { 1346 | dependencies.push( 1347 | 'text', 1348 | 'tcolor', 1349 | 'bcolor', 1350 | 'hcolor', 1351 | 'sound', 1352 | 'style', 1353 | { name: 'SetPressed()', snippet: 'SetPressed($0)', type: vscode.CompletionItemKind.Function }, 1354 | { name: 'SetDown()', snippet: 'SetDown($0)', type: vscode.CompletionItemKind.Function }, 1355 | { name: 'SetUp()', snippet: 'SetUp($0)', type: vscode.CompletionItemKind.Function } 1356 | ) 1357 | } 1358 | 1359 | if (var_content.indexOf('ui.AddAnim(') == 0) { 1360 | dependencies.push( 1361 | 'color', 1362 | 'duration', 1363 | 'flipX', 1364 | 'flipY', 1365 | 'frame', 1366 | 'gamePause', 1367 | 'loop', 1368 | 'playing', 1369 | 'paused', 1370 | 'pivotX', 1371 | 'pivotY', 1372 | 'playOnStart', 1373 | { name: 'Load()', snippet: 'Load($0)', type: vscode.CompletionItemKind.Function }, 1374 | { name: 'Pause()', snippet: 'Pause()', type: vscode.CompletionItemKind.Function }, 1375 | { name: 'Play()', snippet: 'Play()', type: vscode.CompletionItemKind.Function }, 1376 | { name: 'Stop()', snippet: 'Stop()', type: vscode.CompletionItemKind.Function } 1377 | ) 1378 | } 1379 | 1380 | if (var_content.indexOf('ui.AddCanvas(') == 0) { 1381 | dependencies.push( 1382 | 'blend', 1383 | { name: 'Get()', snippet: 'Get($0)', type: vscode.CompletionItemKind.Function }, 1384 | { name: 'Set()', snippet: 'Set($0)', type: vscode.CompletionItemKind.Function }, 1385 | { name: 'SetFG()', snippet: 'SetFG($0)', type: vscode.CompletionItemKind.Function }, 1386 | { name: 'SetBG()', snippet: 'SetBG($0)', type: vscode.CompletionItemKind.Function } 1387 | ) 1388 | } 1389 | 1390 | if (var_content.indexOf('math.BigNumber(') == 0) { 1391 | dependencies.push( 1392 | { name: 'Add()', snippet: 'Add($0)', type: vscode.CompletionItemKind.Function }, 1393 | { name: 'Sub()', snippet: 'Sub($0)', type: vscode.CompletionItemKind.Function }, 1394 | { name: 'Mul()', snippet: 'Mul($0)', type: vscode.CompletionItemKind.Function }, 1395 | { name: 'Div()', snippet: 'Div($0)', type: vscode.CompletionItemKind.Function }, 1396 | { name: 'Eq()', snippet: 'Eq($0)', type: vscode.CompletionItemKind.Function }, 1397 | { name: 'Gt()', snippet: 'Gt($0)', type: vscode.CompletionItemKind.Function }, 1398 | { name: 'Ge()', snippet: 'Ge($0)', type: vscode.CompletionItemKind.Function }, 1399 | { name: 'Lt()', snippet: 'Lt($0)', type: vscode.CompletionItemKind.Function }, 1400 | { name: 'Le()', snippet: 'Le($0)', type: vscode.CompletionItemKind.Function }, 1401 | { name: 'ToString()', snippet: 'ToString($0)', type: vscode.CompletionItemKind.Function }, 1402 | { name: 'ToInt()', snippet: 'ToInt($0)', type: vscode.CompletionItemKind.Function }, 1403 | { name: 'ToFloat()', snippet: 'ToFloat($0)', type: vscode.CompletionItemKind.Function }, 1404 | { name: 'ToUI()', snippet: 'ToUI($0)', type: vscode.CompletionItemKind.Function }, 1405 | ) 1406 | } 1407 | 1408 | if (var_content.indexOf('[') == 0 || var_content.indexOf('string.Split(') == 0) { 1409 | dependencies.push( 1410 | { name: 'Add()', snippet: 'Add($0)', type: vscode.CompletionItemKind.Function }, 1411 | { name: 'Clear()', snippet: 'Clear()', type: vscode.CompletionItemKind.Function }, 1412 | { name: 'Contains()', snippet: 'Contains($0)', type: vscode.CompletionItemKind.Function }, 1413 | { name: 'Count()', snippet: 'Count()', type: vscode.CompletionItemKind.Function }, 1414 | { name: 'Emplace()', snippet: 'Emplace($0)', type: vscode.CompletionItemKind.Function }, 1415 | { name: 'IndexOf()', snippet: 'IndexOf($0)', type: vscode.CompletionItemKind.Function }, 1416 | { name: 'Insert()', snippet: 'Insert($0)', type: vscode.CompletionItemKind.Function }, 1417 | { name: 'RemoveAt()', snippet: 'RemoveAt($0)', type: vscode.CompletionItemKind.Function }, 1418 | { name: 'Sort()', snippet: 'Sort()', type: vscode.CompletionItemKind.Function } 1419 | ) 1420 | } 1421 | } 1422 | 1423 | if (/(\w+\.\w+$|\w+\.$|\.\.$)/g.test(lineText) == false) { 1424 | dependencies.push({ name: var_name, snippet: var_name, type: vscode.CompletionItemKind.Variable } 1425 | ) 1426 | } 1427 | }) 1428 | } 1429 | 1430 | if (dependencies == []) { return null } 1431 | return dependencies.map(dep => { 1432 | if (typeof dep == 'object') { 1433 | const item = new vscode.CompletionItem(dep.name, dep.type) 1434 | item.insertText = new vscode.SnippetString(dep.snippet) 1435 | return item 1436 | } else { 1437 | return new vscode.CompletionItem(dep, vscode.CompletionItemKind.Field) 1438 | } 1439 | }) 1440 | } 1441 | 1442 | /** 1443 | * @param {*} item 1444 | * @param {*} token 1445 | */ 1446 | function resolveCompletionItem(item, token) { 1447 | return null 1448 | } 1449 | 1450 | module.exports = function (context) { 1451 | context.subscriptions.push( 1452 | vscode.languages.registerCompletionItemProvider( 1453 | 'stonescript', 1454 | { 1455 | provideCompletionItems, 1456 | resolveCompletionItem 1457 | }, 1458 | '.' 1459 | ) 1460 | ) 1461 | } -------------------------------------------------------------------------------- /src/extension.js: -------------------------------------------------------------------------------- 1 | const vscode = require('vscode') 2 | 3 | /** 4 | * @param {*} context 5 | */ 6 | exports.activate = function (context) { 7 | console.log(vscode) 8 | require('./completion')(context) 9 | require('./hover')(context) 10 | } 11 | 12 | exports.deactivate = function () { 13 | console.log('deactivate') 14 | } 15 | -------------------------------------------------------------------------------- /src/hover.js: -------------------------------------------------------------------------------- 1 | const vscode = require('vscode') 2 | const path = require('path') 3 | const fs = require('fs') 4 | 5 | /** 6 | * @param {*} document 7 | * @param {*} position 8 | * @param {*} token 9 | */ 10 | function provideHover(document, position, token) { 11 | const fileName = document.fileName 12 | const workDir = path.dirname(fileName) 13 | const wordposition = document.getWordRangeAtPosition(position) 14 | const word = document.getText(wordposition) 15 | const line = document.lineAt(position) 16 | 17 | if (/^ *(\/\/|\/\*)/g.test(line.text)) { return } 18 | 19 | let list = [ 20 | // #region Disables 21 | { id: 'disable abilities', name: 'Prevents activation of potion and weapon abilities. Also greys out the HUD buttons' }, 22 | { id: 'enable abilities', name: 'Restores activation of abilities that were disabled by a previous call to "disable abilities"' }, 23 | { id: 'disable banner', name: 'Prevents rendering of the horizontal banner that appears with the location name at the beginning and end of a location' }, 24 | { id: 'enable banner', name: 'Restores rendering of the horizontal banner with location name' }, 25 | { id: 'disable hud', name: 'Hides and disables the gameplay user interface elements. Accepts optional parameters, specifying the set of elements to disable:\n* p = player health and debuffs\n* f = foe health and debuffs\n* a = ability buttons\n* r = resources\n* b = banner\n* u = utility belt' }, 26 | { id: 'enable hud', name: 'Brings back all the user interface elements hidden by a previous "disable hud" command. Accepts optional parameters, specifying the set of elements to enable:\n* p = player health and debuffs\n* f = foe health and debuffs\n* a = ability buttons\n* r = resources\n* b = banner\n* u = utility belt' }, 27 | { id: 'disable loadout', name: ''}, 28 | { id: 'enable loadout', name: ''}, 29 | { id: 'loadout input', name: 'Prevents / restores weapon loadouts from being saved or recalled with input keys'}, 30 | { id: 'loadout print', name: 'Hides / brings back the messages that appear when a loadout is recalled'}, 31 | { id: 'disable pause', name: 'Hides the pause button user interface. Pause is still available with the [P] shortcut' }, 32 | { id: 'enable pause', name: 'Brings back the pause button hidden by a previous "disable pause" command' }, 33 | { id: 'disable player', name: 'Hides the player. Has no effect on combat, this is only cosmetic' }, 34 | { id: 'enable player', name: 'Brings back the player rendering if it was hidden by a previous "disable player" command' }, 35 | // #endregion 36 | // #region Sound effects 37 | { id: 'play buy', name: 'Sound effect' }, 38 | { id: 'play click', name: 'Sound effect' }, 39 | { id: 'play confirm', name: 'Sound effect' }, 40 | { id: 'play soul_stone', name: 'Sound effect' }, 41 | { id: 'play sword_cast', name: 'Sound effect' }, 42 | { id: 'play sword_hit', name: 'Sound effect' }, 43 | { id: 'play wand_cast', name: 'Sound effect' }, 44 | { id: 'play wand_hit', name: 'Sound effect' }, 45 | { id: 'play player_kick', name: 'Sound effect' }, 46 | { id: 'play player_punch', name: 'Sound effect' }, 47 | { id: 'play stone_throw_cast', name: 'Sound effect' }, 48 | { id: 'play stone_throw_hit', name: 'Sound effect' }, 49 | { id: 'play grappling_cast', name: 'Sound effect' }, 50 | { id: 'play grappling_hit', name: 'Sound effect' }, 51 | { id: 'play grappling_idle', name: 'Sound effect' }, 52 | { id: 'play hatchet_cast', name: 'Sound effect' }, 53 | { id: 'play hatchet_hit', name: 'Sound effect' }, 54 | { id: 'play shovel_cast', name: 'Sound effect' }, 55 | { id: 'play torch_cast', name: 'Sound effect' }, 56 | { id: 'play torch_hit', name: 'Sound effect' }, 57 | { id: 'play torch_idle', name: 'Sound effect' }, 58 | { id: 'play pickup_stone', name: 'Sound effect' }, 59 | { id: 'play pickup_wood', name: 'Sound effect' }, 60 | { id: 'play pickup_tar', name: 'Sound effect' }, 61 | { id: 'play pickup_success', name: 'Sound effect' }, 62 | { id: 'play soul_stone_drop', name: 'Sound effect' }, 63 | { id: 'play wand_drop', name: 'Sound effect' }, 64 | { id: 'play key_drop', name: 'Sound effect' }, 65 | { id: 'play cross_deadwood_bump', name: 'Sound effect' }, 66 | { id: 'play cross_deadwood_row', name: 'Sound effect' }, 67 | { id: 'play cross_deadwood_splash', name: 'Sound effect' }, 68 | { id: 'play ui_starfirst', name: 'Sound effect' }, 69 | { id: 'play ui_starnew', name: 'Sound effect' }, 70 | { id: 'play ui_starold1', name: 'Sound effect' }, 71 | { id: 'play ui_starold2', name: 'Sound effect' }, 72 | { id: 'play ui_starold3', name: 'Sound effect' }, 73 | { id: 'play ui_starold4', name: 'Sound effect' }, 74 | { id: 'play bronze_gate_open', name: 'Sound effect' }, 75 | { id: 'play prompt_choice', name: 'Sound effect' }, 76 | { id: 'play waterfall_hook_hit', name: 'Sound effect' }, 77 | { id: 'play waterfall_splash', name: 'Sound effect' }, 78 | { id: 'play haunted_gate_key_bounce_1', name: 'Sound effect' }, 79 | { id: 'play haunted_gate_key_bounce_2', name: 'Sound effect' }, 80 | { id: 'play haunted_gate_key_bounce_3', name: 'Sound effect' }, 81 | { id: 'play haunted_gate_opening', name: 'Sound effect' }, 82 | { id: 'play haunted_gate_point_lost', name: 'Sound effect' }, 83 | { id: 'play haunted_gate_key_into_gate', name: 'Sound effect' }, 84 | { id: 'play haunted_gate_shuffle', name: 'Sound effect' }, 85 | { id: 'play haunted_gate_shuffle_fast', name: 'Sound effect' }, 86 | { id: 'play haunted_gate_torch_off', name: 'Sound effect' }, 87 | { id: 'play haunted_gate_torch_on', name: 'Sound effect' }, 88 | { id: 'play haunted_gate_try_to_open', name: 'Sound effect' }, 89 | { id: 'play paint_splat', name: 'Sound effect' }, 90 | { id: 'play waterfall_land', name: 'Sound effect' }, 91 | { id: 'play waterfall_rope_grab', name: 'Sound effect' }, 92 | { id: 'play waterfall_rope_swing', name: 'Sound effect' }, 93 | { id: 'play skeleton_boss_death', name: 'Sound effect' }, 94 | { id: 'play skeleton_boss_legs_die', name: 'Sound effect' }, 95 | { id: 'play spider_boss_death', name: 'Sound effect' }, 96 | { id: 'play tree_boss_death', name: 'Sound effect' }, 97 | { id: 'play mushroom_boss_death', name: 'Sound effect' }, 98 | { id: 'play tree_boss_attack', name: 'Sound effect' }, 99 | { id: 'play tree_boss_awake', name: 'Sound effect' }, 100 | { id: 'play tree_boss_idle', name: 'Sound effect' }, 101 | { id: 'play tree_boss_spike', name: 'Sound effect' }, 102 | { id: 'play spider_boss_attack', name: 'Sound effect' }, 103 | { id: 'play player_hit', name: 'Sound effect' }, 104 | { id: 'play mushroom_boss_awake', name: 'Sound effect' }, 105 | { id: 'play mushroom_boss_punch', name: 'Sound effect' }, 106 | { id: 'play mushroom_boss_shoot', name: 'Sound effect' }, 107 | { id: 'play skeleton_boss_arm1', name: 'Sound effect' }, 108 | { id: 'play skeleton_boss_arm2', name: 'Sound effect' }, 109 | { id: 'play skeleton_boss_attack', name: 'Sound effect' }, 110 | { id: 'play skeleton_boss_idle', name: 'Sound effect' }, 111 | { id: 'play skeleton_boss_bone_bounce', name: 'Sound effect' }, 112 | { id: 'play skeleton_boss_arm_woosh', name: 'Sound effect' }, 113 | { id: 'play equip', name: 'Sound effect' }, 114 | { id: 'play unequip', name: 'Sound effect' }, 115 | { id: 'play bat_attack_small', name: 'Sound effect' }, 116 | { id: 'play bat_death_small', name: 'Sound effect' }, 117 | { id: 'play bat_wing', name: 'Sound effect' }, 118 | { id: 'play bat_wing_small', name: 'Sound effect' }, 119 | { id: 'play spider_attack', name: 'Sound effect' }, 120 | { id: 'play spider_death', name: 'Sound effect' }, 121 | { id: 'play spider_death_small', name: 'Sound effect' }, 122 | { id: 'play spider_eggs_spawn', name: 'Sound effect' }, 123 | { id: 'play spider_walk', name: 'Sound effect' }, 124 | { id: 'play scarab_awake', name: 'Sound effect' }, 125 | { id: 'play scarab_bite', name: 'Sound effect' }, 126 | { id: 'play scarab_death', name: 'Sound effect' }, 127 | { id: 'play scarab_horn', name: 'Sound effect' }, 128 | { id: 'play scarab_wings', name: 'Sound effect' }, 129 | { id: 'play mosquito_attack', name: 'Sound effect' }, 130 | { id: 'play mosquito_death', name: 'Sound effect' }, 131 | { id: 'play mosquito_loop', name: 'Sound effect' }, 132 | { id: 'play bronze_gate_locked', name: 'Sound effect' }, 133 | { id: 'play bat_attack', name: 'Sound effect' }, 134 | { id: 'play bat_death', name: 'Sound effect' }, 135 | { id: 'play progress_1', name: 'Sound effect' }, 136 | { id: 'play progress_2', name: 'Sound effect' }, 137 | { id: 'play progress_3', name: 'Sound effect' }, 138 | { id: 'play progress_4', name: 'Sound effect' }, 139 | { id: 'play progress_5', name: 'Sound effect' }, 140 | { id: 'play progress_6', name: 'Sound effect' }, 141 | { id: 'play progress_7', name: 'Sound effect' }, 142 | { id: 'play progress_8', name: 'Sound effect' }, 143 | { id: 'play progress_9', name: 'Sound effect' }, 144 | { id: 'play life_gain', name: 'Sound effect' }, 145 | { id: 'play player_death', name: 'Sound effect' }, 146 | { id: 'play logo_full', name: 'Sound effect' }, 147 | { id: 'play logo_short', name: 'Sound effect' }, 148 | { id: 'play smithy_hammer', name: 'Sound effect' }, 149 | { id: 'play sightstone_cast', name: 'Sound effect' }, 150 | { id: 'play error', name: 'Sound effect' }, 151 | { id: 'play ranting_tree_halt', name: 'Sound effect' }, 152 | { id: 'play treasure_close', name: 'Sound effect' }, 153 | { id: 'play treasure_item_pop', name: 'Sound effect' }, 154 | { id: 'play treasure_item_show', name: 'Sound effect' }, 155 | { id: 'play treasure_open', name: 'Sound effect' }, 156 | { id: 'play skeleton_boss_awake', name: 'Sound effect' }, 157 | { id: 'play skeleton_boss_hand_slam', name: 'Sound effect' }, 158 | { id: 'play level_up', name: 'Sound effect' }, 159 | { id: 'play insta_kill', name: 'Sound effect' }, 160 | { id: 'play spider_boss_awake', name: 'Sound effect' }, 161 | { id: 'play metal_drop', name: 'Sound effect' }, 162 | { id: 'play treasure_drop', name: 'Sound effect' }, 163 | { id: 'play smithy_hammer_fail', name: 'Sound effect' }, 164 | { id: 'play xp_tick', name: 'Sound effect' }, 165 | { id: 'play crossbow_cast', name: 'Sound effect' }, 166 | { id: 'play crossbow_hit', name: 'Sound effect' }, 167 | { id: 'play wand_aether_cast', name: 'Sound effect' }, 168 | { id: 'play wand_aether_hit', name: 'Sound effect' }, 169 | { id: 'play wand_air_cast', name: 'Sound effect' }, 170 | { id: 'play wand_air_hit', name: 'Sound effect' }, 171 | { id: 'play wand_fire_cast', name: 'Sound effect' }, 172 | { id: 'play wand_fire_hit', name: 'Sound effect' }, 173 | { id: 'play wand_ice_cast', name: 'Sound effect' }, 174 | { id: 'play wand_ice_hit', name: 'Sound effect' }, 175 | { id: 'play wand_poison_cast', name: 'Sound effect' }, 176 | { id: 'play wand_poison_hit', name: 'Sound effect' }, 177 | { id: 'play wand_vigor_cast', name: 'Sound effect' }, 178 | { id: 'play wand_vigor_hit', name: 'Sound effect' }, 179 | { id: 'play skeleton_boss_arm_reconnect', name: 'Sound effect' }, 180 | { id: 'play skeleton_boss_summon_minions', name: 'Sound effect' }, 181 | { id: 'play mushroom_boss_fat_slam', name: 'Sound effect' }, 182 | { id: 'play pickup_bronze', name: 'Sound effect' }, 183 | { id: 'play temple_npc_chant', name: 'Sound effect' }, 184 | { id: 'play temple_npc_clear_throat', name: 'Sound effect' }, 185 | { id: 'play temple_npc_talk', name: 'Sound effect' }, 186 | { id: 'play first_controller', name: 'Sound effect' }, 187 | { id: 'play slave_npc', name: 'Sound effect' }, 188 | { id: 'play slave_outro_chatter', name: 'Sound effect' }, 189 | { id: 'play slave_outro_voice', name: 'Sound effect' }, 190 | { id: 'play haunted_gate_npc_voice', name: 'Sound effect' }, 191 | { id: 'play slave_outro_transition', name: 'Sound effect' }, 192 | { id: 'play bronze_guardian_attack1', name: 'Sound effect' }, 193 | { id: 'play bronze_guardian_attack2', name: 'Sound effect' }, 194 | { id: 'play bronze_guardian_attack3', name: 'Sound effect' }, 195 | { id: 'play bronze_guardian_death', name: 'Sound effect' }, 196 | { id: 'play bronze_guardian_helmet', name: 'Sound effect' }, 197 | { id: 'play bronze_guardian_power_up', name: 'Sound effect' }, 198 | { id: 'play bronze_guardian_steps', name: 'Sound effect' }, 199 | { id: 'play ant_attack', name: 'Sound effect' }, 200 | { id: 'play ant_death', name: 'Sound effect' }, 201 | { id: 'play ant_walk', name: 'Sound effect' }, 202 | { id: 'play snail_attack', name: 'Sound effect' }, 203 | { id: 'play snail_attack_small', name: 'Sound effect' }, 204 | { id: 'play snail_death', name: 'Sound effect' }, 205 | { id: 'play snail_death_small', name: 'Sound effect' }, 206 | { id: 'play snail_walk', name: 'Sound effect' }, 207 | { id: 'play ghost_death', name: 'Sound effect' }, 208 | { id: 'play ghost_death_small', name: 'Sound effect' }, 209 | { id: 'play skeletimmy_death', name: 'Sound effect' }, 210 | { id: 'play skeletony_death', name: 'Sound effect' }, 211 | { id: 'play skeletimmy_attack', name: 'Sound effect' }, 212 | { id: 'play skeletony_attack', name: 'Sound effect' }, 213 | { id: 'play skeletony_awake_a', name: 'Sound effect' }, 214 | { id: 'play skeletony_awake_b', name: 'Sound effect' }, 215 | { id: 'play skeletony_walk', name: 'Sound effect' }, 216 | { id: 'play ghost_loop', name: 'Sound effect' }, 217 | { id: 'play ghost_loop_small', name: 'Sound effect' }, 218 | { id: 'play ghost_attack', name: 'Sound effect' }, 219 | { id: 'play ghost_attack_small', name: 'Sound effect' }, 220 | { id: 'play controller_death', name: 'Sound effect' }, 221 | { id: 'play controller_whip_attack', name: 'Sound effect' }, 222 | { id: 'play controller_whip_hit', name: 'Sound effect' }, 223 | { id: 'play dominotaur_death', name: 'Sound effect' }, 224 | { id: 'play dominotaur_whip_attack', name: 'Sound effect' }, 225 | { id: 'play dominotaur_whip_hit', name: 'Sound effect' }, 226 | { id: 'play mine_walker_death', name: 'Sound effect' }, 227 | { id: 'play mine_walker_attack_a', name: 'Sound effect' }, 228 | { id: 'play mine_walker_attack_b', name: 'Sound effect' }, 229 | { id: 'play mine_walker_attack_hit', name: 'Sound effect' }, 230 | { id: 'play mine_walker_awake', name: 'Sound effect' }, 231 | { id: 'play mine_walker_step', name: 'Sound effect' }, 232 | { id: 'play fire_elemental_attack', name: 'Sound effect' }, 233 | { id: 'play fire_elemental_attack_hit', name: 'Sound effect' }, 234 | { id: 'play fire_elemental_awake', name: 'Sound effect' }, 235 | { id: 'play fire_elemental_death', name: 'Sound effect' }, 236 | { id: 'play mine_walker_helmet_break', name: 'Sound effect' }, 237 | { id: 'play ice_elemental_attack', name: 'Sound effect' }, 238 | { id: 'play ice_elemental_attack_hit', name: 'Sound effect' }, 239 | { id: 'play ice_elemental_awake', name: 'Sound effect' }, 240 | { id: 'play ice_elemental_death', name: 'Sound effect' }, 241 | { id: 'play ki_eater_attack', name: 'Sound effect' }, 242 | { id: 'play ki_eater_attack_hit', name: 'Sound effect' }, 243 | { id: 'play ki_eater_awake', name: 'Sound effect' }, 244 | { id: 'play ki_eater_death', name: 'Sound effect' }, 245 | { id: 'play ki_gobbler_attack', name: 'Sound effect' }, 246 | { id: 'play ki_gobbler_attack_hit', name: 'Sound effect' }, 247 | { id: 'play ki_gobbler_awake', name: 'Sound effect' }, 248 | { id: 'play ki_gobbler_death', name: 'Sound effect' }, 249 | { id: 'play ki_slerper_attack', name: 'Sound effect' }, 250 | { id: 'play ki_slerper_attack_hit', name: 'Sound effect' }, 251 | { id: 'play ki_slerper_awake', name: 'Sound effect' }, 252 | { id: 'play ki_slerper_death', name: 'Sound effect' }, 253 | { id: 'play bell_ringer_attack', name: 'Sound effect' }, 254 | { id: 'play bell_ringer_attack_hit', name: 'Sound effect' }, 255 | { id: 'play cult_guard_attack', name: 'Sound effect' }, 256 | { id: 'play cult_guard_attack_hit', name: 'Sound effect' }, 257 | { id: 'play cult_marksman_attack', name: 'Sound effect' }, 258 | { id: 'play cult_marksman_attack_hit', name: 'Sound effect' }, 259 | { id: 'play cult_sorcerer_attack', name: 'Sound effect' }, 260 | { id: 'play cult_sorcerer_attack_hit', name: 'Sound effect' }, 261 | { id: 'play cultist_death', name: 'Sound effect' }, 262 | { id: 'play flying_serpent_loop', name: 'Sound effect' }, 263 | { id: 'play poison_adept_attack', name: 'Sound effect' }, 264 | { id: 'play poison_adept_attack_hit', name: 'Sound effect' }, 265 | { id: 'play serpent_attack', name: 'Sound effect' }, 266 | { id: 'play serpent_death', name: 'Sound effect' }, 267 | { id: 'play serpent_handler_release', name: 'Sound effect' }, 268 | { id: 'play serpent_hiss', name: 'Sound effect' }, 269 | { id: 'play serpent_slither', name: 'Sound effect' }, 270 | { id: 'play worm_rider_hop', name: 'Sound effect' }, 271 | { id: 'play booklet_open', name: 'Sound effect' }, 272 | { id: 'play booklet_turn_page', name: 'Sound effect' }, 273 | { id: 'play booklet_close', name: 'Sound effect' }, 274 | { id: 'play hammer_cast', name: 'Sound effect' }, 275 | { id: 'play hammer_hit', name: 'Sound effect' }, 276 | { id: 'play shield_dash', name: 'Sound effect' }, 277 | { id: 'play fissure_break_apart', name: 'Sound effect' }, 278 | { id: 'play fissure_unmake', name: 'Sound effect' }, 279 | { id: 'play mindstone_off', name: 'Sound effect' }, 280 | { id: 'play mindstone_on', name: 'Sound effect' }, 281 | { id: 'play triskelion_fuse', name: 'Sound effect' }, 282 | { id: 'play potion_berserk', name: 'Sound effect' }, 283 | { id: 'play potion_cleansing', name: 'Sound effect' }, 284 | { id: 'play potion_defensive', name: 'Sound effect' }, 285 | { id: 'play potion_experience', name: 'Sound effect' }, 286 | { id: 'play potion_healing', name: 'Sound effect' }, 287 | { id: 'play potion_invisibility', name: 'Sound effect' }, 288 | { id: 'play potion_lightning', name: 'Sound effect' }, 289 | { id: 'play potion_lucky', name: 'Sound effect' }, 290 | { id: 'play potion_strength', name: 'Sound effect' }, 291 | { id: 'play potion_vampiric', name: 'Sound effect' }, 292 | { id: 'play bronze_guardian_pulling_hammer', name: 'Sound effect' }, 293 | { id: 'play bronze_guardian_removing_hammer', name: 'Sound effect' }, 294 | { id: 'play bronze_guardian_turbine', name: 'Sound effect' }, 295 | { id: 'play bronze_guardian_ears_ring', name: 'Sound effect' }, 296 | { id: 'play bronze_guardian_fuse', name: 'Sound effect' }, 297 | { id: 'play bronze_guardian_attack4', name: 'Sound effect' }, 298 | { id: 'play yeti_attack', name: 'Sound effect' }, 299 | { id: 'play yeti_attack_flick', name: 'Sound effect' }, 300 | { id: 'play yeti_attack_hit', name: 'Sound effect' }, 301 | { id: 'play yeti_awake_blow', name: 'Sound effect' }, 302 | { id: 'play yeti_awake_explosion', name: 'Sound effect' }, 303 | { id: 'play yeti_awake_inhale', name: 'Sound effect' }, 304 | { id: 'play yeti_awake_lick', name: 'Sound effect' }, 305 | { id: 'play yeti_blow', name: 'Sound effect' }, 306 | { id: 'play yeti_blow_ice_wall', name: 'Sound effect' }, 307 | { id: 'play yeti_death', name: 'Sound effect' }, 308 | { id: 'play yeti_inhale', name: 'Sound effect' }, 309 | { id: 'play yeti_inhale_lick', name: 'Sound effect' }, 310 | { id: 'play nagaraja_awake_roar', name: 'Sound effect' }, 311 | { id: 'play nagaraja_awake_swallow', name: 'Sound effect' }, 312 | { id: 'play nagaraja_awake_tongue_1', name: 'Sound effect' }, 313 | { id: 'play nagaraja_awake_tongue_2', name: 'Sound effect' }, 314 | { id: 'play nagaraja_dead', name: 'Sound effect' }, 315 | { id: 'play nagaraja_poison_attack', name: 'Sound effect' }, 316 | { id: 'play nagaraja_poison_attack_hit', name: 'Sound effect' }, 317 | { id: 'play nagaraja_wail', name: 'Sound effect' }, 318 | { id: 'play nagaraja_wail_brick', name: 'Sound effect' }, 319 | { id: 'play nagaraja_attack_eat', name: 'Sound effect' }, 320 | { id: 'play nagaraja_attack_lick', name: 'Sound effect' }, 321 | { id: 'play nagaraja_attack_swallow', name: 'Sound effect' }, 322 | { id: 'play nagaraja_tongue_damaged', name: 'Sound effect' }, 323 | { id: 'play nagaraja_tongue_lift', name: 'Sound effect' }, 324 | { id: 'play nagaraja_tongue_smell', name: 'Sound effect' }, 325 | { id: 'play nagaraja_tongue_wrap', name: 'Sound effect' }, 326 | { id: 'play bearer3_talk', name: 'Sound effect' }, 327 | { id: 'play bearer_attack', name: 'Sound effect' }, 328 | { id: 'play bearer_attack_hit', name: 'Sound effect' }, 329 | { id: 'play bearer_death', name: 'Sound effect' }, 330 | { id: 'play bearer_stealing', name: 'Sound effect' }, 331 | { id: 'play bearer_super_attack', name: 'Sound effect' }, 332 | { id: 'play bearer_scream', name: 'Sound effect' }, 333 | { id: 'play bearer4_talk', name: 'Sound effect' }, 334 | { id: 'play bearer4_talk_evolving', name: 'Sound effect' }, 335 | { id: 'play bearer_evolving', name: 'Sound effect' }, 336 | { id: 'play elementalist_aether_attack', name: 'Sound effect' }, 337 | { id: 'play elementalist_aether_attack_hit', name: 'Sound effect' }, 338 | { id: 'play elementalist_aether_blink', name: 'Sound effect' }, 339 | { id: 'play elementalist_death', name: 'Sound effect' }, 340 | { id: 'play elementalist_fire_attack', name: 'Sound effect' }, 341 | { id: 'play elementalist_fire_attack_hit', name: 'Sound effect' }, 342 | { id: 'play elementalist_fire_blink', name: 'Sound effect' }, 343 | { id: 'play elementalist_ice_attack', name: 'Sound effect' }, 344 | { id: 'play elementalist_ice_attack_hit', name: 'Sound effect' }, 345 | { id: 'play elementalist_ice_blink', name: 'Sound effect' }, 346 | { id: 'play elementalist_poison_attack', name: 'Sound effect' }, 347 | { id: 'play elementalist_poison_attack_hit', name: 'Sound effect' }, 348 | { id: 'play elementalist_poison_blink', name: 'Sound effect' }, 349 | { id: 'play elementalist_vigor_attack', name: 'Sound effect' }, 350 | { id: 'play elementalist_vigor_attack_hit', name: 'Sound effect' }, 351 | { id: 'play elementalist_vigor_blink', name: 'Sound effect' }, 352 | { id: 'play bearer5_talk', name: 'Sound effect' }, 353 | { id: 'play elementalist_evolving', name: 'Sound effect' }, 354 | { id: 'play perfected_attack', name: 'Sound effect' }, 355 | { id: 'play perfected_attack_hit', name: 'Sound effect' }, 356 | { id: 'play perfected_death', name: 'Sound effect' }, 357 | { id: 'play perfected_defense', name: 'Sound effect' }, 358 | { id: 'play perfected_energy_ball', name: 'Sound effect' }, 359 | { id: 'play perfected_energy_ball_hit', name: 'Sound effect' }, 360 | { id: 'play perfected_summon', name: 'Sound effect' }, 361 | { id: 'play perfected_talk', name: 'Sound effect' }, 362 | { id: 'play epilogue_devolving', name: 'Sound effect' }, 363 | { id: 'play epliogue_player_evolves', name: 'Sound effect' }, 364 | { id: 'play epilogue_talk', name: 'Sound effect' }, 365 | { id: 'play devolved_talk', name: 'Sound effect' }, 366 | { id: 'play dysangelos_guidance', name: 'Sound effect' }, 367 | { id: 'play dysangelos_guidance_1', name: 'Sound effect' }, 368 | { id: 'play dysangelos_guidance_2', name: 'Sound effect' }, 369 | { id: 'play dysangelos_guidance_3', name: 'Sound effect' }, 370 | { id: 'play dysangelos_intro_talk', name: 'Sound effect' }, 371 | { id: 'play ranting_tree_talk_halt', name: 'Sound effect' }, 372 | { id: 'play ranting_tree_talk_again', name: 'Sound effect' }, 373 | { id: 'play ranting_tree_talk_how_dare', name: 'Sound effect' }, 374 | { id: 'play ranting_tree_talk_avenge', name: 'Sound effect' }, 375 | { id: 'play ranting_tree_talk_get_out', name: 'Sound effect' }, 376 | { id: 'play ranting_tree_talk_impressive', name: 'Sound effect' }, 377 | { id: 'play ranting_tree_talk_very_well', name: 'Sound effect' }, 378 | { id: 'play ranting_tree_talk_extra', name: 'Sound effect' }, 379 | { id: 'play hans_talk_intro', name: 'Sound effect' }, 380 | { id: 'play hans_talk_reward', name: 'Sound effect' }, 381 | { id: 'play scotty_a_pleasure', name: 'Sound effect' }, 382 | { id: 'play scotty_a_worthy_opponent', name: 'Sound effect' }, 383 | { id: 'play scotty_deuced', name: 'Sound effect' }, 384 | { id: 'play scotty_failte_back', name: 'Sound effect' }, 385 | { id: 'play scotty_getting_good', name: 'Sound effect' }, 386 | { id: 'play scotty_grr', name: 'Sound effect' }, 387 | { id: 'play scotty_guess_which', name: 'Sound effect' }, 388 | { id: 'play scotty_intro', name: 'Sound effect' }, 389 | { id: 'play scotty_lets_harden', name: 'Sound effect' }, 390 | { id: 'play scotty_make_ye_guess', name: 'Sound effect' }, 391 | { id: 'play scotty_noo_jist', name: 'Sound effect' }, 392 | { id: 'play scotty_perhaps_the_rules', name: 'Sound effect' }, 393 | { id: 'play scotty_pick_some_treasure', name: 'Sound effect' }, 394 | { id: 'play scotty_shall_we_up', name: 'Sound effect' }, 395 | { id: 'play scotty_we_have_wee_use', name: 'Sound effect' }, 396 | { id: 'play scotty_well_met', name: 'Sound effect' }, 397 | { id: 'play scotty_well_then', name: 'Sound effect' }, 398 | { id: 'play scotty_wizard', name: 'Sound effect' }, 399 | { id: 'play scotty_wrong_choice', name: 'Sound effect' }, 400 | { id: 'play scotty_hell_be_back', name: 'Sound effect' }, 401 | { id: 'play scotty_out_of_treasure', name: 'Sound effect' }, 402 | { id: 'play scotty_there_he_is', name: 'Sound effect' }, 403 | { id: 'play nagaraja_choir', name: 'Sound effect' }, 404 | { id: 'play mushroom_boss_split', name: 'Sound effect' }, 405 | { id: 'play ant_hill', name: 'Sound effect' }, 406 | { id: 'play treasure_drop_common', name: 'Sound effect' }, 407 | { id: 'play treasure_drop_epic', name: 'Sound effect' }, 408 | { id: 'play treasure_drop_giant', name: 'Sound effect' }, 409 | { id: 'play treasure_drop_humble', name: 'Sound effect' }, 410 | { id: 'play treasure_drop_rare', name: 'Sound effect' }, 411 | { id: 'play dominotaur_awake', name: 'Sound effect' }, 412 | { id: 'play fire_geyser', name: 'Sound effect' }, 413 | { id: 'play ice_pillar', name: 'Sound effect' }, 414 | { id: 'play treasure_item_cyan', name: 'Sound effect' }, 415 | { id: 'play treasure_item_yellow', name: 'Sound effect' }, 416 | { id: 'play treasure_item_green', name: 'Sound effect' }, 417 | { id: 'play treasure_item_blue', name: 'Sound effect' }, 418 | { id: 'play treasure_item_red', name: 'Sound effect' }, 419 | { id: 'play treasure_item_rainbow', name: 'Sound effect' }, 420 | { id: 'play ki_slerper_walk', name: 'Sound effect' }, 421 | { id: 'play mindstone_found', name: 'Sound effect' }, 422 | { id: 'play ghost_tomb_death', name: 'Sound effect' }, 423 | { id: 'play perfected_fly_start', name: 'Sound effect' }, 424 | { id: 'play perfected_fly_loop', name: 'Sound effect' }, 425 | { id: 'play perfected_fly_end', name: 'Sound effect' }, 426 | { id: 'play shop_door_open', name: 'Sound effect' }, 427 | { id: 'play shop_door_enter', name: 'Sound effect' }, 428 | { id: 'play scorpion_death', name: 'Sound effect' }, 429 | { id: 'play bomb_cart_explosion', name: 'Sound effect' }, 430 | { id: 'play bomb_cart_fuse', name: 'Sound effect' }, 431 | { id: 'play bomb_cart_move', name: 'Sound effect' }, 432 | { id: 'play bronze_gate_close', name: 'Sound effect' }, 433 | { id: 'play poison_powerup', name: 'Sound effect' }, 434 | { id: 'play acronian_cultist_power_up', name: 'Sound effect' }, 435 | { id: 'play giant_ice_elemental_attack', name: 'Sound effect' }, 436 | { id: 'play scout_dialog', name: 'Sound effect' }, 437 | { id: 'play morel_punch', name: 'Sound effect' }, 438 | { id: 'play falling_stonefolk', name: 'Sound effect' }, 439 | { id: 'play scout_arrives', name: 'Sound effect' }, 440 | { id: 'play scout_leaves', name: 'Sound effect' }, 441 | { id: 'play scout_wing', name: 'Sound effect' }, 442 | { id: 'play scout_focus', name: 'Sound effect' }, 443 | { id: 'play dog_bark', name: 'Sound effect' }, 444 | { id: 'play frog', name: 'Sound effect' }, 445 | { id: 'play lost_item_boost', name: 'Sound effect' }, 446 | { id: 'play treasure_item_lost', name: 'Sound effect' }, 447 | { id: 'play blade_glow', name: 'Sound effect' }, 448 | { id: 'play blade_pallas_attack', name: 'Sound effect' }, 449 | { id: 'play blade_raise', name: 'Sound effect' }, 450 | { id: 'play blade_drag', name: 'Sound effect' }, 451 | { id: 'play auggie_voice', name: 'Sound effect' }, 452 | { id: 'play pallas_voice', name: 'Sound effect' }, 453 | { id: 'play quest_stone_jump', name: 'Sound effect' }, 454 | { id: 'play quest_stone_unlock', name: 'Sound effect' }, 455 | { id: 'play bardiche_cast', name: 'Sound effect' }, 456 | { id: 'play boo_voice', name: 'Sound effect' }, 457 | { id: 'play quarterstaff_cast', name: 'Sound effect' }, 458 | { id: 'play air_hiss', name: 'Sound effect' }, 459 | { id: 'play bang_go_forward', name: 'Sound effect' }, 460 | { id: 'play fire_orbs', name: 'Sound effect' }, 461 | { id: 'play open_note', name: 'Sound effect' }, 462 | { id: 'play talisman_reveal', name: 'Sound effect' }, 463 | { id: 'play fire_beast_1', name: 'Sound effect' }, 464 | { id: 'play fire_beast_2', name: 'Sound effect' }, 465 | { id: 'play uulaa_voice', name: 'Sound effect' }, 466 | { id: 'play mask_summon_1', name: 'Sound effect' }, 467 | { id: 'play mask_summon_2', name: 'Sound effect' }, 468 | // #endregion 469 | // #region Keywords 470 | { id: 'loc', name: 'The current location the player is visiting' }, 471 | { id: 'loc.id', name: 'The unique identifier of the current location' }, 472 | { id: 'loc.name', name: 'The localized name of the current location' }, 473 | { id: 'loc.stars', name: 'The current location\'s difficulty' }, 474 | { id: 'loc.begin', name: 'Is true only on the first frame of a location, when time = 0, before any game simulation has run. Is not true after an Ouroboros loop. Useful for resetting variables' }, 475 | { id: 'loc.loop', name: 'Is true on the first frame of a run after an Ouroboros loop' }, 476 | { id: 'loc.isQuest', name: 'True if the current location is a special location from a Legend or custom quest. False otherwise'}, 477 | { id: 'loc.averageTime', name: 'The current location\'s average completion time. A location\'s average time is calculated in a weighted manner, where the latest completion time is worth more and older times are worth progressively less the older they are'}, 478 | { id: 'loc.bestTime', name: 'The current location\'s best completion time (your record, high-score)' }, 479 | { id: 'foe', name: 'The current foe being targeted by the player' }, 480 | { id: 'foe.GetCount', name: '```stonescript\n foe.GetCount(int) \n```\n---\n * The number of foes within a specific number of units.' }, 481 | { id: 'foe.name', name: 'The localized name of the foe being targeted by the player' }, 482 | { id: 'foe.damage', name: 'The damage per attack of the foe being targeted by the player'}, 483 | { id: 'foe.distance', name: 'The distance between the player and the foe being targeted' }, 484 | { id: 'foe.count', name: 'The number of foes within 46 units' }, 485 | { id: 'foe.hp', name: 'The current hitpoints of the foe being targeted by the player' }, 486 | { id: 'foe.maxhp', name: 'The maximum hitpoints of the foe being targeted by the player' }, 487 | { id: 'foe.armor', name: 'The current armor of the foe being targeted by the player' }, 488 | { id: 'foe.maxarmor', name: 'The maximum armor of the foe being targeted by the player' }, 489 | { id: 'foe.buffs.count', name: 'The number of buffs (positive effects) on the foe being targeted'}, 490 | { id: 'foe.buffs.string', name: 'A composite of information about all the buffs on the target foe'}, 491 | { id: 'buffs.oldest', name: 'The ID of the oldest buff on the player'}, 492 | { id: 'foe.debuffs.count', name: 'The number of debuffs (negative effects)'}, 493 | { id: 'foe.debuffs.string', name: 'A composite of information about all the debuffs'}, 494 | { id: 'debuffs.oldest', name: 'The ID of the oldest debuff on the player'}, 495 | { id: 'foe.state', name: 'A number representing the target foe\'s current state' }, 496 | { id: 'foe.time', name: 'Elapsed number of frames in target foe\'s current state' }, 497 | { id: 'foe.level', name: 'The level number of the target foe' }, 498 | { id: 'item.GetLoadoutR', name: '```stonescript\n item.GetLoadoutR(int) \n```\n---\n * Returns the items in a specific loadout. The integer parameter is the loadout number to query. Returns a blank string if that loadout has no item in that slot.' }, 499 | { id: 'item.GetLoadoutL', name: '```stonescript\n item.GetLoadoutL(int) \n```\n---\n * Returns the items in a specific loadout. The integer parameter is the loadout number to query. Returns a blank string if that loadout has no item in that slot.' }, 500 | { id: 'item.left.id', name: 'The ID of the item equipped to the left hand' }, 501 | { id: 'item.right.id', name: 'The ID of the item equipped to the right hand' }, 502 | { id: 'item.left.state', name: 'The numeric representation for an equipped weapon\'s current state' }, 503 | { id: 'item.left.time', name: 'The numeric representation for an equipped weapon\'s elapsed frames within that state.' }, 504 | { id: 'item.right.state', name: 'The numeric representation for an equipped weapon\'s current state' }, 505 | { id: 'item.right.time', name: 'The numeric representation for an equipped weapon\'s elapsed frames within that state.' }, 506 | { id: 'item.left', name: 'The item equipped to the left hand' }, 507 | { id: 'item.right', name: 'The item equipped to the right hand' }, 508 | { id: 'item.potion', name: 'The potion currently brewed. Includes "auto" if auto-refill is enabled on the Cauldron' }, 509 | { id: 'harvest', name: 'The next harvestable object, such as a tree or boulder' }, 510 | { id: 'harvest.distance', name: 'The distance between the player and the nearest harvestable object' }, 511 | { id: 'pickup', name: 'The current pickup being targeted by the player' }, 512 | { id: 'pickup.distance', name: 'The distance between the player and the pickup being targeted' }, 513 | { id: 'time', name: 'The current frame number of the location' }, 514 | { id: 'totaltime', name: 'The current frame number of the location, accumulated in case of boss sub-location' }, 515 | { id: 'armor', name: 'The player\'s current armor, rounded down' }, 516 | { id: 'armor.f', name: 'The player\'s current armor\'s fractional amount' }, 517 | { id: 'buffs.count', name: 'The number of buffs (positive effects) on the player' }, 518 | { id: 'buffs.string', name: 'A composite of information about all buffs on the player' }, 519 | { id: 'debuffs.count', name: 'The number of debuffs (negative effects)' }, 520 | { id: 'debuffs.string', name: 'A composite of information about all debuffs' }, 521 | { id: 'hp', name: 'The player\'s current hitpoints' }, 522 | { id: 'maxhp', name: 'The player\'s maximum hitpoints' }, 523 | { id: 'maxarmor', name: 'The player\'s maximum armor, rounded down' }, 524 | { id: 'pos.x', name: 'The player\'s current X position' }, 525 | { id: 'pos.y', name: 'The player\'s current Y position' }, 526 | { id: 'pos.z', name: 'The player\'s current Z position' }, 527 | { id: 'ai.enabled', name: 'True if the AI is on, False if the AI is off (e.g. during a cinematic moment)' }, 528 | { id: 'ai.paused', name: 'True if the AI is temporarily suspended, such as when waiting for a treasure to drop' }, 529 | { id: 'ai.idle', name: 'True if the player is idle, waiting for something such as an attack to complete' }, 530 | { id: 'ai.walking', name: 'True if the player is moving' }, 531 | { id: 'face', name: 'The player\'s current facial expression' }, 532 | { id: 'key', name: 'The state of custom game input' }, 533 | { id: 'key.Bind', name: '```stonescript\n key.Bind(act, key1, [key2]) \n```\n---\n * Assigns a new set of keys to a specific action. If another action already has one of those keys, then the key already in use is abandoned for the original action. Up to two keys may be assigned to an action' }, 534 | { id: 'key.GetKeyAct', name: '```stonescript\n key.GetKeyAct(key) \n```\n---\n * Returns the action bound to a given key. Returns "None" if the given key is not bound to any actions' }, 535 | { id: 'key.GetActKey', name: '```stonescript\n key.GetActKey(act) \n```\n---\n * Returns the first key bound to a given action. Returns "None" if the given action has no keys bound to it' }, 536 | { id: 'key.GetActKey2', name: '```stonescript\n key.GetActKey2(act) \n```\n---\n * Returns the second key bound to a given action. Returns "None" if the given action does not have a secondary key bound to it' }, 537 | { id: 'key.GetActLabel', name: '```stonescript\n key.GetActLabel(act) \n```\n---\n * Returns a user-facing label that represents the first key bound to a given action. The current implementation returns the first letter of the bound key, which can be confusing in cases such as "LeftShift"' }, 538 | { id: 'key.ResetBinds', name: '```stonescript\n key.ResetBinds() \n```\n---\n * Resets all actions to their default key bindings' }, 539 | { id: 'res.stone', name: 'The player\'s current amount of stone in their inventory' }, 540 | { id: 'res.wood', name: 'The player\'s current amount of wood in their inventory' }, 541 | { id: 'res.tar', name: 'The player\'s current amount of tar in their inventory' }, 542 | { id: 'res.ki', name: 'The player\'s current amount of ki in their inventory' }, 543 | { id: 'res.bronze', name: 'The player\'s current amount of bronze in their inventory' }, 544 | { id: 'res.crystals', name: 'The player\'s current amount of crystals in their inventory' }, 545 | { id: 'player.direction', name: 'Indicates the direction in which the player is facing. Returns a value of 1 for right and -1 for left' }, 546 | { id: 'player.name', name: 'The name chosen by the player' }, 547 | { id: 'totalgp', name: 'The total "Gear Points" of your inventory, calculated from item star levels and enchantment bonuses' }, 548 | { id: 'rng', name: 'Returns a random integer between 0 and 9999' }, 549 | { id: 'rngf', name: 'Returns a random floating-point number between 0 and 1' }, 550 | { id: 'input.x', name: 'The X position, on the ASCII grid, of the input device (mouse/touch)' }, 551 | { id: 'input.y', name: 'The Y position, on the ASCII grid, of the input device (mouse/touch)' }, 552 | { id: 'sys.cacheRemoteFiles', name: 'Indicates if files imported remotely should be cached between runs. Default is `true`. If set to `false`, then remote scripts will re-download when you begin play from the Locations screen. It can be useful to change this during development and iteration of new scripts that are deployed remotely. This global property persists between runs.' }, 553 | { id: 'sys.fileUrl', name: 'Getter for the current file path to be used when importing scripts. The default value depends on your device. On PC the default value is `local`. On mobile the default is `https://StonestoryRPG.com/stonescript/`' }, 554 | { id: 'sys.SetFileUrl', name: '```stonescript\nsys.SetFileUrl(str)\n```\n---\n \n * Changes the origin of imported scripts when using the commands `import` or `new`. Can only be called on the Mind Stone and will error if written on an imported script. Accepts any URL as a remote location, but also accepts the values `local` and `remote` as shortcuts to easily point at your local drive or to the official Stone Story RPG repository, respectively. If null is passed as parameter, then the file URL resets to the default value for your device. This global property persists between runs.' }, 555 | { id: 'sys.os', name: 'The user\'s operating system, such as `Android`, `iOS`, `Linux`, `OSX` or `Windows`.' }, 556 | { id: 'sys.isMobile', name: 'Returns true if the users is on `Android` or `iOS`.' }, 557 | { id: 'sys.isPC', name: 'Returns true if the users is on `Win` or `Mac` or `Linux`.' }, 558 | // { id: 'sys.isConsole', name: '???' }, 559 | { id: 'screen.i', name: 'The screen\'s position in-game, as an index that increses when the player reaches the right-side and it slides over' }, 560 | { id: 'screen.x', name: 'The screen\'s position in-game' }, 561 | { id: 'screen.w', name: 'The width of the screen\'s ASCII grid' }, 562 | { id: 'screen.h', name: 'The height of the screen\'s ASCII grid' }, 563 | { id: 'time.msbn', name: 'Unix time represents the number of milliseconds that have elapsed since 1970-01-01T00:00:00Z (January 1, 1970, at 12:00 AM UTC). It does not take leap seconds into account. Returns a BigNumber'}, 564 | { id: 'time.year', name: 'The local system time on the player\'s computer' }, 565 | { id: 'time.month', name: 'The local system time on the player\'s computer' }, 566 | { id: 'time.day', name: 'The local system time on the player\'s computer' }, 567 | { id: 'time.hour', name: 'The local system time on the player\'s computer' }, 568 | { id: 'time.minute', name: 'The local system time on the player\'s computer' }, 569 | { id: 'time.second', name: 'The local system time on the player\'s computer' }, 570 | { id: 'time.FormatCasual', name: '```stonescript\ntime.FormatCasual(int, [bool])\n```\n---\n \n * Converts an amount of frames into a human-readable string representation of time, such as "1m 23s". The second parameter (bool) is optional; If \'true\', then precision is maximized in the result' }, 571 | { id: 'time.FormatDigital', name: '```stonescript\ntime.FormatDigital(int, [bool])\n```\n---\n \n * Converts an amount of frames into a human-readable string representation of time, such as "1:23". The second parameter (bool) is optional; If \'true\', then precision is maximized in the result' }, 572 | { id: 'utc.year', name: 'The local system time on the player\'s computer' }, 573 | { id: 'utc.month', name: 'The local system time on the player\'s computer' }, 574 | { id: 'utc.day', name: 'The current UTC time' }, 575 | { id: 'utc.hour', name: 'The current UTC time' }, 576 | { id: 'utc.minute', name: 'The current UTC time' }, 577 | { id: 'utc.second', name: 'The current UTC time' }, 578 | { id: 'activate', name: '```stonescript\nactivate (ability)\n```\n---\n \n * Activates an item ability. (ability) can have these values: potion, P, left, L, right, R' }, 579 | { id: 'brew', name: '```stonescript\nbrew (ingredients)\n```\n---\n \n * Refills the potion bottle to the specified combination of ingredients. Executes only at the beginning of a run, at time 0. Ingredients can be stone, wood, tar or bronze and should be separated by +. Ingredient names can be written in English or in the language selected in the settings' 580 | }, 581 | { id: 'equip', name: '```stonescript\nequip (str)\n```\n---\n \n * Equips an item. (str) has a limit of 7 criteria. Two-handed items must use this form of the equip command' }, 582 | { id: 'equipL', name: '```stonescript\nequipL (str)\n```\n---\n \n * Equips an item to the left hand that best fits the given criteria' }, 583 | { id: 'equipR', name: '```stonescript\nequipR (str)\n```\n---\n \n * Equips an item to the right hand that best fits the given criteria' }, 584 | { id: 'loadout', name: '```stonescript\nloadout (n)\n```\n---\n \n * Equips a specific loadout number' }, 585 | { id: 'var', name: '```stonescript\nvar (variable)\n```\n---\n \n * Declares a variable that can be used in math, logical and string operations' }, 586 | { id: 'func', name: '```stonescript\nfunc (function)\n```\n---\n \n * Declares a function that can be called later' }, 587 | { id: 'for', name: '```stonescript\nfor v = a..b\n```\n---\n \n * Creates a loop that iterates a variable \'v\' from value \'a\' to value \'b\'. Code that appears inside the loop\'s scope will run multiple times' }, 588 | { id: 'import', name: '```stonescript\nimoprt (script)\n```\n---\n \n * Loads and executes a singular copy of an external script' }, 589 | { id: 'new', name: '```stonescript\nnew (script)\n```\n---\n \n * Loads and executes an external script similar to \'import\'. However, objects loaded with \'new\' are each an individual copy and their script body will only execute one time' }, 590 | { id: 'play', name: '```stonescript\nplay (sound) [pitch]\n```\n---\n \n* Plays a sound effect with an optional pitch value. The pitch default value is 100 with higher numbers increasing the pitch and smaller numbers lowering it' }, 591 | { id: 'ambient', name: 'Returns a comma-separated list of all active ambient audio IDs' }, 592 | { id: 'ambient.Add', name: '```stonescript\nambient.Add(str)\n```\n---\n \n * Adds a layer of ambient audio, with the given sound ID. Up to 4 layers. If a 5th layer is added, the oldest layer is removed' }, 593 | { id: 'ambient.Stop', name: 'Clears all ambient layers' }, 594 | { id: 'draw.Bg', name: '```stonescript\ndraw.Bg(x, y, color, [w], [h])\n```\n---\n \n * Sets the background color at a specific screen position' }, 595 | { id: 'draw.Box', name: '```stonescript\ndraw.Box(x, y, w, h, color, style)\n```\n---\n \n * Draws a rectangular shape at the specified position and size. The rectangle\'s border is defined by color and a style number. Negative style numbers cause the center of the rectangle to be transparent. CAVEAT - At this time, advanced prints always draw on top of boxes' }, 596 | { id: 'draw.Clear', name: '```stonescript\ndraw.Clear()\n```\n---\n \n * Clears the entire screen' }, 597 | { id: 'draw.GetSymbol', name: '```stonescript\ndraw.GetSymbol(x, y)\n```\n---\n \n * Returns the glyph at screen position (x, y)' }, 598 | { id: 'draw.Player', name: '```stonescript\ndraw.Player([x], [y])\n```\n---\n \n * Draws the player character, with all equipment and addons, at a specific point in the script. Optional offset values x, y. For drawing to an absolute screen position, see the screen namespace and derive offsets that convert from the player\'s local position to screen position'}, 599 | { id: 'int.Parse', name: '```stonescript\nint.Parse(str)\n```\n---\n \n * Converts a string of a number into an integer value. If the given string is not a number an error is thrown' }, 600 | { id: 'item.CanActivate', name: '```stonescript\nitem.CanActivate()\n```\n---\n \n * Returns true if it\'s possible to activate item abilities. False otherwise. In some gameplay situations all ability activations are disabled, even if they are not on cooldown, such as moments before a boss fight or during a cinematic' 601 | }, 602 | { id: 'item.GetCooldown', name: '```stonescript\nitem.GetCooldown(str)\n```\n---\n \n * Returns the remaining cooldown time (in frames) for a given ability' }, 603 | { id: 'item.GetCount', name: '```stonescript\nitem.GetCount(str)\n```\n---\n \n * Returns the number of copies of an item in the inventory. Returns 0 if no item is found' }, 604 | { id: 'loc.Leave', name: '```stonescript\nloc.Leave()\n```\n---\n \n * Causes the run to be abandoned as if the player had pressed to leave manually' }, 605 | { id: 'loc.Pause', name: '```stonescript\nloc.Leave()\n```\n---\n \n * Causes the run to be paused as if the player had pressed the pause button manually' }, 606 | { id: 'math.e', name: 'The constant e, also known as Euler\'s number, approximately 2.71828' }, 607 | { id: 'math.pi', name: 'The constant π, approximately 3.1415926' }, 608 | { id: 'math.BigNumber', name: '```stonescript\nmath.BigNumber(num)\n```\n---\n \n * BigNumbers are a special type of object that provide a way to work with large integers that exceed 32 bits. While they can only hold positive and negative whole number values, their arithmetic and comparison operations work with floats as well as integers and other BigNumbers' }, 609 | { id: 'math.Abs', name: '```stonescript\nmath.Abs(num)\n```\n---\n \n * Returns the absolute value of a given number' }, 610 | { id: 'math.Sign', name: '```stonescript\nmath.Sign(num)\n```\n---\n \n * Returns -1 if the given number is negative. Otherwise, returns 1' }, 611 | { id: 'math.Min', name: '```stonescript\nmath.Min(num1, num2)\n```\n---\n \n * Returns the smallest of the two numbers' }, 612 | { id: 'math.Max', name: '```stonescript\nmath.Max(num1, num2)\n```\n---\n \n * Returns the largest of the two numbers' }, 613 | { id: 'math.Clamp', name: '```stonescript\nmath.Clamp(num, min, max)\n```\n---\n \n * Constrains a number to within the range \'min\' and \'max\'. If the number is already within the range then it will be returned without change' }, 614 | { id: 'math.Round', name: '```stonescript\nmath.Round(num)\n```\n---\n \n * Rounds a number to the nearest whole number' }, 615 | { id: 'math.RoundToInt', name: '```stonescript\nmath.RoundToInt(num)\n```\n---\n \n * Rounds a number to the nearest whole integer' }, 616 | { id: 'math.Floor', name: '```stonescript\nmath.Floor(num)\n```\n---\n \n * Rounds a number down, to the first whole number smaller than it' }, 617 | { id: 'math.FloorToInt', name: '```stonescript\nmath.FloorToInt(num)\n```\n---\n \n * Rounds a number down, to the first integer smaller than it' }, 618 | { id: 'math.Ceil', name: '```stonescript\nmath.Ceil(num)\n```\n---\n \n * Rounds a number up, to the first whole number greater than it' }, 619 | { id: 'math.CeilToInt', name: '```stonescript\nmath.CeilToInt(num)\n```\n---\n \n * Rounds a number up, to the first integer greater than it' }, 620 | { id: 'math.Lerp', name: '```stonescript\nmath.Lerp(a, b, t)\n```\n---\n \n * Performs a linear interpolation, from value a to b at time (percentage)' }, 621 | { id: 'math.Log', name: '```stonescript\nmath.Log(num, base)\n```\n---\n \n * Returns the logarithm of a number at a given base' }, 622 | { id: 'math.Pow', name: '```stonescript\nmath.Pow(num, p)\n```\n---\n \n * Returns the number raised to a power' }, 623 | { id: 'math.Sqrt', name: '```stonescript\nmath.Sqrt(num)\n```\n---\n \n * Returns the square root of a number' }, 624 | { id: 'math.ToDeg', name: '```stonescript\nmath.ToDeg(num)\n```\n---\n \n * Converts a radian number to degrees' }, 625 | { id: 'math.ToRad', name: '```stonescript\nmath.ToRad(num)\n```\n---\n \n * Converts a degrees number to radians' }, 626 | { id: 'math.Acos', name: '```stonescript\nmath.Acos(num)\n```\n---\n \n * Returns the arc-cosine of a number, in radians. The input bounds are -1 to 1. If the input value is out of bounds then "NaN" is returned' }, 627 | { id: 'math.Atan', name: '```stonescript\nmath.Atan(num)\n```\n---\n \n * Returns the arc-tangent of a number, in radians' }, 628 | { id: 'math.Atan2', name: '```stonescript\nmath.Atan2(y, x)\n```\n---\n \n * Returns the angle, in radians, between the x-axis and the line from the origin to the point (x,y)' }, 629 | { id: 'math.Asin', name: '```stonescript\nmath.Asin(num)\n```\n---\n \n * Returns the arc-sine of a number, in radians. The input bounds are -1 to 1. If the input value is out of bounds then "NaN" is returned' }, 630 | { id: 'math.Atan', name: '```stonescript\nmath.Atan(num)\n```\n---\n \n * Returns the arc-tangent of a number, in radians' }, 631 | { id: 'math.Cos', name: '```stonescript\nmath.Cos(num)\n```\n---\n \n * Returns the cosine of a given radian angle' }, 632 | { id: 'math.Sin', name: '```stonescript\nmath.Sin(num)\n```\n---\n \n * Returns the sine of a given radian angle' }, 633 | { id: 'math.Tan', name: '```stonescript\nmath.Tan(num)\n```\n---\n \n * Returns the tangent of a given radian angle' }, 634 | { id: 'music', name: 'Returns the ID of the currently playing music' }, 635 | { id: 'music.Play', name: '```stonescript\nmusic.Play(str)\n```\n---\n \n * Plays a music, with the given sound ID. There can only be one music playing at a time' }, 636 | { id: 'music.Stop', name: '```stonescript\nmusic.Stop()\n```\n---\n \n * Stops all music' }, 637 | { id: 'player.ShowScaredFace', name: '```stonescript\nplayer.ShowScaredFace(num)\n```\n---\n \n * If the player has big-head enabled, their facial expression will change to scared for a given amount of time' }, 638 | { id: 'screen.FromWorldX', name: '```stonescript\nscreen.FromWorldX(int)\n```\n---\n \n * Converts a value on the X-axis from world-space to screen-space' }, 639 | { id: 'screen.FromWorldZ', name: '```stonescript\nscreen.FromWorldZ(int)\n```\n---\n \n * Converts a value from the world-space Z-axis to screen-space Y-axis' }, 640 | { id: 'screen.ToWorldX', name: '```stonescript\nscreen.ToWorldX(int)\n```\n---\n \n * Converts a value on the X-axis from screen-space to world-space' }, 641 | { id: 'screen.ToWorldZ', name: '```stonescript\nscreen.ToWorldZ(int)\n```\n---\n \n * Converts a value from the screen-space Y-axis to world-space Z-axis' }, 642 | { id: 'screen.Next', name: '```stonescript\nscreen.Next()\n```\n---\n \n * For locations that are multi-screen, moves the camera one screen forward in relation to the player' }, 643 | { id: 'screen.Previous', name: '```stonescript\nscreen.Previous()\n```\n---\n \n * For locations that are multi-screen, moves the camera one screen back in relation to the player' }, 644 | { id: 'screen.ResetOffset', name: '```stonescript\nscreen.ResetOffset()\n```\n---\n \n * Resets the camera to follow the player, undoing changes made by screen.Next() and screen.Previous()' }, 645 | { id: 'storage', name: 'Values saved into permanent storage persist when you leave a location, as well as when the game is shut down. They are not part of your primary_save, existing instead in a series of separate files within the Stonescript folder. Imported scripts access storage in isolation from each other, allowing different modules to use the same keys without modifying each other\'s data' }, 646 | { id: 'storage.Delete', name: '```stonescript\nstorage.Delete(str)\n```\n---\n \n * Deletes any value that may exist at the specified key' }, 647 | { id: 'storage.Get', name: '```stonescript\nstorage.Get(str, [value])\n```\n---\n \n * Retrieves a permanent value stored at the specified key. If it\'s not found, returns the second parameter as a default value' }, 648 | { id: 'storage.Has', name: '```stonescript\nstorage.Has(string)\n```\n---\n \n * Returns true if the specified key exists in permanent storage; false otherwise' }, 649 | { id: 'storage.Incr', name: '```stonescript\nstorage.Incr(str, [int])\n```\n---\n \n * Increases by 1 (if int is empty) the value stored at the specified key, then returns the new value' }, 650 | { id: 'storage.Keys', name: '```stonescript\nstorage.Keys()\n```\n---\n \n * Retrieves an array of strings containing all the storage keys available in the current context'}, 651 | { id: 'storage.Set', name: '```stonescript\nstorage.Set(string)\n```\n---\n \n * Saves a value to permanent storage at a specified key' }, 652 | { id: 'string.Break', name: '```stonescript\nstring.Break(str, int)\n```\n---\n \n * Breaks a string into multiple strings, given a max width' }, 653 | { id: 'string.Capitalize', name: '```stonescript\nstring.Capitalize(str)\n```\n---\n \n * Changes the first letter of a string to be upper-case' }, 654 | { id: 'string.Equals', name: '```stonescript\nstring.Equals(str1, str2)\n```\n---\n \n * Takes two string parameters and returns true if they are exactly the same. Returns false otherwise. Case sensitive' }, 655 | { id: 'string.Format', name: '```stonescript\nstring.Format(str, ...)\n```\n---\n \n * Modifies a string by replacing format-templates with the values of the other parameters, then returns the final composed string. This is a powerful function that supports lots of formatting options' }, 656 | { id: 'string.IndexOf', name: '```stonescript\nstring.IndexOf(str, criteria, [startAt])\n```\n---\n \n * Takes a string variable, a string criteria and a starting index as parameters. Finds the position of the criteria inside the string, but begins the search at \'startAt\'. Returns -1 if not found' }, 657 | { id: 'string.Join', name: '```stonescript\nstring.Join(s, [], [int], [int])\n```\n---\n \n * Takes an array of strings [] and combines it into a single string with the separator s. Optional integer parameters can be passed that specify the starting index and number of elements to combine. If no index parameters are provided, the entire array is combined' }, 658 | { id: 'string.Size', name: '```stonescript\nstring.Size(str)\n```\n---\n \n * Takes a string variable as parameter and calculates how long it is, in number of glyphs' }, 659 | { id: 'string.Split', name: '```stonescript\nstring.Split(str, [s...], [bool])\n```\n---\n \n * Takes a string and breaks it down into an array of strings, given a set of string separators s…. If no separators are provided, then the string is broken wherever there is a space. An optional boolean parameter specifies if empty entries should be discarded' }, 660 | { id: 'string.Sub', name: '```stonescript\nstring.Sub(str, startAt, [len])\n```\n---\n \n * Takes a string variable, a starting index and a length as parameters and splits the string from that starting point, stopping at the given length' }, 661 | { id: 'string.ToLower', name: '```stonescript\nstring.ToLower(str)\n```\n---\n \n * Changes all letters in a string to lower-case' }, 662 | { id: 'string.ToUpper', name: '```stonescript\nstring.ToUpper(str)\n```\n---\n \n * Changes all letters in a string to upper-case' }, 663 | { id: 'ui.root', name: 'The base UI object on top of which the entire tree is built' }, 664 | { id: 'ui.AddAnim', name: '```stonescript\nui.AddAnim(str)\n```\n---\n \n * Adds an Anim object to the root Panel. Accepts an animation sprite sheet as parameter' }, 665 | { id: 'ui.AddButton', name: '```stonescript\nui.AddButton()\n```\n---\n \n * Adds a Button object to the root Panel' }, 666 | { id: 'ui.AddPanel', name: '```stonescript\nui.AddPanel()\n```\n---\n \n * Adds a Panel object to the root Panel. Panels are an important object type, serving as containers for other elements' }, 667 | { id: 'ui.AddStyle', name: '```stonescript\nui.AddStyle()\n```\n---\n \n * Adds a new style that can be used for drawing rectangular Components such as Panels and Buttons. Returns an ID number of the new style. Is protected against the same style being added multiple times, in which case nothing changes and the same ID is returned. Because different scripts may all call ui.AddStyle(), it\'s recommended to save the ID as a variable instead of hard-coding style numbers into the script' }, 668 | { id: 'ui.AddText', name: '```stonescript\nui.AddText(str)\n```\n---\n \n * Adds a Text object to the root Panel' }, 669 | { id: 'ui.Clear', name: '```stonescript\nui.Clear()\n```\n---\n \n * Removes all UI elements from the main container' }, 670 | { id: 'ui.ShowBanner', name: '```stonescript\nui.ShowBanner(str, [str])\n```\n---\n \n * Displays the animated banner with up to two messages. The banner animation restarts each time ui.ShowBanner() is called' }, 671 | { id: 'ui.OpenInv', name: '```stonescript\nui.OpenInv()\n```\n---\n \n * Opens the inventory screen' }, 672 | { id: 'ui.OpenMind', name: '```stonescript\nui.OpenMind()\n```\n---\n \n * Opens the Mind Stone screen' }, 673 | { id: 'color.FromRGB', name: '```stonescript\ncolor.FromRGB(r, g, b)\n```\n---\n \n * Converts a color from three integer numbers (0 to 255) into a string' }, 674 | { id: 'color.ToRGB', name: '```stonescript\ncolor.ToRGB(str)\n```\n---\n \n * Converts a color from string to three integer numbers (0 to 255)' }, 675 | { id: 'color.Lerp', name: '```stonescript\ncolor.Lerp(c1, c2, t)\n```\n---\n \n * Interpolates linearly from color c1 to color c2 at time (percentage) t' }, 676 | { id: 'color.Random', name: '```stonescript\ncolor.Random()\n```\n---\n \n * Returns a random color' }, 677 | { id: 'Type', name: '```stonescript\nType(var)\n```\n---\n \n * Evaluates the type of a variable and returns a string representation. Possible types include \'string\', \'int\', \'bool\', \'function\', \'object\' and \'null\'' }, 678 | { id: 'te.language', name: 'The code for the language selected by the player in settings. Possible values: EN, PT-BR, ZH-CN, ZH-TW, FR, DE, RU, ES-LA, ES-EU, JP, KR and TK' }, 679 | { id: 'te.xt', name: '```stonescript\nte.xt(str)\n```\n---\n \n * Translates a given English text into the player\'s selected language. If a translated version is not found, then the input text is returned instead. Alternatively, a text identifier (TID) can be used as input--albeit the exhausting list of TIDs is beyond the scope of this manual' }, 680 | { id: 'te.GetTID', name: '```stonescript\nte.GetTID(str)\n```\n---\n \n * Returns the text identifier (TID) for a given text. The input text is expected in the language selected by the player' }, 681 | { id: 'te.ToEnglish', name: '```stonescript\nte.ToEnglish(str)\n```\n---\n \n * Translates a given text from the player\'s selected language into the original English text. If a translated version is not found, then the input text is returned instead' }, 682 | { id: 'summon.count', name: 'The number of summoned allies currently in game' }, 683 | { id: 'summon.GetId', name: '```stonescript\n summon.GetId(index = 0) \n```\n---\n * Returns the ID of the summon at a given `index`. The `index` parameter is optional and defaults to zero (first summon). Returns null if no summons are at that `index`' }, 684 | { id: 'summon.GetName', name: '```stonescript\n summon.GetName(index = 0) \n```\n---\n * Returns the localized name of the summon at a given `index`. The `index` parameter is optional and defaults to zero (first summon). Returns null if no summons are at that `index`.' }, 685 | { id: 'summon.GetVar', name: '```stonescript\n summon.GetVar(varName, index = 0) \n```\n---\n * Returns the value for a custom variable on a summon. Different types of summons expose different variables, based on their unique abilities. The `index` parameter is optional and defaults to zero (first summon). Returns null if no summons are at that `index`. Shows an error if varName does not correspond to a valid variable' }, 686 | { id: 'summon.GetState', name: '```stonescript\n summon.GetState(index = 0) \n```\n---\n * Returns a number representing the current state of a summon. The `index` parameter is optional and defaults to zero (first summon). Returns -1 if no summons are at that `index`' }, 687 | { id: 'summon.GetTime', name: '```stonescript\n summon.GetTime(index = 0) \n```\n---\n * Returns the elapsed number of frames in the current state of a summon. The `index` parameter is optional and defaults to zero (first summon). Returns -1 if no summons are at that `index`' }, 688 | // #endregion 689 | // #region Weapons 690 | { id: 'sword', name: 'Weapon' }, 691 | { id: 'wand', name: 'Weapon' }, 692 | { id: 'shield', name: 'Weapon' }, 693 | { id: 'bardiche', name: 'Weapon \\ search filter for buffs' }, 694 | { id: 'crossbow', name: 'Weapon' }, 695 | { id: 'hammer', name: 'Weapon' }, 696 | { id: 'heavy hammer', name: 'Weapon' }, 697 | { id: 'staff', name: 'Weapon' }, 698 | { id: 'quarterstaff', name: 'Weapon' }, 699 | { id: 'staff',name: 'Weapon' }, 700 | { id: 'arm',name: 'Weapon' }, 701 | { id: 'blade', name: 'Weapon' }, 702 | { id: 'mask', name: 'Weapon' }, 703 | { id: 'mind stone',name: 'Weapon' }, 704 | { id: 'runestone',name: 'Weapon' }, 705 | { id: 'grappling hook',name: 'Weapon' }, 706 | { id: 'mind', name: 'Weapon' }, 707 | { id: 'stones', name: 'Weapon' }, 708 | { id: 'hatchet', name: 'Weapon' }, 709 | { id: 'shovel', name: 'Weapon' }, 710 | { id: 'grappling', name: 'Weapon' }, 711 | { id: 'moon', name: 'Weapon (moon stone) \n * Gives +5 attack speed when equipped' }, 712 | { id: 'mind', name: 'Weapon (mind stone) \n * Dodge backwards upon equipping. Cooldown 12 seconds' }, 713 | { id: 'triskelion', name: 'Weapon (triskelion stone) \n * +1 Movement speed when equipped' }, 714 | { id: 'fissure', name: 'Weapon (fissure stone) \n * Deals damage equial to half your health. Cooldown 18 seconds' }, 715 | { id: 'quest', name: 'Weapon (quest stone) \n * Gives [2] armor points when equipped, increases shield recovery rate' }, 716 | { id: 'ouroboros', name: 'Weapon (ouroboros stone) \n * Replayed locations loop around. Heal over time when equipped' }, 717 | { id: 'xp', name: 'Weapon (xp stone) \n * Bonus XP when equipped' }, 718 | { id: 'xi', name: 'Weapon (xi stone) \n * Bouss KI (@) when equipped' }, 719 | { id: 'star', name: 'Weapon (star stone) \n * Gathers nearby resources' }, 720 | { id: 'sight', name: 'Weapon (sight stone) \n * Reveals the nature of things' }, 721 | // #endregion 722 | // #region Search filters 723 | { id: 'poison', name: 'Search filter' }, 724 | { id: 'vigor', name: 'Search filter' }, 725 | { id: 'aether', name: 'Search filter' }, 726 | { id: 'fire', name: 'Search filter' }, 727 | { id: 'air', name: 'Search filter' }, 728 | { id: 'ice', name: 'Search filter' }, 729 | { id: 'arachnid', name: 'Search filter' }, 730 | { id: 'serpent', name: 'Search filter' }, 731 | { id: 'insect', name: 'Search filter' }, 732 | { id: 'machine', name: 'Search filter' }, 733 | { id: 'humanoid', name: 'Search filter' }, 734 | { id: 'elemental', name: 'Search filter' }, 735 | { id: 'boss', name: 'Search filter' }, 736 | { id: 'phase1', name: 'Search filter' }, 737 | { id: 'phase2', name: 'Search filter' }, 738 | { id: 'phase3', name: 'Search filter' }, 739 | { id: 'spawner', name: 'Search filter' }, 740 | { id: 'flying', name: 'Search filter' }, 741 | { id: 'slow', name: 'Search filter' }, 742 | { id: 'ranged', name: 'Search filter' }, 743 | { id: 'explode', name: 'Search filter' }, 744 | { id: 'swarm', name: 'Search filter' }, 745 | { id: 'unpushable undamageable', name: 'Search filter' }, 746 | { id: 'magic_resist', name: 'Search filter' }, 747 | { id: 'magic_vulnerability', name: 'Search filter' }, 748 | { id: 'immune_to_stun', name: 'Search filter' }, 749 | { id: 'immune_to_ranged', name: 'Search filter' }, 750 | { id: 'immune_to_debuff_damage', name: 'Search filter' }, 751 | { id: 'immune_to_physical', name: 'Search filter' }, 752 | { id: 'stone', name: 'Brewing resource \\ Search filter' }, 753 | { id: 'compound', name: 'Search filter for shield' }, 754 | { id: 'dashing', name: 'Search filter for shield' }, 755 | { id: 'bashing', name: 'Search filter for shield' }, 756 | { id: 'long', name: 'Search filter for sword' }, 757 | { id: 'heavy', name: 'Search filter for crossbow' }, 758 | { id: 'repeating', name: 'Search filter for crossbow' }, 759 | { id: 'socketed', name: 'Search filter for staff' }, 760 | { id: 'wood', name: 'Brewing resource' }, 761 | { id: 'tar', name: 'Brewing resource' }, 762 | { id: 'bronze', name: 'Brewing resource' }, 763 | { id: 'ki', name: 'Brewing resource' }, 764 | { id: 'potion', name: 'Search filter' }, 765 | { id: 'empty', name: 'Search filter for potion' }, 766 | // #endregion 767 | // #region De/Buffs search filters 768 | { id: 'protection', name: 'Search filter for foe buffs' }, 769 | { id: 'buff_protection', name: 'Search filter for foe buffs' }, 770 | { id: 'stun', name: 'Search filter for foe debuffs' }, 771 | { id: 'dot', name: 'Search filter for foe debuffs' }, 772 | { id: 'debuff_dot', name: 'Search filter for foe debuffs' }, 773 | { id: 'debuff_dot_2', name: 'Search filter for foe debuffs' }, 774 | { id: 'damage', name: 'Search filter for foe debuffs' }, 775 | { id: 'debuff_damage', name: 'Search filter for foe debuffs' }, 776 | { id: 'chill', name: 'Search filter for foe debuffs' }, 777 | { id: 'debuff_chill', name: 'Search filter for foe debuffs' }, 778 | { id: 'bardiche', name: 'Search filter for player buffs' }, 779 | { id: 'smite', name: 'Search filter for player buffs' }, 780 | { id: 'berserk', name: 'Search filter for player buffs' }, 781 | { id: 'crit', name: 'Search filter for player buffs' }, 782 | { id: 'lucky_crit', name: 'Search filter for player buffs' }, 783 | { id: 'mult', name: 'Search filter for player buffs' }, 784 | { id: 'lucky_mult', name: 'Search filter for player buffs' }, 785 | { id: 'strength', name: 'Search filter for player buffs' }, 786 | { id: 'invisibility', name: 'Search filter for player buffs' }, 787 | { id: 'vampiric', name: 'Search filter for player buffs' }, 788 | { id: 'experience', name: 'Search filter for player buffs' }, 789 | // #endregion 790 | // #region Key search filters 791 | { id: 'left', name: 'Search filter for key codes' }, 792 | { id: 'right', name: 'Search filter for key codes' }, 793 | { id: 'up', name: 'Search filter for key codes' }, 794 | { id: 'down', name: 'Search filter for key codes' }, 795 | { id: 'primary', name: 'Search filter for key codes' }, 796 | { id: 'back', name: 'Search filter for key codes' }, 797 | { id: 'ability1', name: 'Search filter for key codes' }, 798 | { id: 'ability2', name: 'Search filter for key codes' }, 799 | { id: 'bumpL', name: 'Search filter for key codes' }, 800 | { id: 'bumpR', name: 'Search filter for key codes' }, 801 | { id: 'leftBegin', name: 'Search filter for key codes' }, 802 | { id: 'rightBegin', name: 'Search filter for key codes' }, 803 | { id: 'upBegin', name: 'Search filter for key codes' }, 804 | { id: 'downBegin', name: 'Search filter for key codes' }, 805 | { id: 'primaryBegin', name: 'Search filter for key codes' }, 806 | { id: 'backBegin', name: 'Search filter for key codes' }, 807 | { id: 'ability1Begin', name: 'Search filter for key codes' }, 808 | { id: 'ability2Begin', name: 'Search filter for key codes' }, 809 | { id: 'bumpLBegin', name: 'Search filter for key codes' }, 810 | { id: 'bumpRBegin', name: 'Search filter for key codes' }, 811 | { id: 'leftEnd', name: 'Search filter for key codes' }, 812 | { id: 'rightEnd', name: 'Search filter for key codes' }, 813 | { id: 'upEnd', name: 'Search filter for key codes' }, 814 | { id: 'downEnd', name: 'Search filter for key codes' }, 815 | { id: 'primaryEnd', name: 'Search filter for key codes' }, 816 | { id: 'backEnd', name: 'Search filter for key codes' }, 817 | { id: 'ability1End', name: 'Search filter for key codes' }, 818 | { id: 'ability2End', name: 'Search filter for key codes' }, 819 | { id: 'bumpLEnd', name: 'Search filter for key codes' }, 820 | { id: 'bumpREnd', name: 'Search filter for key codes' }, 821 | { id: '←', name: 'Search filter for key codes' }, 822 | { id: '→', name: 'Search filter for key codes' }, 823 | { id: '↑', name: 'Search filter for key codes' }, 824 | { id: '↓', name: 'Search filter for key codes' }, 825 | { id: 'A', name: 'Search filter for key codes' }, 826 | { id: 'D', name: 'Search filter for key codes' }, 827 | { id: 'W', name: 'Search filter for key codes' }, 828 | { id: 'S', name: 'Search filter for key codes' }, 829 | { id: 'LMB', name: 'Search filter for key codes' }, 830 | { id: 'Return', name: 'Search filter for key codes' }, 831 | { id: 'X', name: 'Search filter for key codes' }, 832 | { id: 'Shift', name: 'Search filter for key codes' }, 833 | { id: 'Control', name: 'Search filter for key codes' }, 834 | { id: 'Z', name: 'Search filter for key codes' }, 835 | { id: 'C', name: 'Search filter for key codes' }, 836 | // #endregion 837 | // #region Locations 838 | { id: 'Rocky', name: 'Location (Rocky Plateau) \n * Stone resource (o) \n * Can drop any runes when the location level is greater than 5 (stars)' }, 839 | { id: 'Waterfall', name: 'Location (Deadwood waterfall)' }, 840 | { id: 'Deadwood', name: 'Location (Deadwood Canyon) \n * Wood resource (_/`)' }, 841 | { id: 'Caves', name: 'Location (Caves of Fear) \n * Tar resource (≈) \n * Drops poison runes (∞)\n * Enemies weak to Ice' }, 842 | { id: 'Mushroom', name: 'Location (Mushroom Forest) \n * Drops vigor runes (❤) \n * Enemies weak to Poison' }, 843 | { id: 'Halls', name: 'Location (Haunted Halls) \n * Drops Aether runes (\*) \n * Enemies weak to Vigor \n * Skeletons take double magic damage \n * Booos immune to physical damage' }, 844 | { id: 'Mine', name: 'Location (Boiling Mine) \n * Bronze resource (:.) \n * Drops fire runes (φ) \n * Enemies weak to Aether (\*)' }, 845 | { id: 'Ridge', name: 'Location (Icy Ridge) \n * Drops Ice runes (❄) \n * Enemies weak to Fire' }, 846 | { id: 'Temple', name: 'Location (Temple) \n * Drops poison runes (∞)' }, 847 | { id: 'Shop', name: 'Location (Hotspring Shop) \n * Here player can buy items and chests' }, 848 | { id: 'Gate', name: 'Location (Haunted Gate) \n * Here player can win a bone chest once per day' }, 849 | // Events 850 | { id: 'event.GetObjectiveId', name: '```stonescript\nevent.GetObjectiveId(int)\n```\n---\n * Returns information about active objectives in a community or seasonal event. Pass the index of the desired objective. Events are usually limited to a maximum of 3 active objectives, therefore the first parameter would be 0, 1 or 2' }, 851 | { id: 'event.GetObjectiveProgress', name: '```stonescript\nevent.GetObjectiveProgress(int)\n```\n---\n * Returns information about active objectives in a community or seasonal event. Pass the index of the desired objective. Events are usually limited to a maximum of 3 active objectives, therefore the first parameter would be 0, 1 or 2' }, 852 | { id: 'event.GetObjectiveGoal', name: '```stonescript\nevent.GetObjectiveGoal(int)\n```\n---\n * Returns information about active objectives in a community or seasonal event. Pass the index of the desired objective. Events are usually limited to a maximum of 3 active objectives, therefore the first parameter would be 0, 1 or 2' }, 853 | // #endregion 854 | // #region Enemies 855 | // 856 | { id: 'encounter.isElite', name: 'Tells you if the current encounter is an elite encounter or not' }, 857 | { id: 'encounter.eliteMod', name: 'Tells you the special modifier, if any, for the current encounter.' }, 858 | 859 | { id: 'target', name: 'Currently targeted enemy, waypoint or foe' }, 860 | { id: 'waypoint', name: 'Target search filter' }, 861 | // Rocky 862 | { id: 'acronian_scout', name: 'Enemy (Acronian Scout)' }, 863 | { id: 'Dysangelos', name: 'Enemy (Dysangelos, Bearer of Stones)' }, 864 | { id: 'dysangelos', name: 'Enemy (Dysangelos, Bearer of Stones)' }, 865 | { id: 'dysangelos_bearer', name: 'Enemy (Dysangelos, Bearer of Stones) \n * phase1' }, 866 | { id: 'dysangelos_elementalist', name: 'Enemy (One With the Elements) \n * phase2' }, 867 | { id: 'dysangelos_perfected', name: 'Enemy (Dysangelos Perfected) \n * phase3' }, 868 | // Deadwood 869 | { id: 'scarab', name: 'Enemy (Stone Scarab)' }, 870 | { id: 'flesh_scarab', name: 'Enemy (Stone Scarab)' }, 871 | { id: 'mosquito', name: 'Enemy (Huge Mosquito)' }, 872 | { id: 'huge_mosquito', name: 'Enemy (Huge Mosquito)' }, 873 | { id: 'wasp', name: 'Enemy (Wasp)' }, 874 | { id: 'wasp_nest', name: 'Enemy (Wasp Nest)' }, 875 | { id: 'Xyloalgia', name: 'Enemy (Xyloalgia, Residue of Leuce)' }, 876 | { id: 'tree_boss', name: 'Enemy (Xyloalgia, Residue of Leuce)' }, 877 | { id: 'Poena', name: 'Enemy (Poena) \n * phase1' }, 878 | { id: 'poena', name: 'Enemy (Poena) \n * phase1' }, 879 | // Caves 880 | { id: 'tiny_spider', name: 'Enemy (Nail Biter)' }, 881 | { id: 'small_spider', name: 'Enemy (Skin Peeler)' }, 882 | { id: 'spider_eggs', name: 'Enemy (Not Caviar)' }, 883 | { id: 'small_bat', name: 'Enemy (Wound Licker)' }, 884 | { id: 'medium_bat', name: 'Enemy (Neck Warmer)' }, 885 | { id: 'scorpion', name: 'Enemy (Knee Chopper)' }, 886 | { id: 'cool_bat', name: 'Enemy (Ceiling Decorator)' }, 887 | { id: 'Bolesh', name: 'Enemy (Bolesh, the Cunning)' }, 888 | { id: 'spider_boss', name: 'Enemy (Bolesh, the Cunning)' }, 889 | // Mushroom 890 | { id: 'ant', name: 'Enemy (Ant)' }, 891 | { id: 'ant_hill', name: 'Enemy (Ant Hill) \\ Sound effect' }, 892 | { id: 'epic_snail', name: 'Enemy (Big A** Snail)' }, 893 | { id: 'colossal_snail', name: 'Enemy (Huge Snail)' }, 894 | { id: 'fluff', name: 'Enemy (Mr. Puff)' }, 895 | { id: 'mushroom_boss', name: 'Enemy (Angry Shroom)' }, 896 | { id: 'mushroom_boss_fat', name: 'Enemy (Morel, the Sporeadic)' }, 897 | { id: 'mushroom_boss_skinny', name: 'Enemy (Enoki, Fungi to be with)' }, 898 | // Halls 899 | { id: 'ghost', name: 'Enemy (Booo)' }, 900 | { id: 'large_ghost', name: 'Enemy (Big Booo)' }, 901 | { id: 'ghost_tomb', name: 'Enemy (R.I.P.)' }, 902 | { id: 'small_skeleton', name: 'Enemy (Skeletimmy)' }, 903 | { id: 'large_skeleton', name: 'Enemy (Skeletony)' }, 904 | { id: 'ghost_tomb', name: 'Enemy (R.I.Pieces)' }, 905 | { id: 'Pallas', name: 'Enemy (Pallas, the Skinless)' }, 906 | { id: 'pallas', name: 'Enemy (Pallas, the Skinless)' }, 907 | { id: 'skeleton_boss', name: 'Enemy (Pallas, the Skinless)' }, 908 | { id: 'skeleton_boss_stage_2', name: 'Enemy (Pallas, the Skinless) \n * phase2' }, 909 | // Mine 910 | { id: 'mine_walker', name: 'Enemy (Mine walker)' }, 911 | { id: 'fire_elemental', name: 'Enemy (Fire elemental)' }, 912 | { id: 'flame_geyser', name: 'Enemy (Flame Geyser)' }, 913 | { id: 'slave_master', name: 'Enemy (Whip Controller)' }, 914 | { id: 'big_slave_master', name: 'Enemy (Dominotaur)' }, 915 | { id: 'bomb_cart', name: 'Enemy (Bomb Cart)' }, 916 | { id: 'bronze_guardian', name: 'Enemy (Bronze Guardian)' }, 917 | // Ridge 918 | { id: 'elite', name: 'Enemy (Elite Ice Elemental)' }, 919 | { id: 'ice_elemental_elite', name: 'Enemy (Elite Ice Elemental)' }, 920 | { id: 'pillar', name: 'Enemy (Ice Pillar)' }, 921 | { id: 'ice_pillar', name: 'Enemy (Ice Pillar) \\ Sound effect' }, 922 | { id: 'ki_eater', name: 'Enemy (Ki Eater)' }, 923 | { id: 'ki_slerper', name: 'Enemy (Ki Slurper)' }, 924 | { id: 'ki_globbler', name: 'Enemy (Ki Globbler)' }, 925 | { id: 'ice_elemental_elite', name: 'Enemy (Giant Ice Elemental)' }, 926 | { id: 'Hrimnir', name: 'Enemy (Hrimnir)' }, 927 | { id: 'yeti', name: 'Enemy (Hrimnir)' }, 928 | // Temple 929 | { id: 'slying_serpent', name: 'Enemy (Toupee Snatcher)' }, 930 | { id: 'ground_serpent', name: 'Enemy (Ground Serpent)' }, 931 | { id: 'worm_rider', name: 'Enemy (Worm Rider)' }, 932 | { id: 'cult_guard', name: 'Enemy (Cult Guard)' }, 933 | { id: 'cult_sorcerer', name: 'Enemy (Cult Sorcerer)' }, 934 | { id: 'cult_marksman', name: 'Enemy (Cult Marksman)' }, 935 | { id: 'heavy_hitter', name: 'Enemy (The Bell Ringer)' }, 936 | { id: 'poison_adept', name: 'Enemy (Poison Adept)' }, 937 | { id: 'acronian_cultist', name: 'Enemy (Acronian Cultist)' }, 938 | { id: 'Nagaraja', name: 'Enemy (Nagaraja, Eater of the Torch)' }, 939 | { id: 'nagaraja', name: 'Enemy (Nagaraja, Eater of the Torch)' }, 940 | // #endregion 941 | // #region Music 942 | // Boiling Mine 943 | { id: 'bronze_guardian_3', name: 'Sound effect (Music)' }, 944 | { id: 'bronze_guardian_4', name: 'Sound effect (Music)' }, 945 | { id: 'bronze_guardian_5', name: 'Sound effect (Music)' }, 946 | { id: 'bronze_guardian_cyan', name: 'Sound effect (Music)' }, 947 | { id: 'bronze_mine_0', name: 'Sound effect (Music)' }, 948 | { id: 'bronze_mine_1', name: 'Sound effect (Music)' }, 949 | { id: 'bronze_mine_2', name: 'Sound effect (Music)' }, 950 | { id: 'bronze_mine_3', name: 'Sound effect (Music)' }, 951 | { id: 'bronze_mine_4', name: 'Sound effect (Music)' }, 952 | { id: 'bronze_mine_5', name: 'Sound effect (Music)' }, 953 | { id: 'bronze_mine_cyan', name: 'Sound effect (Music)' }, 954 | { id: 'slave_outro_climb', name: 'Sound effect (Music)' }, 955 | { id: 'slave_outro_loop', name: 'Sound effect (Music)' }, 956 | // Caves of Fear 957 | { id: 'caustic_caves', name: 'Sound effect (Music)' }, 958 | { id: 'spider_boss', name: 'Sound effect (Music)' }, 959 | // Deadwood 960 | { id: 'cross_deadwood_river', name: 'Sound effect (Music)' }, 961 | { id: 'cross_deadwood_wind', name: 'Sound effect (Music)' }, 962 | { id: 'deadwood_0', name: 'Sound effect (Music)' }, 963 | { id: 'deadwood_1', name: 'Sound effect (Music)' }, 964 | { id: 'deadwood_2', name: 'Sound effect (Music)' }, 965 | { id: 'deadwood_3', name: 'Sound effect (Music)' }, 966 | { id: 'deadwood_4', name: 'Sound effect (Music)' }, 967 | { id: 'deadwood_5', name: 'Sound effect (Music)' }, 968 | { id: 'deadwood_cyan', name: 'Sound effect (Music)' }, 969 | { id: 'tree_boss', name: 'Sound effect (Music)' }, 970 | { id: 'waterfall_descent', name: 'Sound effect (Music)' }, 971 | // Haunted Halls 972 | { id: 'skeleton_boss', name: 'Sound effect (Music)' }, 973 | { id: 'undead_crypt_0', name: 'Sound effect (Music)' }, 974 | { id: 'undead_crypt_1', name: 'Sound effect (Music)' }, 975 | { id: 'undead_crypt_2', name: 'Sound effect (Music)' }, 976 | { id: 'undead_crypt_3', name: 'Sound effect (Music)' }, 977 | { id: 'undead_crypt_4', name: 'Sound effect (Music)' }, 978 | { id: 'undead_crypt_5', name: 'Sound effect (Music)' }, 979 | { id: 'undead_crypt_cyan', name: 'Sound effect (Music)' }, 980 | { id: 'undead_crypt_intro', name: 'Sound effect (Music)' }, 981 | // Icy Ridge 982 | { id: 'bridge_broken', name: 'Sound effect (Music)' }, 983 | { id: 'bridge_crossing', name: 'Sound effect (Music)' }, 984 | { id: 'icy_ridge_0', name: 'Sound effect (Music)' }, 985 | { id: 'icy_ridge_1', name: 'Sound effect (Music)' }, 986 | { id: 'icy_ridge_2', name: 'Sound effect (Music)' }, 987 | { id: 'icy_ridge_3', name: 'Sound effect (Music)' }, 988 | { id: 'icy_ridge_4', name: 'Sound effect (Music)' }, 989 | { id: 'icy_ridge_5', name: 'Sound effect (Music)' }, 990 | { id: 'icy_ridge_cyan', name: 'Sound effect (Music)' }, 991 | { id: 'yeti', name: 'Sound effect (Music)' }, 992 | // Mushroom Forest 993 | { id: 'fire_loop', name: 'Sound effect (Music)' }, 994 | { id: 'fungus_forest_0', name: 'Sound effect (Music)' }, 995 | { id: 'fungus_forest_1', name: 'Sound effect (Music)' }, 996 | { id: 'fungus_forest_2', name: 'Sound effect (Music)' }, 997 | { id: 'fungus_forest_3', name: 'Sound effect (Music)' }, 998 | { id: 'fungus_forest_4', name: 'Sound effect (Music)' }, 999 | { id: 'fungus_forest_5', name: 'Sound effect (Music)' }, 1000 | { id: 'fungus_forest_cyan', name: 'Sound effect (Music)' }, 1001 | { id: 'mushroom_boss', name: 'Sound effect (Music)' }, 1002 | { id: 'mushroom_boss_cyan', name: 'Sound effect (Music)' }, 1003 | { id: 'shop', name: 'Sound effect (Music)' }, 1004 | // Rocky Plateau 1005 | { id: 'rocky_plateau_0', name: 'Sound effect (Music)' }, 1006 | { id: 'rocky_plateau_1', name: 'Sound effect (Music)' }, 1007 | { id: 'rocky_plateau_2', name: 'Sound effect (Music)' }, 1008 | { id: 'rocky_plateau_3', name: 'Sound effect (Music)' }, 1009 | { id: 'rocky_plateau_4', name: 'Sound effect (Music)' }, 1010 | { id: 'rocky_plateau_5', name: 'Sound effect (Music)' }, 1011 | { id: 'rocky_plateau_epilogue', name: 'Sound effect (Music)' }, 1012 | { id: 'rocky_plateau_fight', name: 'Sound effect (Music)' }, 1013 | { id: 'rocky_plateau_talk', name: 'Sound effect (Music)' }, 1014 | // Temple 1015 | { id: 'nagaraja', name: 'Sound effect (Music)' }, 1016 | { id: 'temple_0', name: 'Sound effect (Music)' }, 1017 | { id: 'temple_1', name: 'Sound effect (Music)' }, 1018 | { id: 'temple_2', name: 'Sound effect (Music)' }, 1019 | { id: 'temple_3', name: 'Sound effect (Music)' }, 1020 | { id: 'temple_4', name: 'Sound effect (Music)' }, 1021 | { id: 'temple_5', name: 'Sound effect (Music)' }, 1022 | { id: 'temple_cyan', name: 'Sound effect (Music)' }, 1023 | // Events 1024 | { id: 'event_fall', name: 'Sound effect (Music)' }, 1025 | { id: 'event_hamartia', name: 'Sound effect (Music)' }, 1026 | { id: 'event_spring', name: 'Sound effect (Music)' }, 1027 | { id: 'event_stonejam', name: 'Sound effect (Music)' }, 1028 | { id: 'event_summer', name: 'Sound effect (Music)' }, 1029 | { id: 'event_winter', name: 'Sound effect (Music)' }, 1030 | // Other 1031 | { id: 'credits', name: 'Sound effect (Music)' }, 1032 | { id: 'main_menu', name: 'Sound effect (Music)' }, 1033 | { id: 'bone_factory', name: 'Sound effect (Music)' }, 1034 | { id: 'osteophone', name: 'Sound effect (Music)' }, 1035 | { id: 'uulaa', name: 'Sound effect (Music)' }, 1036 | // #endregion 1037 | // #region Ambient 1038 | { id: 'ambient_mines', name: 'Sound effect (Ambient)' }, 1039 | { id: 'ambient_caves', name: 'Sound effect (Ambient)' }, 1040 | { id: 'ambient_bronze_gate', name: 'Sound effect (Ambient)' }, 1041 | { id: 'ambient_deadwood', name: 'Sound effect (Ambient)' }, 1042 | { id: 'ambient_mushroom', name: 'Sound effect (Ambient)' }, 1043 | { id: 'ambient_bridge', name: 'Sound effect (Ambient)' }, 1044 | { id: 'ambient_icy', name: 'Sound effect (Ambient)' }, 1045 | { id: 'ambient_cave', name: 'Sound effect (Ambient)' }, 1046 | { id: 'ambient_rocky', name: 'Sound effect (Ambient)' }, 1047 | { id: 'ambient_temple', name: 'Sound effect (Ambient)' }, 1048 | { id: 'ambient_crypt', name: 'Sound effect (Ambient)' }, 1049 | { id: 'ambient_haunted_gate', name: 'Sound effect (Ambient)' }, 1050 | { id: 'ambient_pallas', name: 'Sound effect (Ambient)' }, 1051 | { id: 'waterfall_a', name: 'Sound effect (Ambient)' }, 1052 | { id: 'waterfall_b', name: 'Sound effect (Ambient)' }, 1053 | { id: 'waterfall_c', name: 'Sound effect (Ambient)' }, 1054 | // #endregion 1055 | // #region Component values 1056 | { id: '.absoluteX', name: '```stonescript\n\n```\n---\n * The component\'s position relative to the screen' }, 1057 | { id: '.absoluteY', name: '```stonescript\ncomponent.absoluteY\n```\n---\n * The component\'s position relative to the screen' }, 1058 | { id: '.anchor', name: '```stonescript\ncomponent.anchor\n```\n---\n * Auto-layout property representing the internal pivot of the component. This guides the UI system on how to position the component relative to itself. Default value is "center_center". Possible values: top_left, top_center, top_right, center_left, center_center, center_right, bottom_left, bottom_center and bottom_right' }, 1059 | { id: '.dock', name: '```stonescript\ncomponent.dock\n```\n---\n * Auto-layout property similar to anchor. However, dock represents the external pivot, or position inside the parent where to position the component. If in doubt, use the same value for both anchor and dock, which is the most common situation' }, 1060 | { id: '.ax', name: '```stonescript\ncomponent.ax\n```\n---\n * The X part of the anchor. Possible values: left, center and right' }, 1061 | { id: '.ay', name: '```stonescript\ncomponent.ay\n```\n---\n * The Y part of the anchor. Possible values: top, center and bottom' }, 1062 | { id: '.dx', name: '```stonescript\ncomponent.dx\n```\n---\n * The X part of the dock. Possible values: left, center and right' }, 1063 | { id: '.dy', name: '```stonescript\ncomponent.dy\n```\n---\n * The Y part of the dock. Possible values: top, center and bottom' }, 1064 | { id: '.parent', name: '```stonescript\ncomponent.parent\n```\n---\n * Reference to the component\'s parent Panel. May refer to the root Panel if the component was created but never added to another Panel. When panel.Add(component) is called the component\'s parent changes' }, 1065 | { id: '.visible', name: '```stonescript\ncomponent.visible\n```\n---\n * Visibility of the component. Default value is "inherit". Possible values: true, false and inherit. If set to \'true\', the component will always be visible, ignoring the status of its parent. If set to \'false\', the component will be invisible, regardless of its parent. However, if set to \'inherit\', the component will follow the visibility of its parent' }, 1066 | { id: '.Recycle', name: '```stonescript\component.nRecycle()\n```\n---\n * Removes the component from its parent Panel. It will be repurposed in future ui.Add_() calls. Any variable references to the recycled element should be nulled or reassigned to avoid bugs' }, 1067 | // #endregion 1068 | // #region Panel values 1069 | { id: '.children', name: '```stonescript\npanel.children\n```\n---\n * Array with all the child components that have been added to the Panel with panel.Add()' }, 1070 | { id: '.clip', name: '```stonescript\npanel.clip\n```\n---\n * Indicates if the bounds of Panel should be used to contrain the drawing of child components. If true, parts of child components that fall outside of the Panel\'s bounds will not draw' }, 1071 | { id: '.color', name: '```stonescript\ncomponent.color\n```\n---\n * The component color, in RGB hexadecimal format' }, 1072 | { id: '.style', name: '```stonescript\ncomponent.style\n```\n---\n * ID number of the Component\'s current style. Default value is 1. Possible values from -8 to 8. Additional styles can be added with ui.AddStyle()' }, 1073 | { id: '.Add', name: '```stonescript\npanel.Add(Component, [int])\n```\n---\n * Adds a Component to a Panel. The Component becomes a child of the Panel and the Panel becomes the parent of the Component. The order in which elements are added to a Panel affects the draw order. Components may be inserted to a specific sorting position by use of the optional integer parameter. No integer parameter means the Component is added as the last child of the Panel. This function can also be used for changing the draw order of Components that are already children of the Panel' }, 1074 | { id: '.Clear', name: '```stonescript\npanel.Clear()\n```\n---\n * Removes all UI elements from the Panel. Components removed this way are recycled into the UI system and will be repurposed in future ui.Add_() calls. Any variable references to those elements should be nulled or reassigned to avoid bugs' }, 1075 | { id: '.Remove', name: '```stonescript\npanel.Remove(Component / int)\n```\n---\n * Removes a specific Component from a Panel or removes the Component at a specified index number. Components removed this way are recycled into the UI system and will be repurposed in future ui.Add_() calls. Any variable references to those elements should be nulled or reassigned to avoid bugs' }, 1076 | // #endregion 1077 | // #region BigNumber 1078 | { id: '.Add', name: '```stonescript\nBigNumber.Add(num / BigNumber)\n```\n---\n * Adds a number to a BigNumber (+)' }, 1079 | { id: '.Sub', name: '```stonescript\nBigNumber.Sub(num / BigNumber)\n```\n---\n * Subtracts a number from a BigNumber (-)' }, 1080 | { id: '.Mul', name: '```stonescript\nBigNumber.Mul(num / BigNumber)\n```\n---\n * Multiplies a BigNumber by a number (*)' }, 1081 | { id: '.Div', name: '```stonescript\nBigNumber.Div(num / BigNumber)\n```\n---\n * Divides a BigNumber by a number (/)' }, 1082 | { id: '.Eq', name: '```stonescript\nBigNumber.Eq(num / BigNumber)\n```\n---\n * Determines if a BigNumber is equal to a number (=)' }, 1083 | { id: '.Gt', name: '```stonescript\nBigNumber.(nGtum / BigNumber)\n```\n---\n * Determines if a BigNumber is greater than a number (>)' }, 1084 | { id: '.Ge', name: '```stonescript\nBigNumber.Ge(num / BigNumber)\n```\n---\n * Determines if a BigNumber is greater than or equal to a number (>=)' }, 1085 | { id: '.Lt', name: '```stonescript\nBigNumber.Lt(num / BigNumber)\n```\n---\n * Determines if a BigNumber is less than a number (<)' }, 1086 | { id: '.Le', name: '```stonescript\nBigNumber.Le(num / BigNumber)\n```\n---\n * Determines if a BigNumber is less than or equal to a number (<=)' }, 1087 | { id: '.ToString', name: '```stonescript\nBigNumber.ToString()\n```\n---\n * Returns a string representation of the BigNumber. Can be used to serialize it for storage.' }, 1088 | { id: '.ToInt', name: '```stonescript\nBigNumber.ToInt()\n```\n---\n * Converts a big number to integer value. Throws error if the number is too large or too small.' }, 1089 | { id: '.ToFloat', name: '```stonescript\nBigNumber.ToFloat()\n```\n---\n * Converts a big number to float value. Throws error if the number is too large or too small.' }, 1090 | { id: '.ToUI', name: '```stonescript\nBigNumber.ToUI()\n```\n---\n * Returns a shortened string representation of the number for use in user interfaces.' }, 1091 | // #endregion 1092 | // #region Text values 1093 | { id: '.align', name: '```stonescript\ntext.align\n```\n---\n * The alignment/justification of the text inside the box. Default value is "left". Possible values: left, center and right' }, 1094 | { id: '.lines', name: '```stonescript\ntext.lines\n```\n---\n * Array of strings that are the broken-down lines of text after the Text box has formatted its contents. Excludes color metadata' }, 1095 | { id: '.text', name: '```stonescript\ntext.text\n```\n---\n * The full contents of the Text box. A subsection of the text may be colored with the metadata [color=#rrggbb][/color]' }, 1096 | // #endregion 1097 | // #region Button values 1098 | { id: '.tcolor', name: '```stonescript\nbutton.tcolor\n```\n---\n * The color of the text inside the button, in RGB hexadecimal format' }, 1099 | { id: '.bcolor', name: '```stonescript\nbutton.bcolor\n```\n---\n * The color of the button\'s border, in RGB hexadecimal format' }, 1100 | { id: '.hcolor', name: '```stonescript\nbutton.hcolor\n```\n---\n * The color of the button\'s highlight when it\'s pressed, in RGB hexadecimal format' }, 1101 | { id: '.sound', name: '```stonescript\nbutton.\n```\n---\n * The sound effect that plays when the button is pressed. Default is "confirm"' }, 1102 | { id: '.SetPressed', name: '```stonescript\nbutton.SetPressed(f)\n```\n---\n * Assigns a function to be called when the button is pressed. The function can have any number of parameters (even no parameters). When the function is called, the first parameter will be a reference to the button itself' }, 1103 | { id: '.SetDown', name: '```stonescript\nbutton.SetDown(f)\n```\n---\n * Similar to .SetPressed(), .SetDown() assigns a function to be called when the button press begins (first user contact)' }, 1104 | { id: '.SetUp', name: '```stonescript\nbutton.SetUp(f)\n```\n---\n * Similar to .SetPressed(), .SetUp() assigns a function to be called when a depress ends on top of the button (last user contact)' }, 1105 | // #endregion 1106 | // #region Anim values 1107 | { id: '.duration', name: '```stonescript\nanim.duratoin\n```\n---\n * Time length of the animation, in frames' }, 1108 | { id: '.flipX', name: '```stonescript\nanim.flipX\n```\n---\n * If true, flips the art horizontally, over its pivot' }, 1109 | { id: '.flipY', name: '```stonescript\nanim.flipY\n```\n---\n * If true, flips the art vertically, over its pivot' }, 1110 | { id: '.frame', name: '```stonescript\nanim.frame\n```\n---\n * Current animation frame being drawn. Can be changed to set an animation to a specific frame' }, 1111 | { id: '.gamePause', name: '```stonescript\nanim.gamePause\n```\n---\n * If true, the animation automatically pauses playback if the player pauses the game and resumes playback if the player exits the pause screen' }, 1112 | { id: '.loop', name: '```stonescript\nanim.loop\n```\n---\n * If true, the animation will restart from the begining as soon as it reaches the end of its duration' }, 1113 | { id: '.playing', name: '```stonescript\nanim.playing\n```\n---\n * True if the animation is currently playing' }, 1114 | { id: '.paused', name: '```stonescript\nanim.paused\n```\n---\n * True if the animatino is playing, but has been paused with a call to anim.Pause()' }, 1115 | { id: '.pivotX', name: '```stonescript\nanim.pivotX\n```\n---\n * Additional pivot offset that can be used for fine-tuning where the ASCII-art draws in relationship to its position' }, 1116 | { id: '.pivotY', name: '```stonescript\nanim.pivotY\n```\n---\n * Additional pivot offset that can be used for fine-tuning where the ASCII-art draws in relationship to its position' }, 1117 | { id: '.playOnStart', name: '```stonescript\nanim.playOnStart\n```\n---\n * If true, the animation will begin playing as soon as possible' }, 1118 | { id: '.Load', name: '```stonescript\nanim.Load(str)\n```\n---\n * Assigns a new ASCII sprite sheet' }, 1119 | { id: '.Pause', name: '```stonescript\nanim.Pause()\n```\n---\n * Suspends playback of the animation at its current frame. A subsequent call to anim.Play() resumes playback' }, 1120 | { id: '.Play', name: '```stonescript\nanim.Play()\n```\n---\n * Begins playing the animation, or resumes playback in case it had been paused' }, 1121 | { id: '.Stop', name: '```stonescript\nanim.Stop()\n```\n---\n * Suspends playback and sets the animation back to its first frame' }, 1122 | // #endregion 1123 | // #region Canvas values 1124 | { id: '.blend', name: '```stonescript\ncanvas.blend\n```\n---\n * The blend mode of the canvas, when composed with elements behind it. Possible values: Opaque, Multiply, Divide, Add, Subtract. Default value is "opaque"' }, 1125 | { id: '.Get', name: '```stonescript\ncanvas.Get(int, int)\n```\n---\n * Returns the glyph at a specific position x, y on the canvas' }, 1126 | { id: '.Set', name: '```stonescript\ncanvas.Set(str | int, int, [fg], [bg], str)\n```\n---\n * Overloads for changing a canvas at a specific position, while simultaneously setting the foreground and background colors' }, 1127 | { id: '.SetFG', name: '```stonescript\ncanvas.SetFG([int], [int], color)\n```\n---\n * Changes the foreground color at a specific position x,y' }, 1128 | { id: '.SetBG', name: '```stonescript\ncanvas.SetBG([int], [int], color)\n```\n---\n * Changes the background color at a specific position x,y' }, 1129 | // #endregion 1130 | // #region Array values 1131 | { id: '.Add', name: '```stonescript\na.Add(value)\n```\n---\n * Adds a new value/object to the end of the array' }, 1132 | { id: '.Clear', name: '```stonescript\na.Clear()\n```\n---\n * Removes all elements from the array, making it empty. This is more efficient than re-declaring the array with []' }, 1133 | { id: '.Contains', name: '```stonescript\na.Contains(value)\n```\n---\n * Determines if a given value is inside the array. Returns true if found; false otherwise' }, 1134 | { id: '.Count', name: '```stonescript\na.Count()\n```\n---\n * Returns the number of elements in the array' }, 1135 | { id: '.Emplace', name: '```stonescript\na.Emplace(int, value)\n```\n---\n * Replaces the value at a given position with a new value' }, 1136 | { id: '.IndexOf', name: '```stonescript\na.IndexOf(value)\n```\n---\n * Searches for a given value inside the array. Returns an integer indicating the position of the first occurrance of the value. If the value is not found returns -1' }, 1137 | { id: '.Insert', name: '```stonescript\na.Insert(int, value)\n```\n---\n * Adds a new value/object to a specific position of the array. Elements to the right are shifted to the next position' }, 1138 | { id: '.RemoveAt', name: '```stonescript\na.RemoveAt(int)\n```\n---\n * Removes an element in the array from a specific position. Returns the value removed. \n * Zero-based: myArray.RemoveAt(0) removes the first element. \n * Elements to the right are shifted to the previous position' }, 1139 | { id: '.Sort', name: '```stonescript\na.Sort()\n```\n---\n * Organizes the array\'s elements into ascending order. If the array contains objects of different types it will still be sorted, but no expected results are defined and elements are not guaranteed to be grouped by type' }, 1140 | // #endregion 1141 | // { id: '', name: '```stonescript\n ... \n```\n---\n * ' }, 1142 | // { id: '', 1143 | ] 1144 | 1145 | for (let index = 0; index < list.length; index++) { 1146 | const item = list[index] 1147 | if (item.id == word) { return new vscode.Hover(item.name) } 1148 | 1149 | if (item.id.includes('.')) { 1150 | let arr = item.id.split('.') 1151 | let len = arr[0].length + 1 1152 | if (arr[1] == word) { 1153 | let index = line.text.indexOf(item.id, wordposition.start.character - len) 1154 | if (index > -1) { 1155 | return new vscode.Hover(item.name) 1156 | } 1157 | } 1158 | } 1159 | 1160 | if (item.id.includes(' ')) { 1161 | let arr = item.id.split(' ') 1162 | let len = arr[0].length + 1 1163 | if (arr[1] == word) { 1164 | let index = line.text.indexOf(item.id, wordposition.start.character - len) 1165 | if (index > -1) { 1166 | return new vscode.Hover(item.name) 1167 | } 1168 | } 1169 | } 1170 | } 1171 | } 1172 | 1173 | module.exports = function (context) { 1174 | context.subscriptions.push( 1175 | vscode.languages.registerHoverProvider('stonescript', { 1176 | provideHover 1177 | }) 1178 | ) 1179 | } 1180 | -------------------------------------------------------------------------------- /src/util.js: -------------------------------------------------------------------------------- 1 | const fs = require('fs'); 2 | const os = require('os'); 3 | const path = require('path'); 4 | const vscode = require('vscode'); 5 | const exec = require('child_process').exec; 6 | 7 | const util = { 8 | /** 9 | * getProjectPath(uri) 10 | * getProjectPath(document) 11 | * getProjectPath() 12 | * @param {*} document 13 | */ 14 | getProjectPath(document) { 15 | if (!document) { 16 | document = vscode.window.activeTextEditor ? vscode.window.activeTextEditor.document : null; 17 | } 18 | if (!document) { 19 | this.showError('no doc'); 20 | return ''; 21 | } 22 | const currentFile = (document.uri ? document.uri : document).fsPath; 23 | let projectPath = null; 24 | 25 | let workspaceFolders = vscode.workspace.workspaceFolders.map(item => item.uri.path); 26 | if (workspaceFolders.length == 1 && workspaceFolders[0] === vscode.workspace.rootPath) { 27 | const rootPath = workspaceFolders[0]; 28 | var files = fs.readdirSync(rootPath); 29 | workspaceFolders = files.filter(name => !/^\./g.test(name)).map(name => path.resolve(rootPath, name)); 30 | // return vscode.workspace.rootPath + '/' + this._getProjectName(vscode, document); 31 | } 32 | workspaceFolders.forEach(folder => { 33 | if (currentFile.indexOf(folder) === 0) { 34 | projectPath = folder; 35 | } 36 | }) 37 | if (!projectPath) { 38 | this.showError('Path error'); 39 | return ''; 40 | } 41 | return projectPath; 42 | }, 43 | getProjectName: function(projectPath) { 44 | return path.basename(projectPath); 45 | }, 46 | getPluginPath() { 47 | }, 48 | /** 49 | * @param {*} word 50 | */ 51 | upperFirstLetter: function(word) { 52 | return (word || '').replace(/^\w/, m => m.toUpperCase()); 53 | }, 54 | /** 55 | * @param {*} word 56 | */ 57 | lowerFirstLeter: function(word) { 58 | return (word || '').replace(/^\w/, m => m.toLowerCase()); 59 | }, 60 | log: function(...args) { 61 | console.log(...args); 62 | }, 63 | error: function(...args) { 64 | console.error(...args); 65 | }, 66 | showError: function(info) { 67 | vscode.window.showErrorMessage(info); 68 | }, 69 | showInfo: function(info) { 70 | vscode.window.showInformationMessage(info); 71 | }, 72 | findStrInFolder: function(folderPath, str) { 73 | }, 74 | /** 75 | * @param filePath 76 | * @param reg 77 | */ 78 | findStrInFile: function(filePath, reg) { 79 | const content = fs.readFileSync(filePath, 'utf-8'); 80 | reg = typeof reg === 'string' ? new RegExp(reg, 'm') : reg; 81 | if (content.search(reg) < 0) return {row: 0, col: 0}; 82 | const rows = content.split(os.EOL); 83 | for(let i = 0; i < rows.length; i++) { 84 | let col = rows[i].search(reg); 85 | if(col >= 0) { 86 | return {row: i, col}; 87 | } 88 | } 89 | return {row: 0, col: 0}; 90 | }, 91 | getStrRangeInFile: function(filePath, str) { 92 | var pos = this.findStrInFile(filePath, str); 93 | return new vscode.Range(new vscode.Position(pos.row, pos.col), new vscode.Position(pos.row, pos.col + str.length)); 94 | }, 95 | checkVersion: function(version1, version2) { 96 | version1 = parseInt(version1.replace(/\./g, '')); 97 | version2 = parseInt(version2.replace(/\./g, '')); 98 | return version1 > version2; 99 | }, 100 | /** 101 | * @param context 102 | * @param relativePath 103 | */ 104 | getExtensionFileAbsolutePath: function(context, relativePath) { 105 | return path.join(context.extensionPath, relativePath); 106 | }, 107 | /** 108 | * @param context 109 | * @param relativePath 110 | */ 111 | getExtensionFileVscodeResource: function(context, relativePath) { 112 | const diskPath = vscode.Uri.file(path.join(context.extensionPath, relativePath)); 113 | return diskPath.with({ scheme: 'vscode-resource' }).toString(); 114 | }, 115 | openFileInFinder: function(filePath) { 116 | if (!fs.existsSync(filePath)) { 117 | this.showError('filePath: ' + filePath); 118 | } 119 | if (fs.statSync(filePath).isDirectory()) { 120 | exec(`open ${filePath}`); 121 | } else { 122 | const fileName = path.basename(filePath); 123 | filePath = path.dirname(filePath); 124 | exec(`open ${filePath}`); 125 | } 126 | }, 127 | /** 128 | * @param {*} path 129 | * @param {*} text 130 | */ 131 | openFileInVscode: function(path, text) { 132 | let options = undefined; 133 | if (text) { 134 | const selection = this.getStrRangeInFile(path, text); 135 | options = { selection }; 136 | } 137 | vscode.window.showTextDocument(vscode.Uri.file(path), options); 138 | }, 139 | openJarByJdGui: function(jarPath) { 140 | const jdGuiPath = vscode.workspace.getConfiguration().get('eggHelper.jdGuiPath'); 141 | if (!jdGuiPath) { 142 | this.showError('JD-GUI err'); 143 | return; 144 | } 145 | if (!fs.existsSync(jdGuiPath)) { 146 | this.showError('JD-GUI err'); 147 | return; 148 | } 149 | if (!fs.existsSync(jarPath)) { 150 | this.showError('jar: ' + jarPath); 151 | return; 152 | } 153 | exec(`open ${jarPath} -a ${jdGuiPath}`); 154 | }, 155 | openUrlInBrowser: function(url) { 156 | exec(`open '${url}'`); 157 | }, 158 | /** 159 | * @param {*} absolutePath 160 | */ 161 | clearRequireCache(absolutePath) { 162 | const root = require.cache[absolutePath]; 163 | if (!root) return; 164 | if (root.children) { 165 | root.children.forEach(item => { 166 | this.clearRequireCache(item.id); 167 | }); 168 | } 169 | delete require.cache[absolutePath]; 170 | }, 171 | /** 172 | * @param {*} modulePath 173 | */ 174 | dynamicRequire(modulePath) { 175 | this.clearRequireCache(modulePath); 176 | return require(modulePath); 177 | }, 178 | /** 179 | * @param {*} filePath 180 | */ 181 | readProperties(filePath) { 182 | const content = fs.readFileSync(filePath, 'utf-8'); 183 | let rows = content.split(os.EOL); 184 | rows = rows.filter(row => row && row.trim() && !/^#/.test(row)); 185 | const result = {}; 186 | rows.forEach(row => { 187 | let temp = row.split('='); 188 | result[temp[0].trim()] = temp[1].trim(); 189 | }); 190 | return result; 191 | }, 192 | /** 193 | * @param {*} obj1 194 | * @param {*} obj2 195 | */ 196 | jsonEquals(obj1, obj2) { 197 | let s1 = this.formatToSpecialJSON(obj1, '', true); 198 | let s2 = this.formatToSpecialJSON(obj2, '', true); 199 | return s1 === s2; 200 | } 201 | }; 202 | 203 | module.exports = util; -------------------------------------------------------------------------------- /syntaxes/stonescript.tmLanguage.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://raw.githubusercontent.com/martinring/tmlanguage/master/tmlanguage.json", 3 | "name": "Stonescript", 4 | "scopeName": "source.txt", 5 | "patterns": [ 6 | { "include": "#comments" }, 7 | { "include": "#strings" }, 8 | { "include": "#sounds"}, 9 | { "include": "#variables" }, 10 | { "include": "#functions" }, 11 | { "include": "#keywords" }, 12 | { "include": "#operators" }, 13 | { "include": "#control" }, 14 | { "include": "#classes" }, 15 | { "include": "#links" }, 16 | { "include": "#colors" }, 17 | { "include": "#constants" }, 18 | { "include": "#ascii" } 19 | ], 20 | "repository": { 21 | "links":{ 22 | "name": "variable.stonescript", 23 | "begin": "(@)", 24 | "beginCaptures": { "1": { "name": "keyword.control.stonescript" } }, 25 | "end": "(@)", 26 | "endCaptures": { "1": { "name": "keyword.control.stonescript" } }, 27 | "patterns": [ 28 | { "include": "#comments" }, 29 | { "include": "#strings" }, 30 | { "include": "#sounds"}, 31 | { "include": "#variables" }, 32 | { "include": "#functions" }, 33 | { "include": "#keywords" }, 34 | { "include": "#operators" }, 35 | { "include": "#control" }, 36 | { "include": "#classes" }, 37 | { "include": "#links" }, 38 | { "include": "#colors" }, 39 | { "include": "#constants" }, 40 | { "include": "#ascii" } 41 | ] 42 | }, 43 | "ascii": { 44 | "begin": "\\b(ascii)\\b", 45 | "beginCaptures": { "1": { "name": "keyword.control.stonescript" } }, 46 | "end": "\\b(asciiend)\\b", 47 | "endCaptures": { "1": { "name": "keyword.control.stonescript" } }, 48 | "patterns": [ 49 | { "include": "#links" }, 50 | { "match": "(@.+?@)|(.+?)", 51 | "captures": { 52 | "2": {"name": "string.other.stonescript"} 53 | } 54 | } 55 | ] 56 | }, 57 | "comments": { 58 | "patterns": [ 59 | { 60 | "name": "comment.line.double-slash.stonescript", 61 | "begin": "//", 62 | "end": "\n" 63 | }, 64 | { 65 | "name": "comment.block.stonescript", 66 | "begin": "/\\*", 67 | "end": "\\*/" 68 | } 69 | ] 70 | }, 71 | "variables": { 72 | "patterns": [ 73 | { 74 | "match": "this", 75 | "name": "variable.language.this.stonescript" 76 | }, 77 | { 78 | "match": "(?|\\<|\\>=|\\<=|\\=|\\(|\\)|,|\\+|\\-)", 87 | "name": "keyword.operator.stonescript" 88 | }, 89 | { 90 | "match": "\\b((?<=\\w)\\s?(\\+\\+|--|\\*\\*))", 91 | "name": "keyword.operator.stonescript" 92 | }, 93 | { 94 | "match": "([\\x{0021}\\x{003d}\\+\\-\\*\\+\\x{0025}\\x{002f}\\[\\]\\{\\}\\(\\)\\x{002c}\\.\\|\\x{0026}\\x{003e}\\x{003c}])", 95 | "name": "keyword.operator.stonescript" 96 | } 97 | ] 98 | }, 99 | "sounds": { 100 | "patterns": [ 101 | { 102 | "match": "(?<=^ *play *)\\b(buy|click|confirm|soul_stone|sword_cast|sword_hit|wand_cast|wand_hit|player_kick|player_punch|stone_throw_cast|stone_throw_hit|grappling_cast|grappling_hit|grappling_idle|hatchet_cast|hatchet_hit|shovel_cast|torch_cast|torch_hit|torch_idle|pickup_stone|pickup_wood|pickup_tar|pickup_success|soul_stone_drop|wand_drop|key_drop|cross_deadwood_bump|cross_deadwood_row|cross_deadwood_splash|ui_starfirst|ui_starnew|ui_starold1|ui_starold2|ui_starold3|ui_starold4|bronze_gate_open|prompt_choice|waterfall_hook_hit|waterfall_splash|haunted_gate_key_bounce_1|haunted_gate_key_bounce_2|haunted_gate_key_bounce_3|haunted_gate_opening|haunted_gate_point_lost|haunted_gate_key_into_gate|haunted_gate_shuffle|haunted_gate_shuffle_fast|haunted_gate_torch_off|haunted_gate_torch_on|haunted_gate_try_to_open|paint_splat|waterfall_land|waterfall_rope_grab|waterfall_rope_swing|skeleton_boss_death|skeleton_boss_legs_die|spider_boss_death|tree_boss_death|mushroom_boss_death|tree_boss_attack|tree_boss_awake|tree_boss_idle|tree_boss_spike|spider_boss_attack|player_hit|mushroom_boss_awake|mushroom_boss_punch|mushroom_boss_shoot|skeleton_boss_arm1|skeleton_boss_arm2|skeleton_boss_attack|skeleton_boss_idle|skeleton_boss_bone_bounce|skeleton_boss_arm_woosh|equip|unequip|bat_attack_small|bat_death_small|bat_wing|bat_wing_small|spider_attack|spider_death|spider_death_small|spider_eggs_spawn|spider_walk|scarab_awake|scarab_bite|scarab_death|scarab_horn|scarab_wings|mosquito_attack|mosquito_death|mosquito_loop|bronze_gate_locked|bat_attack|bat_death|progress_1|progress_2|progress_3|progress_4|progress_5|progress_6|progress_7|progress_8|progress_9|life_gain|player_death|logo_full|logo_short|smithy_hammer|sightstone_cast|error|ranting_tree_halt|treasure_close|treasure_item_pop|treasure_item_show|treasure_open|skeleton_boss_awake|skeleton_boss_hand_slam|level_up|insta_kill|spider_boss_awake|metal_drop|treasure_drop|smithy_hammer_fail|xp_tick|crossbow_cast|crossbow_hit|wand_aether_cast|wand_aether_hit|wand_air_cast|wand_air_hit|wand_fire_cast|wand_fire_hit|wand_ice_cast|wand_ice_hit|wand_poison_cast|wand_poison_hit|wand_vigor_cast|wand_vigor_hit|skeleton_boss_arm_reconnect|skeleton_boss_summon_minions|mushroom_boss_fat_slam|pickup_bronze|temple_npc_chant|temple_npc_clear_throat|temple_npc_talk|first_controller|slave_npc|slave_outro_chatter|slave_outro_voice|haunted_gate_npc_voice|slave_outro_transition|bronze_guardian_attack1|bronze_guardian_attack2|bronze_guardian_attack3|bronze_guardian_death|bronze_guardian_helmet|bronze_guardian_power_up|bronze_guardian_steps|ant_attack|ant_death|ant_walk|snail_attack|snail_attack_small|snail_death|snail_death_small|snail_walk|ghost_death|ghost_death_small|skeletimmy_death|skeletony_death|skeletimmy_attack|skeletony_attack|skeletony_awake_a|skeletony_awake_b|skeletony_walk|ghost_loop|ghost_loop_small|ghost_attack|ghost_attack_small|controller_death|controller_whip_attack|controller_whip_hit|dominotaur_death|dominotaur_whip_attack|dominotaur_whip_hit|mine_walker_death|mine_walker_attack_a|mine_walker_attack_b|mine_walker_attack_hit|mine_walker_awake|mine_walker_step|fire_elemental_attack|fire_elemental_attack_hit|fire_elemental_awake|fire_elemental_death|mine_walker_helmet_break|ice_elemental_attack|ice_elemental_attack_hit|ice_elemental_awake|ice_elemental_death|ki_eater_attack|ki_eater_attack_hit|ki_eater_awake|ki_eater_death|ki_gobbler_attack|ki_gobbler_attack_hit|ki_gobbler_awake|ki_gobbler_death|ki_slerper_attack|ki_slerper_attack_hit|ki_slerper_awake|ki_slerper_death|bell_ringer_attack|bell_ringer_attack_hit|cult_guard_attack|cult_guard_attack_hit|cult_marksman_attack|cult_marksman_attack_hit|cult_sorcerer_attack|cult_sorcerer_attack_hit|cultist_death|flying_serpent_loop|poison_adept_attack|poison_adept_attack_hit|serpent_attack|serpent_death|serpent_handler_release|serpent_hiss|serpent_slither|worm_rider_hop|booklet_open|booklet_turn_page|booklet_close|hammer_cast|hammer_hit|shield_dash|fissure_break_apart|fissure_unmake|mindstone_off|mindstone_on|triskelion_fuse|potion_berserk|potion_cleansing|potion_defensive|potion_experience|potion_healing|potion_invisibility|potion_lightning|potion_lucky|potion_strength|potion_vampiric|bronze_guardian_pulling_hammer|bronze_guardian_removing_hammer|bronze_guardian_turbine|bronze_guardian_ears_ring|bronze_guardian_fuse|bronze_guardian_attack4|yeti_attack|yeti_attack_flick|yeti_attack_hit|yeti_awake_blow|yeti_awake_explosion|yeti_awake_inhale|yeti_awake_lick|yeti_blow|yeti_blow_ice_wall|yeti_death|yeti_inhale|yeti_inhale_lick|nagaraja_awake_roar|nagaraja_awake_swallow|nagaraja_awake_tongue_1|nagaraja_awake_tongue_2|nagaraja_dead|nagaraja_poison_attack|nagaraja_poison_attack_hit|nagaraja_wail|nagaraja_wail_brick|nagaraja_attack_eat|nagaraja_attack_lick|nagaraja_attack_swallow|nagaraja_tongue_damaged|nagaraja_tongue_lift|nagaraja_tongue_smell|nagaraja_tongue_wrap|bearer3_talk|bearer_attack|bearer_attack_hit|bearer_death|bearer_stealing|bearer_super_attack|bearer_scream|bearer4_talk|bearer4_talk_evolving|bearer_evolving|elementalist_aether_attack|elementalist_aether_attack_hit|elementalist_aether_blink|elementalist_death|elementalist_fire_attack|elementalist_fire_attack_hit|elementalist_fire_blink|elementalist_ice_attack|elementalist_ice_attack_hit|elementalist_ice_blink|elementalist_poison_attack|elementalist_poison_attack_hit|elementalist_poison_blink|elementalist_vigor_attack|elementalist_vigor_attack_hit|elementalist_vigor_blink|bearer5_talk|elementalist_evolving|perfected_attack|perfected_attack_hit|perfected_death|perfected_defense|perfected_energy_ball|perfected_energy_ball_hit|perfected_summon|perfected_talk|epilogue_devolving|epliogue_player_evolves|epilogue_talk|devolved_talk|dysangelos_guidance|dysangelos_guidance_1|dysangelos_guidance_2|dysangelos_guidance_3|dysangelos_intro_talk|ranting_tree_talk_halt|ranting_tree_talk_again|ranting_tree_talk_how_dare|ranting_tree_talk_avenge|ranting_tree_talk_get_out|ranting_tree_talk_impressive|ranting_tree_talk_very_well|ranting_tree_talk_extra|hans_talk_intro|hans_talk_reward|scotty_a_pleasure|scotty_a_worthy_opponent|scotty_deuced|scotty_failte_back|scotty_getting_good|scotty_grr|scotty_guess_which|scotty_intro|scotty_lets_harden|scotty_make_ye_guess|scotty_noo_jist|scotty_perhaps_the_rules|scotty_pick_some_treasure|scotty_shall_we_up|scotty_we_have_wee_use|scotty_well_met|scotty_well_then|scotty_wizard|scotty_wrong_choice|scotty_hell_be_back|scotty_out_of_treasure|scotty_there_he_is|nagaraja_choir|mushroom_boss_split|ant_hill|treasure_drop_common|treasure_drop_epic|treasure_drop_giant|treasure_drop_humble|treasure_drop_rare|dominotaur_awake|fire_geyser|ice_pillar|treasure_item_cyan|treasure_item_yellow|treasure_item_green|treasure_item_blue|treasure_item_red|treasure_item_rainbow|ki_slerper_walk|mindstone_found|ghost_tomb_death|perfected_fly_start|perfected_fly_loop|perfected_fly_end|shop_door_open|shop_door_enter|scorpion_death|bomb_cart_explosion|bomb_cart_fuse|bomb_cart_move|bronze_gate_close|poison_powerup|acronian_cultist_power_up|giant_ice_elemental_attack|scout_dialog|morel_punch|falling_stonefolk|scout_arrives|scout_leaves|scout_wing|scout_focus|dog_bark|frog|lost_item_boost|treasure_item_lost|blade_glow|blade_pallas_attack|blade_raise|blade_drag|auggie_voice|pallas_voice|quest_stone_jump|quest_stone_unlock|bardiche_cast|boo_voice|quarterstaff_cast|air_hiss|bang_go_forward|fire_orbs|open_note|talisman_reveal|fire_beast_1|fire_beast_2|uulaa_voice|mask_summon_1|mask_summon_2)\\b", 103 | "name": "keyword.operator.sound-effect.stonescript" 104 | } 105 | ] 106 | }, 107 | "control": { 108 | "patterns": [ 109 | { 110 | "match": "(\\?|:\\?|:)", 111 | "name": "keyword.control.stonescript" 112 | }, 113 | { 114 | "match": "\\^", 115 | "name": "keyword.control.stonescript" 116 | }, 117 | { 118 | "match": "\\b(poison|vigor|aether|fire|air|ice|long|sword|compound|dashing|bashing|shield|wand|talisman|bardiche|heavy|repeating|crossbow|hammer|(quarter|socketed )?staff|skeleton arm|arm|blade|mask|mind|(?(`|o|h|c|f|\\()))(-)?[0-9.]+\\b", 227 | "name": "constant.numeric.stonescript" 228 | } 229 | ] 230 | }, 231 | "colors": { 232 | "patterns": [ 233 | { 234 | "match": "(#[0-9a-fA-F]{6})", 235 | "name": "constant.other.color.stonescript" 236 | }, 237 | { 238 | "match": "(#[0-9a-fA-F]{3})", 239 | "name": "constant.other.color.stonescript" 240 | }, 241 | { 242 | "match": "(#red|#white|#cyan|#yellow|#green|#blue)", 243 | "name": "constant.other.color.stonescript" 244 | }, 245 | { 246 | "match": "(#rain[0-9a-fA-F]{2})", 247 | "name": "constant.other.color.stonescript" 248 | } 249 | ] 250 | }, 251 | "strings": { 252 | "patterns": [ 253 | { 254 | "begin": "\"", 255 | "end": "\"", 256 | "name": "string.quoted.double.stonescript" 257 | }, 258 | { 259 | "begin": "'", 260 | "end": "'", 261 | "name": "string.quoted.single.stonescript" 262 | }, 263 | { 264 | "begin": "(?<=^ *>[`ohcf] ?(@.*?@|(-|\\+)?\\d+),(@.*?@|(-|\\+)?\\d+),#\\w{3,6},(\\n *\\^)?)|(?<=^ *>[`ohcf] ?(@.*?@|(-|\\+)?\\d+),(@.*?@|(-|\\+)?\\d+),(\\n *\\^)?)(?!#\\w{3,6},)|(?<=^ *>)(?![`ohcf] ?(@.*?@|(-|\\+)?\\d+),(@.*?@|(-|\\+)?\\d+),)|(?<=^ *>\\()", 265 | "end": "(?<=^)(?! *\\^)", 266 | "name": "meta.stonescript", 267 | "patterns": [ 268 | { "match": "^ *\\^", "name": "keyword.control.stonescript"}, 269 | { "include": "#ascii" }, 270 | { "include": "#links" }, 271 | { "match": "(@.+?@)|(ascii.+?asciiend)|(.+?)", 272 | "captures": { 273 | "3": {"name": "string.interpolated.stonescript"} 274 | } 275 | } 276 | ] 277 | }, 278 | { 279 | "match": "^ *>(^ *>|\\(|[`ohcf](?= ?(@.*?@|(-|\\+)?\\d+),(@.*?@|(-|\\+)?\\d+),))?", 280 | "name": "keyword.control.stonescript" 281 | }, 282 | { 283 | "match": "\\\\n", 284 | "name": "constant.character.escape" 285 | } 286 | ] 287 | } 288 | } 289 | } 290 | --------------------------------------------------------------------------------