Compare commits

..

No commits in common. '6e92461a9a97a4c77d9f6c50f33af0aae1715fe2' and 'b0efa6c9a8a753e185d97d309777d578a1b83c37' have entirely different histories.

@ -52,35 +52,26 @@ jobs:
sudo update-alternatives --set x86_64-w64-mingw32-gcc /usr/bin/x86_64-w64-mingw32-gcc-posix
sudo update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix
- name: (Android) Install JDK 17
- name: (Android) Set up Java 11
if: ${{ startsWith(matrix.identifier, 'android-') }}
uses: actions/setup-java@v3
uses: actions/setup-java@v1
with:
java-version: 17
distribution: temurin
java-version: 11
- name: (Android) Install Android SDK
- name: (Android) Set up Android SDK
if: ${{ startsWith(matrix.identifier, 'android-') }}
uses: android-actions/setup-android@v3
uses: android-actions/setup-android@v2
# From Godot docs, might not be necessary.
#- name: (Android) Install Android Tools
# if: ${{ startsWith(matrix.identifier, 'android-') }}
# shell: sh
# run: |
# "$ANDROID_SDK_ROOT"/cmdline-tools/latest/bin/sdkmanager --sdk_root="$ANDROID_SDK_ROOT" "platform-tools" "build-tools;30.0.3" "platforms;android-29" "cmdline-tools;latest" "cmake;3.10.2.4988404"
- name: (Android) Install NDK r23c
if: ${{ matrix.platform == 'android' }}
uses: nttld/setup-ndk@v1
with:
ndk-version: r23c
link-to-sdk: true
- name: (Android) Install Android Tools
if: ${{ startsWith(matrix.identifier, 'android-') }}
shell: sh
run: |
"$ANDROID_SDK_ROOT"/cmdline-tools/latest/bin/sdkmanager --sdk_root="$ANDROID_SDK_ROOT" "platform-tools" "build-tools;30.0.3" "platforms;android-29" "cmdline-tools;latest" "cmake;3.10.2.4988404" "ndk;21.4.7075529"
- name: Install Python
- name: Set up Python
uses: actions/setup-python@v2
- name: Install SCons
- name: Set up SCons
shell: bash
run: |
python -c "import sys; print(sys.version)"

@ -4,14 +4,17 @@ GDExtension template that automatically builds into a self-contained addon for t
### Getting started:
1. Clone this repository (or a new repository with this template) with submodules.
- `git clone --recurse-submodules https://github.com/nathanfranke/gdextension.git`
- `git clone --recurse-submodules https://github.com/nathanfranke/gdextension.git` \
- `cd gdextension`
2. Update to the latest `godot-cpp`.
- `git submodule update --remote`
2. Build a debug binary for the current platform.
- `scons`
3. Import, edit, and play `project/` using Godot Engine 4+.
- `godot --path project/`
- Alternatively, run the project using the terminal.
- Either alias an existing executable to godot4: `alias godot4="~/workspace/godot/bin/godot.linuxbsd.tools.x86_64"`
- Or, on Arch Linux, install `godot4-bin` from the AUR (`yay -S aur/godot4-bin`).
- Finally, `godot4 --path project/`
4. Check the output:
```
Hello GDScript!

@ -1 +1 @@
Subproject commit 48afa82f29354668c12cffaf6a2474dabfd395ed
Subproject commit 9d1c396c54fc3bdfcc7da4f3abcb52b14f6cce8f

@ -1,7 +1,6 @@
[configuration]
entry_symbol = "gdextension_init"
compatibility_minimum = 4.2
[libraries]

@ -12,4 +12,4 @@ config_version=5
config/name="project"
run/main_scene="res://demo/scene.tscn"
config/features=PackedStringArray("4.2", "Forward Plus")
config/features=PackedStringArray("4.0", "Forward Plus")

@ -36,9 +36,9 @@ void gdextension_terminate(ModuleInitializationLevel p_level)
extern "C"
{
GDExtensionBool GDE_EXPORT gdextension_init(GDExtensionInterfaceGetProcAddress p_get_proc_address, GDExtensionClassLibraryPtr p_library, GDExtensionInitialization *r_initialization)
GDExtensionBool GDE_EXPORT gdextension_init(const GDExtensionInterface *p_interface, GDExtensionClassLibraryPtr p_library, GDExtensionInitialization *r_initialization)
{
godot::GDExtensionBinding::InitObject init_obj(p_get_proc_address, p_library, r_initialization);
godot::GDExtensionBinding::InitObject init_obj(p_interface, p_library, r_initialization);
init_obj.register_initializer(gdextension_initialize);
init_obj.register_terminator(gdextension_terminate);

Loading…
Cancel
Save