我正在尝试使用C#学习编写游戏脚本,当我在Godot引擎中右键选择连接,添加了信号之后,Godot自动打开了Visual Studio Code,但是为我的脚本添加一段_on_xxx(){}的方法,这是否说明我必须手动输入这段代码?
官方文档中指出,"Godot will automatically create a function",然而我并没有在VSCode中找到这段代码。(无论是选择哪个Signal,都会存在这个问题)
我正在学习的文档:https://docs.godotengine.org/en/stable/getting_started/first_2d_game/03.coding_the_player.html#preparing-for-collisions
我尝试将外部编辑器切换为Disabled,发现这段代码可以正常添加到Godot内置的编辑器中(而且确实是正确的C#代码,而不是官方文档中的GDScript)。我尝试过保存Godot项目,点击Build,但是VSCode中仍然没有自动添加本段代码,直到我使用Godot内置编辑器保存,VScode才可以从磁盘加载由Godot修改的代码。
我也尝试切换为Visual Studio,但这个问题仍然存在。
Godot版本:v4.1.3.stable.mono.official [f06b6836a],
VScode信息:
版本: 1.84.2 (user setup)
提交: 1a5daa3a0231a0fbba4f14db7ec463cf99d7768e
日期: 2023-11-09T10:51:52.184Z
Electron: 25.9.2
ElectronBuildId: 24603566
Chromium: 114.0.5735.289
Node.js: 18.15.0
V8: 11.4.183.29-electron.0
OS: Windows_NT x64 10.0.22621
VS信息:
Microsoft Visual Studio Community 2022
版本 17.7.5
VisualStudio.17.Release/17.7.5+34202.233
Microsoft .NET Framework
版本 4.8.09032
Windows版本: 10.0.22621 版本 22621
官方文档中指出,"Godot will automatically create a function",然而我并没有在VSCode中找到这段代码。(无论是选择哪个Signal,都会存在这个问题)
我正在学习的文档:https://docs.godotengine.org/en/stable/getting_started/first_2d_game/03.coding_the_player.html#preparing-for-collisions

我尝试将外部编辑器切换为Disabled,发现这段代码可以正常添加到Godot内置的编辑器中(而且确实是正确的C#代码,而不是官方文档中的GDScript)。我尝试过保存Godot项目,点击Build,但是VSCode中仍然没有自动添加本段代码,直到我使用Godot内置编辑器保存,VScode才可以从磁盘加载由Godot修改的代码。
我也尝试切换为Visual Studio,但这个问题仍然存在。
Godot版本:v4.1.3.stable.mono.official [f06b6836a],
VScode信息:
版本: 1.84.2 (user setup)
提交: 1a5daa3a0231a0fbba4f14db7ec463cf99d7768e
日期: 2023-11-09T10:51:52.184Z
Electron: 25.9.2
ElectronBuildId: 24603566
Chromium: 114.0.5735.289
Node.js: 18.15.0
V8: 11.4.183.29-electron.0
OS: Windows_NT x64 10.0.22621
VS信息:
Microsoft Visual Studio Community 2022
版本 17.7.5
VisualStudio.17.Release/17.7.5+34202.233
Microsoft .NET Framework
版本 4.8.09032
Windows版本: 10.0.22621 版本 22621

