Coming from Unity
Gaminode has two tools for Unity projects. Import from Unity brings the content: scenes, prefabs, models and materials. Convert Unity C# Scripts turns your MonoBehaviours into GDScript starters with the right types, fields and events, so you only port the logic.
1. Import scenes, prefabs and assets
- Create or open an empty Gaminode project.
- Choose Project > Tools > Gaminode: Import from Unity.... The first time, the importer is added to the project and switched on.
- Pick your Unity project's
Assetsfolder or a.unitypackageand start the import.
The importer is built on Unidot Importer (MIT license). Code is not converted by it; that's step 2.
2. Convert C# scripts
- Choose Project > Tools > Gaminode: Convert Unity C# Scripts...
- Pick the Unity project folder (the one with
Assetsinside). Editor scripts,Pluginsand packages are skipped. - Gaminode writes one GDScript per class into
res://unity_scripts/, plusUNITY_IMPORT_REPORT.md. It never overwrites a script that already exists.
Each script gets:
- the right
extends, guessed from the Unity APIs it uses:CharacterBody3Dfor a CharacterController,RigidBody3D,CharacterBody2D,Controlfor UI,Resourcefor a ScriptableObject; - every public or
[SerializeField]field as an@exportvariable with the matching type and default value; - Unity events mapped to Godot callbacks, and every other method as a function with the same parameters;
- the original C# kept as comments under each function, with a hint for each Unity call it uses.
Generated from PlayerMove.cs# Converted from Unity: Scripts/PlayerMove.cs
class_name PlayerMove
extends CharacterBody3D
@export var speed: float = 6.0
@export var jump_height: float = 2.0
@export var coin_prefab: PackedScene
func _physics_process(delta: float) -> void:
# --- Unity FixedUpdate() ---
# hint: Input.GetAxis("Horizontal") -> Input.get_axis("ui_left", "ui_right")
# hint: controller.Move -> velocity = v; move_and_slide()
# float x = Input.GetAxis("Horizontal");
# controller.Move(new Vector3(x, 0, 0) * speed * Time.deltaTime);
pass
Honest limits: the converter does the structure, types, fields and events. The logic inside each function is still yours (or Gaminode AI's) to port, line by line, with the hints beside it.
Unity events and Gaminode callbacks
| Unity | Gaminode |
|---|---|
| Awake, Start | _ready() |
| Update | _process(delta) |
| FixedUpdate | _physics_process(delta) |
| LateUpdate | end of _process(delta) |
| OnEnable / OnDisable / OnDestroy | _enter_tree() / _exit_tree() |
| OnTriggerEnter | an Area3D's body_entered signal |
| OnCollisionEnter | body_entered on a RigidBody with contact monitor on |
Unity ideas in Gaminode
| Unity | Gaminode |
|---|---|
| GameObject + components | A node (each node type does one job; combine them as children) |
| Prefab | A scene (.tscn) you instance |
| Instantiate(prefab) | var n = scene.instantiate(); add_child(n) |
| Destroy(gameObject) | queue_free() |
| GetComponent<T>() | $ChildName, get_node() or an @export variable |
| Tags | Groups: add_to_group("enemy"), is_in_group("enemy") |
| Coroutines | await get_tree().create_timer(1.0).timeout |
| UnityEvent / C# events | Signals: signal died, died.emit() |
| PlayerPrefs | ConfigFile saved to user:// |
| SceneManager.LoadScene | get_tree().change_scene_to_file("res://...") |
| DontDestroyOnLoad singleton | An Autoload (Project Settings > Globals) |
Something wrong or missing on this page? Email gaminodeofficial@gmail.com.