mirror of
https://github.com/godotengine/godot-vscode-plugin.git
synced 2026-02-26 00:53:27 +03:00
Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c2ec7c9f05 | ||
|
|
4d7c23fe81 | ||
|
|
74b766726a | ||
|
|
53f986f131 | ||
|
|
104148baa9 |
2
.github/ISSUE_TEMPLATE/bug_report.yml
vendored
2
.github/ISSUE_TEMPLATE/bug_report.yml
vendored
@@ -40,7 +40,7 @@ body:
|
||||
Open the **Extensions** side panel and click on the **godot-tools** extension to see your current version.
|
||||
Specify the Git commit hash if using a development or non-official build.
|
||||
If you use a custom build, please test if your issue is reproducible in official builds too.
|
||||
placeholder: "2.6.0"
|
||||
placeholder: "2.6.1"
|
||||
validations:
|
||||
required: true
|
||||
|
||||
|
||||
2
.github/ISSUE_TEMPLATE/feature_request.yml
vendored
2
.github/ISSUE_TEMPLATE/feature_request.yml
vendored
@@ -40,7 +40,7 @@ body:
|
||||
Open the **Extensions** side panel and click on the **godot-tools** extension to see your current version.
|
||||
Specify the Git commit hash if using a development or non-official build.
|
||||
If you use a custom build, please test if your issue is reproducible in official builds too.
|
||||
placeholder: "2.6.0"
|
||||
placeholder: "2.6.1"
|
||||
validations:
|
||||
required: true
|
||||
|
||||
|
||||
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
@@ -63,7 +63,7 @@ jobs:
|
||||
- name: Install Node.js
|
||||
uses: actions/setup-node@v5.0.0
|
||||
with:
|
||||
node-version: 16.x
|
||||
node-version: 22.x
|
||||
|
||||
- name: Install dependencies
|
||||
run: npm install
|
||||
|
||||
@@ -1,5 +1,9 @@
|
||||
# Changelog
|
||||
|
||||
### 2.6.1
|
||||
|
||||
- [Fix broken LSP connection handshake, which resulted in VS Code constantly trying to reconnect](https://github.com/godotengine/godot-vscode-plugin/pull/968)
|
||||
|
||||
### 2.6.0
|
||||
|
||||
- [**Add support for `uid://` references to hovers and document links**](https://github.com/godotengine/godot-vscode-plugin/pull/841)
|
||||
|
||||
38
README.md
38
README.md
@@ -9,21 +9,19 @@ Godot 3.2 or later.
|
||||
- [Features](#features)
|
||||
- [Download](#download)
|
||||
- [Commands](#commands)
|
||||
- [Configuration](#configuration)
|
||||
- [Godot Editor](#godot-editor)
|
||||
- [VS Code](#vs-code)
|
||||
- [GDScript Debugger](#gdscript-debugger)
|
||||
- [*Configurations*](#configurations)
|
||||
- [Issues and contributions](#issues-and-contributions)
|
||||
- [Configuration](#configuration) - [Godot Editor](#godot-editor) - [VS Code](#vs-code)
|
||||
- [GDScript Debugger](#gdscript-debugger) - [_Configurations_](#configurations)
|
||||
- [Issues and contributions](#issues-and-contributions)
|
||||
- [Contributing](#contributing)
|
||||
- [FAQ](#faq)
|
||||
- [Why does it fail to connect to the language server?](#why-does-it-fail-to-connect-to-the-language-server)
|
||||
- [Why isn't IntelliSense displaying script members?](#why-isnt-intellisense-displaying-script-members)
|
||||
|
||||
- [FAQ](#faq)
|
||||
- [Why does it fail to connect to the language server?](#why-does-it-fail-to-connect-to-the-language-server)
|
||||
- [Why isn't IntelliSense displaying script members?](#why-isnt-intellisense-displaying-script-members)
|
||||
- [I'm using Linux and the drag + shift drop isn't working. Why?](#im-using-linux-and-the-drag--shift-drop-isnt-working-why)
|
||||
|
||||
# Features
|
||||
|
||||
(**bold items** are new in Godot Tools `v2.0.0`)
|
||||
|
||||
- **ALL FEATURES FULLY SUPPORT GODOT 4**
|
||||
- GDScript (`.gd`) language features:
|
||||
- syntax highlighting
|
||||
@@ -92,12 +90,12 @@ You can set VS Code as your default script editor for Godot by following these s
|
||||
|
||||
1. Open the **Editor Settings**
|
||||
2. Select **Text Editor > External**
|
||||
3. Check **Use External Editor**
|
||||
3. Check **Use External Editor**
|
||||
4. Fill **Exec Path** with the path to your VS Code executable
|
||||
* On macOS, this executable is typically located at: `/Applications/Visual Studio Code.app/Contents/MacOS/Electron`
|
||||
- On macOS, this executable is typically located at: `/Applications/Visual Studio Code.app/Contents/MacOS/Electron`
|
||||
5. Fill **Exec Flags** with `{project} --goto {file}:{line}:{col}`
|
||||
|
||||
You can make Godot seamlessly reload VSCode-edited scripts by changing some additional settings. More details about each are available when hovering over the description in the Settings window:
|
||||
You can make Godot seamlessly reload VSCode-edited scripts by changing some additional settings. More details about each are available when hovering over the description in the Settings window:
|
||||
|
||||
- **Editor Settings > Text Editor > Behavior > Files > Auto Reload Scripts on External Change**
|
||||
- **Editor Settings > Interface > Editor > Save on Focus Loss**
|
||||
@@ -113,7 +111,7 @@ You can use the following settings to configure Godot Tools:
|
||||
The path to the Godot editor executable. _Under Mac OS, this is the executable inside of Godot.app._
|
||||
|
||||
- `godotTools.lsp.headless`
|
||||
|
||||
|
||||
When using Godot >3.6 or >4.2, Headless LSP mode is available. In Headless mode, the extension will attempt to launch a windowless instance of the Godot editor to use as its Language Server.
|
||||
|
||||
# GDScript Debugger
|
||||
@@ -132,9 +130,10 @@ To configure the GDScript debugger:
|
||||
5. Change any relevant settings.
|
||||
6. Press F5 to launch.
|
||||
|
||||
### *Configurations*
|
||||
### _Configurations_
|
||||
|
||||
Minimal:
|
||||
|
||||
```json
|
||||
{
|
||||
"name": "Launch",
|
||||
@@ -144,6 +143,7 @@ Minimal:
|
||||
```
|
||||
|
||||
Everything:
|
||||
|
||||
```json
|
||||
{
|
||||
"name": "Launch",
|
||||
@@ -173,7 +173,7 @@ Everything:
|
||||
|
||||
Godot's command flags are documented here: https://docs.godotengine.org/en/stable/tutorials/editor/command_line_tutorial.html
|
||||
|
||||
*Usage*
|
||||
_Usage_
|
||||
|
||||
- Stacktrace and variable dumps are the same as any regular debugger
|
||||
- The active scene tree can be refreshed with the Refresh icon in the top right.
|
||||
@@ -220,3 +220,9 @@ Godot has some Editor Settings that can help you if your workflow involves chang
|
||||
- **Editor Settings > Text Editor > Behavior > Files > Auto Reload Scripts on External Change**
|
||||
- **Editor Settings > Interface > Editor > Save on Focus Loss**
|
||||
- **Editor Settings > Interface > Editor > Import Resources When Unfocused**
|
||||
|
||||
### I'm using Linux and the drag + shift drop isn't working. Why?
|
||||
|
||||
Most likely you're using Wayland as display server, and there's a limitation of support in VS Code. Try
|
||||
running `code` through the terminal in the project directory with the flag `--ozone-platform=x11`.
|
||||
This will force VS Code to run through XWayland, where it works.
|
||||
|
||||
@@ -15,63 +15,70 @@
|
||||
"_ready method of Node": {
|
||||
"prefix": "ready",
|
||||
"body": [
|
||||
"func _ready():",
|
||||
"func _ready() -> void:",
|
||||
"\t${1:pass}"
|
||||
]
|
||||
},
|
||||
"_init method of Object": {
|
||||
"prefix": "init",
|
||||
"body": [
|
||||
"func _init():",
|
||||
"func _init() -> void:",
|
||||
"\t${1:pass}"
|
||||
]
|
||||
},
|
||||
"_process method of Node": {
|
||||
"prefix": "process",
|
||||
"body": [
|
||||
"func _process(delta):",
|
||||
"func _process(delta: float) -> void:",
|
||||
"\t${1:pass}"
|
||||
]
|
||||
},
|
||||
"_physics_process method of Node": {
|
||||
"prefix": "physics",
|
||||
"body": [
|
||||
"func _physics_process(delta):",
|
||||
"func _physics_process(delta: float) -> void:",
|
||||
"\t${1:pass}"
|
||||
]
|
||||
},
|
||||
"_input method of Node": {
|
||||
"prefix": "input",
|
||||
"body": [
|
||||
"func _input(event):",
|
||||
"func _input(event: InputEvent) -> void:",
|
||||
"\t${1:pass}"
|
||||
]
|
||||
},
|
||||
"_input_event method of Node": {
|
||||
"prefix": "inpute",
|
||||
"_input_event method of CollisionObject2D": {
|
||||
"prefix": "inpute2D",
|
||||
"body": [
|
||||
"func _input_event(event):",
|
||||
"func _input_event(viewport: Viewport, event: InputEvent, shape_idx: int) -> void:",
|
||||
"\t${1:pass}"
|
||||
]
|
||||
},
|
||||
"_input_event method of CollisionObject3D": {
|
||||
"prefix": "inpute3D",
|
||||
"body": [
|
||||
"func _input_event(camera: Camera3D, event: InputEvent, event_position: Vector3, normal: Vector3, shape_idx: int) -> void:",
|
||||
"\t${1:pass}"
|
||||
]
|
||||
},
|
||||
"_unhandled_input method of Node": {
|
||||
"prefix": "uinput",
|
||||
"body": [
|
||||
"func _unhandled_input(event):",
|
||||
"func _unhandled_input(event: InputEvent) -> void:",
|
||||
"\t${1:pass}"
|
||||
]
|
||||
},
|
||||
"_draw method of Node": {
|
||||
"_draw method of CanvasItem": {
|
||||
"prefix": "draw",
|
||||
"body": [
|
||||
"func _draw():",
|
||||
"func _draw() -> void:",
|
||||
"\t${1:pass}"
|
||||
]
|
||||
},
|
||||
"_gui_input method of Node": {
|
||||
"_gui_input method of Control": {
|
||||
"prefix": "guii",
|
||||
"body": [
|
||||
"func _gui_input(event):",
|
||||
"func _gui_input(event: InputEvent) -> void:",
|
||||
"\t${1:pass}"
|
||||
]
|
||||
},
|
||||
@@ -181,7 +188,7 @@
|
||||
"# var a = 2",
|
||||
"# var b = \"textvar\"",
|
||||
"",
|
||||
"func _ready():",
|
||||
"func _ready() -> void:",
|
||||
"\t# Called every time the node is added to the scene.",
|
||||
"\t# Initialization here",
|
||||
"\tpass",
|
||||
@@ -282,4 +289,4 @@
|
||||
],
|
||||
"description": "Waits for a given amount of seconds"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
4
package-lock.json
generated
4
package-lock.json
generated
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "godot-tools",
|
||||
"version": "2.6.0",
|
||||
"version": "2.6.1",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "godot-tools",
|
||||
"version": "2.6.0",
|
||||
"version": "2.6.1",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@vscode/debugadapter": "^1.68.0",
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
"name": "godot-tools",
|
||||
"displayName": "godot-tools",
|
||||
"icon": "icon.png",
|
||||
"version": "2.6.0",
|
||||
"version": "2.6.1",
|
||||
"description": "Tools for game development with Godot Engine and GDScript",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
|
||||
@@ -51,10 +51,8 @@ export class MessageIO extends EventEmitter {
|
||||
socket.on("data", (chunk: Buffer) => {
|
||||
this.emit("data", chunk);
|
||||
});
|
||||
// socket.on("end", this.on_disconnected.bind(this));
|
||||
socket.on("error", () => {
|
||||
this.socket = null;
|
||||
this.emit("disconnected");
|
||||
});
|
||||
socket.on("close", () => {
|
||||
this.socket = null;
|
||||
|
||||
Reference in New Issue
Block a user