C++
Asked Answered
A

6

0

hey i am a new dev that wants to learn C++ to also work on other engines, does godot supports C++??

Ashraf answered 27/9, 2023 at 23:16 Comment(0)
S
0

Yes! Adding C++ code to your game is not as straightforward as adding GDScript or C# code, but it is about the same complexity as C++ in any other game engines. There are two main ways of using C++ in Godot:

GDExtensions are a way to add C++ that don't require you to recompile the entire engine just to add some new code. Getting started can be a lil tricky, but there are good resources out there to show you how to do it.

You can also download the engine source from Github. Even if you don't know Git, you can still download it. With the full source, you can add your own new code or change existing code in the engine, but you will need to fully compile it each time you make a change.

Are you familiar with other programming languages? It might be hard to get started with C++ in Godot without knowing the basics of programming first. There are resources out there for learning C++ as your first language, but none that I know use Godot, and C++ can be a tricky language.

Selfdenial answered 27/9, 2023 at 23:27 Comment(0)
B
0

How do you open the engine from the source in Github? I've got it, but I have no idea how to open it.

Bobby answered 27/9, 2023 at 23:47 Comment(0)
P
0

Bobby

It's a zip file, isn't it?

Photoneutron answered 27/9, 2023 at 23:58 Comment(0)
A
0

Bobby How do you open the engine from the source in Github? I've got it, but I have no idea how to open it.

You have to build it first.
https://docs.godotengine.org/en/4.1/contributing/development/compiling/index.html

Photoneutron It's a zip file, isn't it?

You can also clone the repo.

Arthralgia answered 28/9, 2023 at 0:7 Comment(0)
S
0

Exactly. What's in the folder is just raw source code, not the built Godot Editor executable. To work with C++ in Godot, you will need to follow those instructions to set up the suite of tools needed to compile Godot source code. GDExtensions use those same tools as well.

Selfdenial answered 28/9, 2023 at 0:18 Comment(0)
U
0

Bobby Clone the repository and then follow the build instructions from the docs, depending on your platform. I did it recently on Windows with GCC and VS and it pretty easy to do.

Unblessed answered 28/9, 2023 at 8:56 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.