This repository contains the .NET bindings for Godot using the GDExtension APIs.
Caution
This repository is still a work in progress. API is subject to change and new versions may break compatibility until the first stable release.
Directory structure:
src
- Source projectstests
- Test projectssamples
- Sample projectseng
- Build infrastructure (build scripts and MSBuild tasks)artifacts
- Build outputs (nupkgs, dlls, pdbs, etc.)build.cmd
- Bootstrap the build for windowsbuild.sh
- Bootstrap the build for *nixtest.cmd
- Shortcut forbuild.cmd -test
test.sh
- Shortcut forbuild.sh --test
To generate the bindings, see the instructions in the Godot.BindingsGenerator tool project.
Normally the tool does not need to be used directly, use the build.sh
/build.cmd
scripts at the root of the repository to build the projects in this repository which will also generate the bindings. See more instructions below.
Use the build.sh
/build.cmd
scripts at the root of the repository. Use the --help
argument to get usage information. See the build infrastructure documentation for more detailed information.
To produce a development build and push the packages to a local NuGet feed so they can be used during development:
./build.sh --productBuild --pushNupkgsLocal ~/MyLocalNuGetSource
To produce a stable build for a custom fork of Godot, generate the extension_api.json
and gdextension_interface.h
files from the custom engine build and replace the files in the gdextension
directory. Then, build the stable packages:
./build.sh --productBuild --ci /p:OfficialBuildId=20240319.1 /p:FinalVersionKind=release
More information about package versioning and the build kinds in the build infrastructure documentation.
The output of the build will be stored in the artifacts
directory at the root of the repository. Only shipping packages are meant to be published through official channels.
To use the bindings in a C# project, see the instructions in the Godot.Bindings project.