Repository navigation
Expand file tree
/
Copy pathpackage.json
More file actions
283 lines (283 loc) · 10.2 KB
/
Copy pathpackage.json
File metadata and controls
283 lines (283 loc) · 10.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
{
"name": "vscript-debug",
"displayName": "VScript Debugger",
"version": "0.2.8",
"publisher": "LionDoge",
"description": "A debugger client for VScripts in games based on Source Engine.",
"author": {
"name": "Lion Doge"
},
"license": "GPL3",
"keywords": [
"vscript",
"csgo",
"tf2",
"l4d2",
"portal 2",
"Squirrel",
"vscript debugger",
"Squirrel debugger"
],
"engines": {
"vscode": "^1.84.0"
},
"icon": "images/icon.png",
"categories": [
"Debuggers"
],
"extensionDependencies": [],
"private": true,
"repository": {
"type": "git",
"url": "https://github.com/LionDoge/vscode-vscript-debugger"
},
"bugs": {
"url": "https://github.com/LionDoge/vscode-vscript-debugger/issues"
},
"scripts": {
"compile": "tsc -p ./",
"lint": "eslint src --ext ts",
"typecheck": "tsc -p tsconfig.json --noEmit",
"esbuild-base": "esbuild ./src/extension.ts --bundle --tsconfig=./tsconfig.json --external:vscode --format=cjs --platform=node --outfile=dist/extension.js",
"watch": "npm run -S esbuild-base -- --sourcemap --sources-content=false --watch",
"build": "npm run -S esbuild-base -- --sourcemap --sources-content=false",
"package": "vsce package",
"publish": "vsce publish",
"publish-pre-release": "vsce publish --pre-release",
"vscode:prepublish": "rimraf dist && npm run -S esbuild-base -- --minify"
},
"devDependencies": {
"@total-typescript/ts-reset": "^0.6.1",
"@types/jest": "^30.0.0",
"@types/mocha": "^10.0.10",
"@types/node": "^24.10.1",
"@types/vscode": "^1.106.0",
"@types/xml2js": "^0.4.14",
"@typescript-eslint/eslint-plugin": "^8.46.4",
"@typescript-eslint/parser": "^8.46.4",
"@vscode/debugadapter": "^1.68.0",
"await-notify": "^1.0.1",
"base64-js": "^1.5.1",
"esbuild": "^0.27.0",
"eslint": "^9.39.1",
"events": "^3.3.0",
"glob": "^11.0.3",
"mocha": "^11.7.5",
"path-browserify": "^1.0.1",
"rimraf": "^6.1.0",
"typescript": "^5.9.3",
"url": "^0.11.4"
},
"main": "./dist/extension.js",
"activationEvents": [
"onDebug",
"onDebugResolve:vscript",
"onDebugDynamicConfigurations:vscript"
],
"workspaceTrust": {
"request": "never"
},
"contributes": {
"configuration": {
"title": "VScript Debugger",
"properties": {
"VScriptDebugger.connectionIP": {
"type": "string",
"default": "localhost",
"description": "The IP of the device on which the game is running to connect the debugger to. This setting can be overriden by the 'ip' setting in launch.json. When running the game on the same device as VS Code use 'localhost'"
},
"VScriptDebugger.connectionPort": {
"type": "integer",
"default": 1234,
"description": "The port to use for debugger connections. It is not possible to change which port the game uses by normal means, only change if you know what you are doing."
},
"VScriptDebugger.resumeWorkaround": {
"type": "boolean",
"default": true,
"description": "Automatically resumes execution if no data is sent in a certain time frame, workarounds the issue of not being able to break on breakpoints after execution was resumed by other means than the resume button (only applicable to Squirrel 2 games)."
},
"VScriptDebugger.resumeWorkaroundTimeout": {
"type": "integer",
"default": 2000,
"description": "Time in milliseconds. Only applies if \"Resume Workaround\" is enabled. How much to wait before assuming that no data will be recieved. Setting this higher will allow for remote debugging on slower connections, but the debugger won't be able to break on next breakpoints until this time has passed since last execution that was resumed by other means than the resume button."
},
"VScriptDebugger.scriptEngineVersion": {
"type": "string",
"default": "Squirrel3",
"description": "Defaults to this if not specified in launch.json. Determines which VScript engine version will be debugged. Used as a way to know which workarounds or specific functionalities need to be adjusted by the debugger.",
"scope": "window",
"enum": [
"Squirrel3",
"Squirrel2"
],
"enumItemLabels": [
"VSquirrel version 3.x",
"VSquirrel version 2.x"
],
"enumDescriptions": [
"Squirrel version 3.x games (for most modern games)",
"Squirrel version 2.x games (for legacy games)"
]
},
"VScriptDebugger.maximumStructureShortRepresentationValues": {
"type": "number",
"default": "4",
"description": "How much data to display in structured variables' (e.g. tables, arrays) short one lined representation without fully fetching all data.\n\nNOTE:Setting this to a high value could noticably slow down the debugger with large amounts of data."
},
"VScriptDebugger.hideNativeFunctions": {
"type": "boolean",
"default": true,
"description": "Hide native functions from list of variables."
},
"VScriptDebugger.hideClassDefinitions": {
"type": "boolean",
"default": false,
"description": "Hide class definitions from list of variables."
},
"VScriptDebugger.rememberFileReferencesDuringSession": {
"type": "boolean",
"default": false,
"markdownDescription": "**Doesn't apply to L4D2** *(Workaround for a bug)* If multiple files of the same name exist then upon choosing one it will be remembered for the whole debugging session. You can enable this if you don't expect conflicts with files in your current project."
},
"VScriptDebugger.telnet.enable": {
"type": "boolean",
"default": false,
"description": "[NOT IMPLEMENTED] Enables support for communication between the game and Visual Studio Code for more integration."
},
"VScriptDebugger.telnet.port": {
"type": "integer",
"default": 34755,
"markdownDescription": "[NOT IMPLEMENTED] The port used for Telnet communication if enabled. Use this port with `-netconport` in your game's launch parameters."
},
"VScriptDebugger.displayRootTable": {
"type": "boolean",
"default": false,
"description": "If enabled gathers the root table and displays it in scopes view. Also allows to view 'this' table of script ran in the global scope. It will substantially increase the amount of data sent."
}
}
},
"menus": {
"editor/title/run": [
{
"command": "extension.vscript-debug.attachDebugger",
"when": "resourceLangId == squirrel",
"group": "navigation@2"
}
],
"commandPalette": [
{
"command": "extension.vscript-debug.attachDebugger",
"when": "resourceLangId == squirrel"
}
]
},
"commands": [
{
"command": "extension.vscript-debug.attachDebugger",
"title": "Attach Debugger",
"category": "VScript",
"enablement": "!inDebugMode",
"icon": "$(debug-alt)"
}
],
"breakpoints": [
{
"language": "squirrel"
}
],
"languages": [
{
"id": "squirrel",
"aliases": [
"Squirrel",
"squirrel"
],
"extensions": [
".nut"
]
}
],
"debuggers": [
{
"type": "vscript",
"languages": [
"squirrel"
],
"label": "VScript",
"program": "./out/debugAdapter.js",
"runtime": "node",
"configurationAttributes": {
"attach": {
"properties": {
"engineVersion": {
"type": "string",
"description": "Determines which VScript engine version will be debugged. Used as a way to know which workarounds or specific functionalities need to be adjusted by the debugger.",
"enum": [
"Squirrel3",
"Squirrel2"
],
"enumDescriptions": [
"Squirrel version 3.x games (for most modern games).",
"Squirrel version 2.x games (for legacy games). This setting is forwards compatible with Squirrel 3"
]
},
"ip": {
"type": "string",
"description": "The IP of the device on which the game is running to connect the debugger to. If not set will use the global configuration.",
"default": "localhost"
},
"additionalScriptDirectories": {
"type": "array",
"description": "List of directories considered as valid paths containing VScripts."
},
"enableDebugLogging": {
"type": "boolean",
"description": "Print received XML data to the console."
}
}
}
},
"initialConfigurations": [
{
"type": "vscript",
"request": "attach",
"name": "VScript",
"ip": "localhost",
"engineVersion": "Squirrel3"
}
],
"configurationSnippets": [
{
"label": "VScript",
"description": "Squirrel version 3.x+ games (Most modern games)",
"body": {
"type": "vscript",
"request": "attach",
"name": "VScript (Squirrel 3)",
"engineVersion": "Squirrel3"
}
},
{
"label": "VScript (Squirrel v2.x)",
"description": "Squirrel version 2.x legacy games (like CS:GO ...)",
"body": {
"type": "mock",
"request": "attach",
"name": "VScript (Squirrel 2)",
"engineVersion": "Squirrel2"
}
}
],
"variables": {
"AskForProgramName": "extension.vscript-debug.getProgramName"
}
}
]
},
"dependencies": {
"html-entities": "^2.6.0",
"@vscode/vsce": "^3.7.0",
"xml-formatter": "^3.6.7",
"xml2js": "^0.6.2"
}
}