New to Godot but not code, how's (your) vscode-based `.gd `editing / workflow?
Asked Answered
M

9

0

tl;dr: The question itself: anyone coding all their scripts outside the built-in editor? And if also vscode, does the ext still handle some of v4 / some language-support extension features? How's the experience?

And here the wordy chitchatty "hi I'm new here, here's where I'm coming from" wall-of-text part.. πŸ˜€

Well last time I toyed in this space was 2013-15ish in Unity, but mostly as a "shader-dev canvas" as gfx was my actual dev interest back then.

Now this time I'm actually more into trying out casual/hobbyist game-making evenings/weekends but the things I have in mind will (have to) be code-heavy with very little "editor GUI" usage. (Habit/preference.. I rather press F5 more often than clicking/dragging stuff together all the time.) Other than a root scene+script to kick off everything else, including all inits.

So anyway, as neat and impressive as the built-in source text editor is, I cannot fully customize it to exactly replicate the setup I'm used to spending all my other time in and have for years, which is VSCode-based nowadays.

Since it's actually the FOSS-er version of it (codium), it is sometimes (depends on category) a little slimmer in the extensions-registry/results, but still I find 2 exts for Godot:

  • a purely-syntax-coloring one that's very actively maintained by alfish, and
  • "the basically-(semi?)-official one" from github.com/godotengine/godot-vscode-plugin named godot-tools

Well this gets fresh commits and is not inactive, but no releases (in GH or exts repo) since summer 2022. Godot 4, a substantial move from v3 I suppose, came out in March '23. So looks like it's still WIP for that one...

Mercaptopurine answered 27/11, 2023 at 17:21 Comment(0)
O
1

Hello and welcome!

I wasn't happy with the VSCode experience with GDScript in Godot 4. I think it worked well with Godot 3, but I can't say for sure as I never used Godot 3 much. One problem I have with using actually any external editor for GDScript is how much the internal editor actually controls reloading, analyzing, and evaluating GDScripts. The language server at least works and is updated within the main Godot repo, which is good because it's weirdly responsible for ensuring that externally edited GDScripts get reloaded. When VSCode (with the plugin) saves, it sends a message to the language server which then tells Godot's script editor to reload the script. For a brief time that wasn't working, and I had to resort to reloading the editor when I made script changes... I think I'm rambling but yeah, I'm not a fan πŸ™ƒ

I've gotten used to the internal editor and there are some things I quite like about it, but I definitely wish for a better external editor experience. If you're feeling adventurous, I recall seeing someone got VSCode working as the internal editor some months ago. Maybe you could find that project and maybe it would work well. Who knows?

Officialism answered 27/11, 2023 at 18:57 Comment(0)
M
0

Cheers Sondra! =) In the meantime I did see there's an LSP server in the godot binary, so I guess I'll see what the state-of-affairs is. Given the main vs-ext's Releases are 1.5+ years old, I reckon I'd have to roll with the main branch of the extension repo (and update via git). If it's only mildly bugged, I can probably help out with fixes, having plenty vs-ext-toying XP, and if it's hopelessly over-bugged, I can consider whipping up a minimalist, tailored-to-needs alt LSP-clienting vs-ext instead. Former would of course be preferable, will check it all out. =)

Officialism If you're feeling adventurous, I recall seeing someone got VSCode working as the internal editor some months ago. Maybe you could find that project and maybe it would work well.

Whoa, sounds like some crazy hackery! Would love to see how that's done. Can imagine somehow streaming in live rendition from headless code sub-process... but sending input back? Curious.

Mercaptopurine answered 27/11, 2023 at 19:25 Comment(0)
I
0

I'm using VSCode, and Godot and VSCode both have each others paths so the workflow is "seamless" (Godot will open VSCode when opening code, VSCode can run the project with F5). I'm also using VSCode with the godot-tools extension as is, from the VSCode extensions library, and it works fine, because afaik it's working with the Godot LSP - it isn't specific to Godot 3.x or 4.x. Did you try the absolute vanilla setup?

That being said, Copilot sometimes has a bit of trouble, but it also works very fine and adapts to the code base well enough so it's still useful.

Also, not sure where you're seeing those dates, because the extension has been: "Last updated
2023-09-14"

Inadmissible answered 28/11, 2023 at 19:13 Comment(0)
O
0

Inadmissible Also, not sure where you're seeing those dates, because the extension has been: "Last updated
2023-09-14"

likely on the github repo https://github.com/godotengine/godot-vscode-plugin

It's possible they just stopped deploying on github

Officialism answered 28/11, 2023 at 19:28 Comment(0)
M
0

Inadmissible Also, not sure where you're seeing those dates, because the extension has been: "Last updated
2023-09-14"

Thanks PDeveloper, sounds great, will give it a go shortly (still doing the docs' intro tuts in Godot for now). The dates are probably due to me using the codium build of VSCode, I think they have their own extensions registry that might just not be so well-updated for all extensions. Can always switch to the standard MS build if need be.. =)

Or β€” it's like how Officialism says, will find out. πŸš€

Mercaptopurine answered 28/11, 2023 at 19:49 Comment(0)
G
0

If it's only mildly bugged,<snip> if it's hopelessly over-bugged

Ouch, I do actually have feelings, you know!

I've been working on Godot 4 support for more than a year now, but I'm getting very close to publishing a new release. Ideally in the next two weeks.

Gourley answered 30/11, 2023 at 4:33 Comment(0)
M
0

Gourley > I've been working on Godot 4 support for more than a year now

First off, mad props, LSP clienting or servering is no picnic, tippin' my head and I ain't kiddin' =)

Gourley Ouch, I do actually have feelings, you know!

Not even having tried it yet, I didn't mean anything by it, let alone to imply that any amount of buggedness was likely or indeed even to be expected =)

Gourley but I'm getting very close to publishing a new release. Ideally in the next two weeks.

I'll definitely jump on it then at the very latest, am looking forward to it! πŸš€

Mercaptopurine answered 30/11, 2023 at 6:4 Comment(0)
G
1

Mercaptopurine First off, mad props, LSP clienting or servering is no picnic, tippin' my head and I ain't kiddin' =)

Actually, the LSP has been (mostly) fine: it's the debugger client that's been a nightmare. The engine's debugger had a medium amount of changes between 3 and 4, but trying to adapt to those changes (and support both versions!) mostly just proved that the client never worked in the first place! It was a ton of work to reverse engineer and then rebuild almost the entire thing, but the end result is easier to work on and much more reliable.

Mercaptopurine I'll definitely jump on it then at the very latest, am looking forward to it! πŸš€

Since Godot 4.2 came out today (I was expecting them to take a little longer), I'm gonna try to publish this weekend at the latest.

Gourley answered 30/11, 2023 at 20:59 Comment(0)
N
0

Gourley Hi! Where can I find the new release? Thanks.

Norbertonorbie answered 20/1 at 9:44 Comment(0)

© 2022 - 2024 β€” McMap. All rights reserved.