Godot Version
godot 4.4
Question
Hello all,
I’m developing only with C++ in Godot using GDExtension and having real fun—great framework!
Now, a question coming from non-game-related fields (critical systems): What are the fields where I can push C++ to the edge, something that GDScript would really struggle with? I like to experiment.
Please don’t try to convince me that GDScript is better. It is great, but not for me.
Thanks
Those who say this never really used another language for years and years before.
I use C# with Godot and I’m really happy with it, trying out GDScript was more annoying for me than anything else.
I think most built-in function are already written in C++ so they’re really, really fast, but I think where C++ really shines is with games where you need to compute a LOT of things really fast. You also have a huge advantage since you can implement libraries that otherwise wouldn’t be included in Godot by default. A huge favourite of mine is Steam Audio ( Steam Audio ). There’s already an addon written in C++ to put it into Godot, but if you use C++ anyway, it can be really cool to try and make these external libraries work! GitHub - stechyo/godot-steam-audio: Immersive spatial audio extension for Godot, using Valve's SteamAudio
Oh give gdscript a break would you. It is a great little language specifically for the engine.
If you are just starting out with either Godot or game development in general, GDScript is the recommended language to learn and use since it is native to Godot. While scripting languages tend to be less performant than lower-level languages in the long run, for prototyping, developing Minimum Viable Products (MVPs), and focusing on Time-To-Market (TTM), GDScript will provide a fast, friendly, and capable way of developing your games.
I keep meaning to learn C++ but TBH, I have just never had the time nor any real reason to, but it still sits there as something I should and want to do.
The officially supported languages for Godot are GDScript, C#, and C++.
I get the impression though from other peoples posts that getting C++ or C# up and running for the engine is quite a labour and not for the novice. I could be wrong about this, but if I were going to start learning C++, I think I would try to do it first outside of Godot, before then trying it out with Godot.
Yeah, that sounds fun! I am a bit jealous of you C++ people.
Anyway, I haven’t really added anything of value to this thread apart from wanting to say please be king to gdscript and give it some credit. As a beginner myself, I love it! Without it I would never have made a game as I just cannot face the two year learning curve of getting to grips with C++. (I am sure C# is easier, but for some reason it always leaves me a bit ‘meh’ feeling when I think about C#, my own bias of course, probably unfair.)
2 Likes
This is absolutely the case for C++, but not for C#. The only difference is that you need to download the mono version of Godot (it’s the second big download button on the website) and also install dotnet sdk, which is also just a single installer that you get from Microsoft, and you’re done.
1 Like
@tibaverus
Well that sounds simple enough. Hmm. Although I just don’t know when I can find the time, perhaps C# will be much easier to get into than C++, which to mean seems so low level that it really needs proper training on it. So thank you for that, I am going to try and find some time to devote to trying out C#, if not before Christmas, perhaps I could start over the Christmas holidays.
@whiletrue111
Thanks for this thread. It has resulted in me committing to learn some C# (finally, I probably should have done this a long time ago.)
It’s simple. There’s only one rational reason to use C++ - performance.
The question is not either/or. The best approach is to combine. C++ and GDScript work really well together.
My rule of thumb is this. Implement everything in GDScript. It’s ideal for high level scripting, and can economically and quickly prototype whatever you need. If there are parts causing bottlenecks (e.g. any kind of excessive per-frame iteration, vertex data processing etc…), first try to find a way to delegate that to engine’s native code through built in facilities. There are many of them the average user is not aware of.
If optimal performance still cannot be achieved - delegate critical parts either to your C++ extension code or to compute shaders.
Only other legitimate reason to use C++ may be if you really really love it 
In summary, the C++ vs. GDScript argument is childish. They are meant to work together, not be pinned one against another.
1 Like
C++ is good for computationally intensive processes - gdscript is more like python, which is used for system integration (i.e. the glue between low level powerful libraries).
Typically C++ is order of magnitudes faster than raw Python for tasks like finding prime numbers or multiplying matrices. But Python has powerful libraries like numpy and simpy in the scipi stack that make write such things easier.
If you had to work with large tree type structures or very large graphs then C++ will shine. For things that can be parallelized gdscript has access to the compute shader pipeline, and so could out- perform the C++ version (unless thats also using compute).
I would expect strategy game NPC’s would be better in C++, especially if they are not easy to compute in a compute shader.
Oh, there’s one more case where going full on C++ would make sense - if you decide to not use Godot’s scene tree and node system at all, and instead maintain your own main game loop and scene graph and communicate with the engine only via its server APIs. In fact, using GDScript here would be highly insufficient, almost insane 
On the other end of spectrum, doing endless gameplay balancing tweaks in the later stages of development without a scripting language may drive you insane as well 
2 Likes