GDScript and Python runtime environment
Find a file
LinuxUserGD 7683f1eafb
All checks were successful
Template / Minimal Template (target=editor, everything disabled) (push) Successful in 16s
Template / Deploy (Alpine Linux x86_64) (push) Successful in 3m34s
update to Godot 4.5.1 stable
2025-10-15 23:08:38 +02:00
.forgejo build.zig: Update config options 2025-08-17 01:38:42 +02:00
.github release/0.1.5 (#1) 2024-07-11 23:04:04 +02:00
.godot update to Godot 4.5.1 stable 2025-10-15 23:08:38 +02:00
addons release/0.1.4 (#13) 2023-08-15 17:21:38 +02:00
bin release/0.1.6 (#2) 2025-07-06 23:27:15 +02:00
docker release/0.1.6 (#2) 2025-07-06 23:27:15 +02:00
gdsbin update to Godot 4.5 stable 2025-09-17 17:28:28 +02:00
gdUnit4@b641a131a4 update to Godot 4.5.1 stable 2025-10-15 23:08:38 +02:00
zig-template@88d43fcede release/0.1.6 (#2) 2025-07-06 23:27:15 +02:00
.editorconfig release/0.1.6 (#2) 2025-07-06 23:27:15 +02:00
.gitattributes release/0.1.0 (#6) 2023-08-15 17:21:37 +02:00
.gitignore benchmark: Python 2.7 compatibility 2025-08-31 22:46:07 +02:00
.gitmodules release/0.1.5 (#1) 2024-07-11 23:04:04 +02:00
build release/0.1.4 (#13) 2023-08-15 17:21:38 +02:00
build.zig build.zig: Update config options 2025-08-17 01:38:42 +02:00
CONTRIBUTING.md release/0.1.4 (#13) 2023-08-15 17:21:38 +02:00
CREDITS.md release/0.1.5 (#1) 2024-07-11 23:04:04 +02:00
Godot-v.svg update to Godot 4.5.1 stable 2025-10-15 23:08:38 +02:00
Godot-v.svg.import update to Godot 4.5 stable 2025-09-17 17:28:28 +02:00
icon.svg release/0.1.5 (#1) 2024-07-11 23:04:04 +02:00
icon.svg.import update to Godot 4.5 stable 2025-09-17 17:28:28 +02:00
LICENSE.md release/0.1.6 (#2) 2025-07-06 23:27:15 +02:00
mit.svg release/0.1.5 (#1) 2024-07-11 23:04:04 +02:00
mit.svg.import update to Godot 4.5 stable 2025-09-17 17:28:28 +02:00
preview.gif release/0.1.5 (#1) 2024-07-11 23:04:04 +02:00
project.godot update to Godot 4.5 stable 2025-09-17 17:28:28 +02:00
python.svg release/0.1.6 (#2) 2025-07-06 23:27:15 +02:00
python.svg.import update to Godot 4.5 stable 2025-09-17 17:28:28 +02:00
README.md release/0.1.6 (#2) 2025-07-06 23:27:15 +02:00
zigc++ release/0.1.4 (#13) 2023-08-15 17:21:38 +02:00
zigcc release/0.1.4 (#13) 2023-08-15 17:21:38 +02:00


GDScript to Python to C Transpiler

Godot MIT license Python


gdscript-transpiler-bin is a GDScript compiler (using Nuitka), minimal scripts can be transpiled to Python.

Binary builds are compiled using Forgejo Actions for Alpine Linux, macOS and Windows x86_64.

Other compatible platforms: Android (aarch64 and x86_64).

Also see generated Python source from GDScript.

Video

Example

git clone https://codeberg.org/LinuxUserGD/gdscript-transpiler-bin.git

cd gdscript-transpiler-bin

git submodule update --init --remote --progress

Godot Engine command line (stage0)

  • ./godot4 -s bin/gds.gd --headless help

  • ./godot4 -s bin/gds.gd --headless run=bin/gds.gd (for running GDScript directly using x-python)

  • ./godot4 -s bin/gds.gd --headless format=bin/gds.gd (for generating Python project)

  • ./godot4 -s bin/gds.gd --headless compile=bin/gds.gd (for compiling GDScript to binary using Clang and Nuitka)

Python environment (stage1)

Installing python gds

python -m pip install gdsbin

python -m pip install git+https://codeberg.org/LinuxUserGD/gdscript-transpiler-bin.git@python
  • python -m gdsbin help

  • python -m gdsbin run=bin/gds.gd

  • python -m gdsbin format=bin/gds.gd

  • python -m gdsbin compile=bin/gds.gd

Nuitka compiled binary (stage2)

Installing gds binary (available at itch.io)

unzip gdscript-transpiler-bin.zip
cd gdscript-transpiler-bin
chmod +x gds
  • ./gds[.exe] help

  • ./gds[.exe] run=bin/gds.gd

  • ./gds[.exe] format=bin/gds.gd

  • ./gds[.exe] compile=bin/gds.gd

Benchmark

Time for running GDScript code:

func string() -> int:
	var x: String = ""
	for i in range(0, 300000):
		x += " "
	return x.length()

func add() -> int:
	var x: int = -100000000
	for i in range(0, 100000000):
		x += 1
	return x
Godot Python Nuitka
benchmark.gd 11.639s 4.678s 1.857s

License

See LICENSE and CREDITS (third-party licenses)