This is a Godot Engine project template with GDExtension (C++) already setup to kickstart your project.
This template is meant for developing game code with C++ (à la Unreal Engine). For plugin development, I recommend using the official template instead.
For more information, refer to GDExtension C++ Example, as this is what this project is based on.
This template is tested in Godot 4.4 only. It is not guaranteed to work in earlier and later versions (especially Godot 4.0).
- Godot 4 executable
- C++ build tools*
- SCons*
* Follow this documentation for build tools installation according to your platform.
-
Clone this repository somewhere locally alongside its submodules.
git clone --recurse-submodules https://github.com/sqirramoon/GodotCppGameTemplate.git -
Navigate to the cloned repo and go to
.vscodefolder. Depending on your platform, duplicate (copy & paste) the templatelaunchfile and rename it to exactlylaunch.json. Ex: Windows users should duplicatelaunch.windows.json. -
Open the cloned repo folder in VS Code.
-
Edit the recently renamed
launch.jsonin.vscodefolder and make a few edits:- Change the example Godot executable path to your path.
- (Optional) To use the debugger on the Godot Editor, append
--editorin the arguments list.
It is advised to compile the extension before launching the project for the first time.
Compiling is easy, you can hit the build shortcut (default is Ctrl+Shift+B) or by going to Terminal > Run Build Task...
Debugging is supported. Hit the Run shortcut (default is F5) or by going to Run > Start Debugging.
This project is licensed under Do What The Fuck You Want To Public License (WTFPL), see LICENSE.txt for the full license text.
- All of the Godot Engine authors and contributors. Thank you for your FOSS efforts!